[Bf-blender-cvs] [600ca3190a5] master: Cleanup: argument sign mismatch warning

Campbell Barton noreply at git.blender.org
Thu Jun 6 02:29:51 CEST 2019


Commit: 600ca3190a506d8931e32dd15544038583f57673
Author: Campbell Barton
Date:   Thu Jun 6 09:55:53 2019 +1000
Branches: master
https://developer.blender.org/rB600ca3190a506d8931e32dd15544038583f57673

Cleanup: argument sign mismatch warning

===================================================================

M	source/blender/gpu/GPU_shader.h
M	source/blender/gpu/intern/gpu_codegen.h
M	source/blender/gpu/intern/gpu_shader.c

===================================================================

diff --git a/source/blender/gpu/GPU_shader.h b/source/blender/gpu/GPU_shader.h
index dca66817666..cae2392e503 100644
--- a/source/blender/gpu/GPU_shader.h
+++ b/source/blender/gpu/GPU_shader.h
@@ -99,7 +99,7 @@ void GPU_shader_uniform_int(GPUShader *shader, int location, int value);
 
 int GPU_shader_get_attribute(GPUShader *shader, const char *name);
 
-char *GPU_shader_get_binary(GPUShader *shader, int *r_binary_format, int *r_binary_len);
+char *GPU_shader_get_binary(GPUShader *shader, uint *r_binary_format, int *r_binary_len);
 
 /* Builtin/Non-generated shaders */
 typedef enum eGPUBuiltinShader {
diff --git a/source/blender/gpu/intern/gpu_codegen.h b/source/blender/gpu/intern/gpu_codegen.h
index eac5df7e348..ae34e21b9cd 100644
--- a/source/blender/gpu/intern/gpu_codegen.h
+++ b/source/blender/gpu/intern/gpu_codegen.h
@@ -166,7 +166,7 @@ struct GPUPass {
   uint32_t hash; /* Identity hash generated from all GLSL code. */
   struct {
     char *content;
-    int format;
+    uint format;
     int len;
   } binary;
   bool compiled; /* Did we already tried to compile the attached GPUShader. */
diff --git a/source/blender/gpu/intern/gpu_shader.c b/source/blender/gpu/intern/gpu_shader.c
index 047cabda9f8..c142d8ccba2 100644
--- a/source/blender/gpu/intern/gpu_shader.c
+++ b/source/blender/gpu/intern/gpu_shader.c
@@ -845,7 +845,7 @@ int GPU_shader_get_attribute(GPUShader *shader, const char *name)
   return attr ? attr->location : -1;
 }
 
-char *GPU_shader_get_binary(GPUShader *shader, int *r_binary_format, int *r_binary_len)
+char *GPU_shader_get_binary(GPUShader *shader, uint *r_binary_format, int *r_binary_len)
 {
   BLI_assert(GLEW_ARB_get_program_binary);
   char *r_binary;



More information about the Bf-blender-cvs mailing list