From: Brian Paul Date: Wed, 12 Aug 2009 19:53:56 +0000 (-0600) Subject: demos: rename InitUniforms() to SetUniformValues() X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=684049d97d423a5a873aefc5313d0c4b22528b95;p=mesa.git demos: rename InitUniforms() to SetUniformValues() And call new PrintUniforms() in demos. --- diff --git a/progs/glsl/brick.c b/progs/glsl/brick.c index 1d08b231e7e..e5f5c96607d 100644 --- a/progs/glsl/brick.c +++ b/progs/glsl/brick.c @@ -148,7 +148,8 @@ Init(void) glUseProgram(program); - InitUniforms(program, Uniforms); + SetUniformValues(program, Uniforms); + PrintUniforms(Uniforms); assert(glGetError() == 0); diff --git a/progs/glsl/bump.c b/progs/glsl/bump.c index ddb986abcb5..29af26f7a1f 100644 --- a/progs/glsl/bump.c +++ b/progs/glsl/bump.c @@ -242,7 +242,8 @@ Init(void) CheckError(__LINE__); - InitUniforms(program, Uniforms); + SetUniformValues(program, Uniforms); + PrintUniforms(Uniforms); CheckError(__LINE__); diff --git a/progs/glsl/mandelbrot.c b/progs/glsl/mandelbrot.c index 38dffc3e741..09c65d2c2b7 100644 --- a/progs/glsl/mandelbrot.c +++ b/progs/glsl/mandelbrot.c @@ -159,7 +159,8 @@ Init(void) glUseProgram(program); - InitUniforms(program, Uniforms); + SetUniformValues(program, Uniforms); + PrintUniforms(Uniforms); uZoom = glGetUniformLocation(program, "Zoom"); uXcenter = glGetUniformLocation(program, "Xcenter"); diff --git a/progs/glsl/multitex.c b/progs/glsl/multitex.c index a4a8bbe38fa..ce79bc1b4d5 100644 --- a/progs/glsl/multitex.c +++ b/progs/glsl/multitex.c @@ -328,7 +328,8 @@ CreateProgram(const char *vertProgFile, const char *fragProgFile, glUseProgram(program); - InitUniforms(program, uniforms); + SetUniformValues(program, uniforms); + PrintUniforms(Uniforms); VertCoord_attr = glGetAttribLocation(program, "VertCoord"); if (VertCoord_attr > 0) { diff --git a/progs/glsl/noise.c b/progs/glsl/noise.c index 59f594e78bf..6ef2a80f78d 100644 --- a/progs/glsl/noise.c +++ b/progs/glsl/noise.c @@ -179,7 +179,8 @@ Init(void) glUseProgram(program); - InitUniforms(program, Uniforms); + SetUniformValues(program, Uniforms); + PrintUniforms(Uniforms); assert(glGetError() == 0); diff --git a/progs/glsl/texdemo1.c b/progs/glsl/texdemo1.c index d55f9e7dd97..f0dce8555e7 100644 --- a/progs/glsl/texdemo1.c +++ b/progs/glsl/texdemo1.c @@ -382,7 +382,8 @@ CreateProgram(const char *vertProgFile, const char *fragProgFile, glUseProgram(program); - InitUniforms(program, uniforms); + SetUniformValues(program, uniforms); + PrintUniforms(uniforms); return program; } diff --git a/progs/glsl/toyball.c b/progs/glsl/toyball.c index 7fe27aebfe6..13f57766844 100644 --- a/progs/glsl/toyball.c +++ b/progs/glsl/toyball.c @@ -173,7 +173,8 @@ Init(void) glUseProgram(program); - InitUniforms(program, Uniforms); + SetUniformValues(program, Uniforms); + PrintUniforms(Uniforms); assert(glGetError() == 0); diff --git a/progs/util/shaderutil.c b/progs/util/shaderutil.c index bd04ce5c6ad..f057adf5c73 100644 --- a/progs/util/shaderutil.c +++ b/progs/util/shaderutil.c @@ -122,7 +122,7 @@ LinkShaders(GLuint vertShader, GLuint fragShader) void -InitUniforms(GLuint program, struct uniform_info uniforms[]) +SetUniformValues(GLuint program, struct uniform_info uniforms[]) { GLuint i; diff --git a/progs/util/shaderutil.h b/progs/util/shaderutil.h index 607ed284915..22dc4dc4319 100644 --- a/progs/util/shaderutil.h +++ b/progs/util/shaderutil.h @@ -37,7 +37,7 @@ extern GLuint LinkShaders(GLuint vertShader, GLuint fragShader); extern void -InitUniforms(GLuint program, struct uniform_info uniforms[]); +SetUniformValues(GLuint program, struct uniform_info uniforms[]); extern GLuint GetUniforms(GLuint program, struct uniform_info uniforms[]);