summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorErik Faye-Lund <[email protected]>2018-11-07 15:52:23 +0100
committerErik Faye-Lund <[email protected]>2018-11-23 10:48:35 +0100
commitdd4241b34fbb1c282a34e18a74ba2fcfabe4467a (patch)
treec1ac37d0bf306d4b721552db0891572d675cc4a5 /src
parentba4e8d37548205601df8043a8f303adede4d56f7 (diff)
mesa/main: use non-prefixed enums for consistency
These enums all have the same values as their non-prefixed versions, and there's several aliases for some of them. So let's switch to the non-prefixed versions for simplicity. Signed-off-by: Erik Faye-Lund <[email protected]> Reviewed-by: Tapani Pälli <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/mesa/main/queryobj.c66
1 files changed, 33 insertions, 33 deletions
diff --git a/src/mesa/main/queryobj.c b/src/mesa/main/queryobj.c
index e97a0138e96..2a143191c62 100644
--- a/src/mesa/main/queryobj.c
+++ b/src/mesa/main/queryobj.c
@@ -146,7 +146,7 @@ static struct gl_query_object **
get_pipe_stats_binding_point(struct gl_context *ctx,
GLenum target)
{
- const int which = target - GL_VERTICES_SUBMITTED_ARB;
+ const int which = target - GL_VERTICES_SUBMITTED;
assert(which < MAX_PIPELINE_STATISTICS);
if (!_mesa_is_desktop_gl(ctx) ||
@@ -179,7 +179,7 @@ get_query_binding_point(struct gl_context *ctx, GLenum target, GLuint index)
return NULL;
switch (target) {
- case GL_SAMPLES_PASSED_ARB:
+ case GL_SAMPLES_PASSED:
if (ctx->Extensions.ARB_occlusion_query)
return &ctx->Query.CurrentOcclusionObject;
else
@@ -195,7 +195,7 @@ get_query_binding_point(struct gl_context *ctx, GLenum target, GLuint index)
return &ctx->Query.CurrentOcclusionObject;
else
return NULL;
- case GL_TIME_ELAPSED_EXT:
+ case GL_TIME_ELAPSED:
if (ctx->Extensions.EXT_timer_query)
return &ctx->Query.CurrentTimerObject;
else
@@ -210,43 +210,43 @@ get_query_binding_point(struct gl_context *ctx, GLenum target, GLuint index)
return &ctx->Query.PrimitivesWritten[index];
else
return NULL;
- case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW_ARB:
+ case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW:
if (ctx->Extensions.ARB_transform_feedback_overflow_query)
return &ctx->Query.TransformFeedbackOverflow[index];
else
return NULL;
- case GL_TRANSFORM_FEEDBACK_OVERFLOW_ARB:
+ case GL_TRANSFORM_FEEDBACK_OVERFLOW:
if (ctx->Extensions.ARB_transform_feedback_overflow_query)
return &ctx->Query.TransformFeedbackOverflowAny;
else
return NULL;
- case GL_VERTICES_SUBMITTED_ARB:
- case GL_PRIMITIVES_SUBMITTED_ARB:
- case GL_VERTEX_SHADER_INVOCATIONS_ARB:
- case GL_FRAGMENT_SHADER_INVOCATIONS_ARB:
- case GL_CLIPPING_INPUT_PRIMITIVES_ARB:
- case GL_CLIPPING_OUTPUT_PRIMITIVES_ARB:
+ case GL_VERTICES_SUBMITTED:
+ case GL_PRIMITIVES_SUBMITTED:
+ case GL_VERTEX_SHADER_INVOCATIONS:
+ case GL_FRAGMENT_SHADER_INVOCATIONS:
+ case GL_CLIPPING_INPUT_PRIMITIVES:
+ case GL_CLIPPING_OUTPUT_PRIMITIVES:
return get_pipe_stats_binding_point(ctx, target);
case GL_GEOMETRY_SHADER_INVOCATIONS:
/* GL_GEOMETRY_SHADER_INVOCATIONS is defined in a non-sequential order */
- target = GL_VERTICES_SUBMITTED_ARB + MAX_PIPELINE_STATISTICS - 1;
+ target = GL_VERTICES_SUBMITTED + MAX_PIPELINE_STATISTICS - 1;
/* fallthrough */
- case GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED_ARB:
+ case GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED:
if (_mesa_has_geometry_shaders(ctx))
return get_pipe_stats_binding_point(ctx, target);
else
return NULL;
- case GL_TESS_CONTROL_SHADER_PATCHES_ARB:
- case GL_TESS_EVALUATION_SHADER_INVOCATIONS_ARB:
+ case GL_TESS_CONTROL_SHADER_PATCHES:
+ case GL_TESS_EVALUATION_SHADER_INVOCATIONS:
if (_mesa_has_tessellation(ctx))
return get_pipe_stats_binding_point(ctx, target);
else
return NULL;
- case GL_COMPUTE_SHADER_INVOCATIONS_ARB:
+ case GL_COMPUTE_SHADER_INVOCATIONS:
if (_mesa_has_compute_shaders(ctx))
return get_pipe_stats_binding_point(ctx, target);
else
@@ -316,8 +316,8 @@ _mesa_CreateQueries(GLenum target, GLsizei n, GLuint *ids)
case GL_TIMESTAMP:
case GL_PRIMITIVES_GENERATED:
case GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN:
- case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW_ARB:
- case GL_TRANSFORM_FEEDBACK_OVERFLOW_ARB:
+ case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW:
+ case GL_TRANSFORM_FEEDBACK_OVERFLOW:
break;
default:
_mesa_error(ctx, GL_INVALID_ENUM, "glCreateQueries(invalid target = %s)",
@@ -393,7 +393,7 @@ query_error_check_index(struct gl_context *ctx, GLenum target, GLuint index)
switch (target) {
case GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN:
case GL_PRIMITIVES_GENERATED:
- case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW_ARB:
+ case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW:
if (index >= ctx->Const.MaxVertexStreams) {
_mesa_error(ctx, GL_INVALID_VALUE,
"glBeginQueryIndexed(index>=MaxVertexStreams)");
@@ -692,7 +692,7 @@ _mesa_GetQueryIndexediv(GLenum target, GLuint index, GLenum pname,
}
switch (pname) {
- case GL_QUERY_COUNTER_BITS_ARB:
+ case GL_QUERY_COUNTER_BITS:
switch (target) {
case GL_SAMPLES_PASSED:
*params = ctx->Const.QueryCounterBits.SamplesPassed;
@@ -717,45 +717,45 @@ _mesa_GetQueryIndexediv(GLenum target, GLuint index, GLenum pname,
case GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN:
*params = ctx->Const.QueryCounterBits.PrimitivesWritten;
break;
- case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW_ARB:
- case GL_TRANSFORM_FEEDBACK_OVERFLOW_ARB:
+ case GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW:
+ case GL_TRANSFORM_FEEDBACK_OVERFLOW:
/* The minimum value of this is 1 if it's nonzero, and the value
* is only ever GL_TRUE or GL_FALSE, so no sense in reporting more
* bits.
*/
*params = 1;
break;
- case GL_VERTICES_SUBMITTED_ARB:
+ case GL_VERTICES_SUBMITTED:
*params = ctx->Const.QueryCounterBits.VerticesSubmitted;
break;
- case GL_PRIMITIVES_SUBMITTED_ARB:
+ case GL_PRIMITIVES_SUBMITTED:
*params = ctx->Const.QueryCounterBits.PrimitivesSubmitted;
break;
- case GL_VERTEX_SHADER_INVOCATIONS_ARB:
+ case GL_VERTEX_SHADER_INVOCATIONS:
*params = ctx->Const.QueryCounterBits.VsInvocations;
break;
- case GL_TESS_CONTROL_SHADER_PATCHES_ARB:
+ case GL_TESS_CONTROL_SHADER_PATCHES:
*params = ctx->Const.QueryCounterBits.TessPatches;
break;
- case GL_TESS_EVALUATION_SHADER_INVOCATIONS_ARB:
+ case GL_TESS_EVALUATION_SHADER_INVOCATIONS:
*params = ctx->Const.QueryCounterBits.TessInvocations;
break;
case GL_GEOMETRY_SHADER_INVOCATIONS:
*params = ctx->Const.QueryCounterBits.GsInvocations;
break;
- case GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED_ARB:
+ case GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED:
*params = ctx->Const.QueryCounterBits.GsPrimitives;
break;
- case GL_FRAGMENT_SHADER_INVOCATIONS_ARB:
+ case GL_FRAGMENT_SHADER_INVOCATIONS:
*params = ctx->Const.QueryCounterBits.FsInvocations;
break;
- case GL_COMPUTE_SHADER_INVOCATIONS_ARB:
+ case GL_COMPUTE_SHADER_INVOCATIONS:
*params = ctx->Const.QueryCounterBits.ComputeInvocations;
break;
- case GL_CLIPPING_INPUT_PRIMITIVES_ARB:
+ case GL_CLIPPING_INPUT_PRIMITIVES:
*params = ctx->Const.QueryCounterBits.ClInPrimitives;
break;
- case GL_CLIPPING_OUTPUT_PRIMITIVES_ARB:
+ case GL_CLIPPING_OUTPUT_PRIMITIVES:
*params = ctx->Const.QueryCounterBits.ClOutPrimitives;
break;
default:
@@ -766,7 +766,7 @@ _mesa_GetQueryIndexediv(GLenum target, GLuint index, GLenum pname,
break;
}
break;
- case GL_CURRENT_QUERY_ARB:
+ case GL_CURRENT_QUERY:
*params = (q && q->Target == target) ? q->Id : 0;
break;
default: