From: Ian Romanick Date: Thu, 25 Mar 2010 00:47:20 +0000 (-0700) Subject: Remove unused _mesa_glsl_get_vector_type X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=532edd9bc49ce3430e5084957e2ecf453d1c3d24;p=mesa.git Remove unused _mesa_glsl_get_vector_type This function has been completely replaced by glsl_type::get_instance. --- diff --git a/glsl_types.cpp b/glsl_types.cpp index 6dcbba8e8cd..b2631efef9b 100644 --- a/glsl_types.cpp +++ b/glsl_types.cpp @@ -94,56 +94,6 @@ _mesa_glsl_initialize_types(struct _mesa_glsl_parse_state *state) } -const struct glsl_type * -_mesa_glsl_get_vector_type(unsigned base_type, unsigned vector_length) -{ - switch (base_type) { - case GLSL_TYPE_UINT: - switch (vector_length) { - case 1: - case 2: - case 3: - case 4: - return glsl_uint_type + (vector_length - 1); - default: - return glsl_error_type; - } - case GLSL_TYPE_INT: - switch (vector_length) { - case 1: - case 2: - case 3: - case 4: - return glsl_int_type + (vector_length - 1); - default: - return glsl_error_type; - } - case GLSL_TYPE_FLOAT: - switch (vector_length) { - case 1: - case 2: - case 3: - case 4: - return glsl_float_type + (vector_length - 1); - default: - return glsl_error_type; - } - case GLSL_TYPE_BOOL: - switch (vector_length) { - case 1: - case 2: - case 3: - case 4: - return glsl_bool_type + (vector_length - 1); - default: - return glsl_error_type; - } - default: - return glsl_error_type; - } -} - - const glsl_type *glsl_type::get_base_type() const { switch (base_type) { diff --git a/glsl_types.h b/glsl_types.h index a7897719fb4..04a9ccf4146 100644 --- a/glsl_types.h +++ b/glsl_types.h @@ -254,9 +254,6 @@ extern "C" { extern void _mesa_glsl_initialize_types(struct _mesa_glsl_parse_state *state); -extern const struct glsl_type * -_mesa_glsl_get_vector_type(unsigned base_type, unsigned vector_length); - extern const struct glsl_type *const glsl_error_type; extern const struct glsl_type *const glsl_int_type; extern const struct glsl_type *const glsl_uint_type;