[Piglit] [PATCH 1/4] util: fix piglit_multisample_texture() parameter type

Brian Paul brianp at vmware.com
Fri Nov 10 22:44:42 UTC 2017


Texture IDs are GLuint, not GLenum.
---
 tests/util/piglit-util-gl.c | 3 ++-
 tests/util/piglit-util-gl.h | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/tests/util/piglit-util-gl.c b/tests/util/piglit-util-gl.c
index d8b8f85..041427d 100644
--- a/tests/util/piglit-util-gl.c
+++ b/tests/util/piglit-util-gl.c
@@ -2949,6 +2949,7 @@ static const char multisample_texture_fs_source[] =
  *
  * \param target         either GL_TEXTURE_2D_MULTISAMPLE or
  *                       GL_TEXTURE2D_MULTISAMPLE_ARRAY
+ * \param tex            texture ID for existing texture, or zero
  * \param internalformat a renderable color format accepted by
  *                       glTexImage2DMultisample
  * \param width          texture width
@@ -2963,7 +2964,7 @@ static const char multisample_texture_fs_source[] =
  * \return the new texture object id
  */
 GLuint
-piglit_multisample_texture(GLenum target, GLenum tex, GLenum internalFormat,
+piglit_multisample_texture(GLenum target, GLuint tex, GLenum internalFormat,
 			   unsigned width, unsigned height,
 			   unsigned depth, unsigned samples,
 			   GLenum format, GLenum type, void *data)
diff --git a/tests/util/piglit-util-gl.h b/tests/util/piglit-util-gl.h
index 3bb0ee8..00b5a35 100644
--- a/tests/util/piglit-util-gl.h
+++ b/tests/util/piglit-util-gl.h
@@ -304,7 +304,7 @@ GLuint piglit_rgbw_texture(GLenum internalFormat, int w, int h, GLboolean mip,
 GLuint piglit_integer_texture(GLenum internalFormat, int w, int h, int b, int a);
 GLuint piglit_depth_texture(GLenum target, GLenum format, int w, int h, int d, GLboolean mip);
 GLuint piglit_array_texture(GLenum target, GLenum format, int w, int h, int d, GLboolean mip);
-GLuint piglit_multisample_texture(GLenum target, GLenum tex,
+GLuint piglit_multisample_texture(GLenum target, GLuint tex,
 				  GLenum internalFormat,
 				  unsigned width, unsigned height,
 				  unsigned depth, unsigned samples,
-- 
1.9.1



More information about the Piglit mailing list