diff options
author | Courtney Goeltzenleuchter <[email protected]> | 2013-11-14 10:06:59 -0700 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2014-01-20 11:32:00 -0800 |
commit | 86231c4ab3ceb471b3d44978e7d56f167bafe34f (patch) | |
tree | 72fcf72aafa34a0752215e545b0a522db9c87788 /src/mesa/main/viewport.h | |
parent | 0a7baa68a8559d7889c0b68adfcda53f4575ee98 (diff) |
mesa: Add new viewport and depth-range entry points for GL_ARB_viewport_array
v2 (idr): Use set_viewport_no_notify / set_depth_range_no_notify (and
manually notify the driver) instead of calling _mesa_set_viewporti /
_mesa_set_depthrangei. Refactor bodies of _mesa_ViewportIndexed and
_mesa_ViewportIndexedv into a shared function. Remove spurious CLAMP
calls in _mesa_DepthRangeArrayv and _mesa_DepthRangeIndexed.
v3 (idr): Add some missing return-statements after calls to _mesa_error.
v4 (idr): Only perform the ViewportBounds.Min / ViewportBounds.Max
clamping in set_viewport_no_notify if GL_ARB_viewport_array is enabled.
Otherwise the driver may not have set ViewportBounds, and the clamping
will do bad things.
Signed-off-by: Courtney Goeltzenleuchter <[email protected]>
Signed-off-by: Ian Romanick <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/viewport.h')
-rw-r--r-- | src/mesa/main/viewport.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/mesa/main/viewport.h b/src/mesa/main/viewport.h index 6e4c738a51d..f2311c02b44 100644 --- a/src/mesa/main/viewport.h +++ b/src/mesa/main/viewport.h @@ -34,6 +34,14 @@ struct gl_context; extern void GLAPIENTRY _mesa_Viewport(GLint x, GLint y, GLsizei width, GLsizei height); +extern void GLAPIENTRY +_mesa_ViewportArrayv(GLuint first, GLsizei count, const GLfloat * v); + +extern void GLAPIENTRY +_mesa_ViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h); + +extern void GLAPIENTRY +_mesa_ViewportIndexedfv(GLuint index, const GLfloat * v); extern void _mesa_set_viewport(struct gl_context *ctx, unsigned idx, GLfloat x, GLfloat y, @@ -46,6 +54,12 @@ _mesa_DepthRange(GLclampd nearval, GLclampd farval); extern void GLAPIENTRY _mesa_DepthRangef(GLclampf nearval, GLclampf farval); +extern void GLAPIENTRY +_mesa_DepthRangeArrayv(GLuint first, GLsizei count, const GLclampd * v); + +extern void GLAPIENTRY +_mesa_DepthRangeIndexed(GLuint index, GLclampd n, GLclampd f); + extern void _mesa_set_depth_range(struct gl_context *ctx, unsigned idx, GLclampd nearval, GLclampd farval); |