From d4726b13183c45fbc0869596c128f7c030b3cd9c Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Mon, 6 Nov 2017 09:19:55 -0700 Subject: st/mesa: use enum types instead of int/unsigned (v3) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use the proper enum types for various variables. Makes life in gdb a little nicer. Note that the size of enum bitfields must be one larger so the high bit is always zero (for MSVC). v2: also increase size of image_format bitfield, per Eric Engestrom. v3: use the new ASSERT_BITFIELD_SIZE() macro Reviewed-by: Charmaine Lee Reviewed-by: Roland Scheidegger Reviewed-by: Nicolai Hähnle --- src/mesa/state_tracker/st_mesa_to_tgsi.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/mesa/state_tracker/st_mesa_to_tgsi.h') diff --git a/src/mesa/state_tracker/st_mesa_to_tgsi.h b/src/mesa/state_tracker/st_mesa_to_tgsi.h index 106cf85a3e6..06e8b70cb4d 100644 --- a/src/mesa/state_tracker/st_mesa_to_tgsi.h +++ b/src/mesa/state_tracker/st_mesa_to_tgsi.h @@ -30,6 +30,7 @@ #define ST_MESA_TO_TGSI_H #include "main/glheader.h" +#include "main/mtypes.h" #include "pipe/p_compiler.h" #include "pipe/p_defines.h" @@ -62,10 +63,10 @@ st_translate_mesa_program( const ubyte outputSemanticName[], const ubyte outputSemanticIndex[]); -unsigned -st_translate_texture_target(GLuint textarget, GLboolean shadow); +enum tgsi_texture_type +st_translate_texture_target(gl_texture_index textarget, GLboolean shadow); -unsigned +enum tgsi_return_type st_translate_texture_type(enum glsl_base_type type); #if defined __cplusplus -- cgit v1.2.3