[Mesa-dev] [PATCH excerpt] mesa: Rename _mesa_lookup_enum_by_nr() to _mesa_enum_to_string().
Kenneth Graunke
kenneth at whitecape.org
Sat Jul 18 01:36:28 PDT 2015
Generated by sed; no manual changes.
Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
We talked about doing this back in 2013, but the patches never
quite materialized. Here's the obvious sed job. Actual patch
is here:
http://cgit.freedesktop.org/~kwg/mesa/commit/?h=enumtostring
I figured I'd spare the mailing list 146Kb of obvious diff.
Thoughts?
src/mapi/glapi/gen/gl_enums.py | 2 +-
src/mesa/drivers/common/meta_blit.c | 2 +-
src/mesa/drivers/common/meta_generate_mipmap.c | 2 +-
src/mesa/drivers/dri/i915/i830_state.c | 20 ++--
src/mesa/drivers/dri/i915/intel_fbo.c | 2 +-
src/mesa/drivers/dri/i915/intel_mipmap_tree.c | 2 +-
src/mesa/drivers/dri/i915/intel_render.c | 2 +-
src/mesa/drivers/dri/i915/intel_tex_image.c | 2 +-
src/mesa/drivers/dri/i915/intel_tex_subimage.c | 2 +-
src/mesa/drivers/dri/i915/intel_tris.c | 4 +-
src/mesa/drivers/dri/i965/brw_draw.c | 8 +-
src/mesa/drivers/dri/i965/brw_draw_upload.c | 2 +-
src/mesa/drivers/dri/i965/gen6_cc.c | 4 +-
src/mesa/drivers/dri/i965/intel_fbo.c | 2 +-
src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 2 +-
src/mesa/drivers/dri/i965/intel_tex_image.c | 4 +-
src/mesa/drivers/dri/i965/intel_tex_subimage.c | 4 +-
src/mesa/drivers/dri/r200/r200_state.c | 2 +-
src/mesa/drivers/dri/r200/r200_tex.c | 18 ++--
src/mesa/drivers/dri/radeon/radeon_common.c | 2 +-
src/mesa/drivers/dri/radeon/radeon_fbo.c | 2 +-
src/mesa/drivers/dri/radeon/radeon_mipmap_tree.c | 2 +-
src/mesa/drivers/dri/radeon/radeon_pixel_read.c | 2 +-
src/mesa/drivers/dri/radeon/radeon_state.c | 2 +-
src/mesa/drivers/dri/radeon/radeon_swtcl.c | 2 +-
src/mesa/drivers/dri/radeon/radeon_tex.c | 6 +-
src/mesa/drivers/dri/radeon/radeon_texture.c | 4 +-
src/mesa/main/api_validate.c | 2 +-
src/mesa/main/atifragshader.c | 30 +++---
src/mesa/main/attrib.c | 2 +-
src/mesa/main/blend.c | 34 +++----
src/mesa/main/blit.c | 8 +-
src/mesa/main/bufferobj.c | 14 +--
src/mesa/main/buffers.c | 22 ++---
src/mesa/main/clear.c | 8 +-
src/mesa/main/condrender.c | 4 +-
src/mesa/main/copyimage.c | 8 +-
src/mesa/main/debug.c | 2 +-
src/mesa/main/depth.c | 2 +-
src/mesa/main/dlist.c | 14 +--
src/mesa/main/drawpix.c | 18 ++--
src/mesa/main/enable.c | 12 +--
src/mesa/main/enums.h | 2 +-
src/mesa/main/errors.c | 4 +-
src/mesa/main/fbobject.c | 72 +++++++-------
src/mesa/main/feedback.c | 2 +-
src/mesa/main/formatquery.c | 8 +-
src/mesa/main/framebuffer.c | 2 +-
src/mesa/main/genmipmap.c | 2 +-
src/mesa/main/get.c | 8 +-
src/mesa/main/getstring.c | 4 +-
src/mesa/main/glformats.c | 6 +-
src/mesa/main/hint.c | 4 +-
src/mesa/main/light.c | 6 +-
src/mesa/main/matrix.c | 8 +-
src/mesa/main/objectlabel.c | 2 +-
src/mesa/main/pipelineobj.c | 2 +-
src/mesa/main/polygon.c | 8 +-
src/mesa/main/program_resource.c | 20 ++--
src/mesa/main/queryobj.c | 28 +++---
src/mesa/main/readpix.c | 12 +--
src/mesa/main/samplerobj.c | 20 ++--
src/mesa/main/shader_query.cpp | 14 +--
src/mesa/main/shaderapi.c | 8 +-
src/mesa/main/shaderimage.c | 2 +-
src/mesa/main/tests/enum_strings.cpp | 4 +-
src/mesa/main/texenv.c | 10 +-
src/mesa/main/texformat.c | 2 +-
src/mesa/main/texgen.c | 6 +-
src/mesa/main/texgetimage.c | 4 +-
src/mesa/main/teximage.c | 114 +++++++++++------------
src/mesa/main/texobj.c | 6 +-
src/mesa/main/texparam.c | 24 ++---
src/mesa/main/texstate.c | 36 +++----
src/mesa/main/texstate.h | 2 +-
src/mesa/main/texstorage.c | 16 ++--
src/mesa/main/textureview.c | 10 +-
src/mesa/main/uniforms.c | 2 +-
src/mesa/main/varray.c | 6 +-
src/mesa/main/viewport.c | 4 +-
src/mesa/tnl/t_draw.c | 2 +-
src/mesa/tnl/t_vb_render.c | 2 +-
src/mesa/tnl/t_vertex_sse.c | 2 +-
src/mesa/tnl_dd/t_dd_dmatmp.h | 2 +-
src/mesa/tnl_dd/t_dd_unfilled.h | 2 +-
src/mesa/vbo/vbo_exec_array.c | 58 ++++++------
86 files changed, 423 insertions(+), 423 deletions(-)
diff --git a/src/mapi/glapi/gen/gl_enums.py b/src/mapi/glapi/gen/gl_enums.py
index 955f27d..a2d6c7c 100644
--- a/src/mapi/glapi/gen/gl_enums.py
+++ b/src/mapi/glapi/gen/gl_enums.py
@@ -78,7 +78,7 @@ static int compar_nr( const int *a, enum_elt *b )
static char token_tmp[20];
-const char *_mesa_lookup_enum_by_nr( int nr )
+const char *_mesa_enum_to_string( int nr )
{
enum_elt *elt;
diff --git a/src/mesa/drivers/common/meta_blit.c b/src/mesa/drivers/common/meta_blit.c
index 9cace2b..317a304 100644
--- a/src/mesa/drivers/common/meta_blit.c
+++ b/src/mesa/drivers/common/meta_blit.c
@@ -312,7 +312,7 @@ setup_glsl_msaa_blit_shader(struct gl_context *ctx,
break;
default:
_mesa_problem(ctx, "Unkown texture target %s\n",
- _mesa_lookup_enum_by_nr(target));
+ _mesa_enum_to_string(target));
shader_index = BLIT_2X_MSAA_SHADER_2D_MULTISAMPLE_RESOLVE;
}
More information about the mesa-dev
mailing list