On 06/06/2018 02:51 AM, Ian Romanick wrote:
On 06/05/2018 03:41 PM, Vinson Lee wrote:
piglit-util-gl.c:1941:1: warning: ‘read_texture_via_fbo’ defined but not used 
[-Wunused-function]
  read_texture_via_fbo(int target, int level, int x, int y, int layer, int w,
  ^~~~~~~~~~~~~~~~~~~~

Fixes: 77a4b73436c0 ("util: provide way to read a texture in ES compatible way")
Signed-off-by: Vinson Lee <v...@freedesktop.org>
---
  tests/util/piglit-util-gl.c | 2 ++
  1 file changed, 2 insertions(+)

diff --git a/tests/util/piglit-util-gl.c b/tests/util/piglit-util-gl.c
index 9b0f88a3697e..11e7d4b1da4d 100644
--- a/tests/util/piglit-util-gl.c
+++ b/tests/util/piglit-util-gl.c
@@ -1894,6 +1894,7 @@ piglit_probe_image_ubyte(int x, int y, int w, int h, 
GLenum format,
        return 1;
  }
+#ifndef PIGLIT_USE_OPENGL

Isn't there a PIGLIT_USE_OPENGLES2 flag or similar that we could use?
I'm not sure how this change (or 77a4b73436c0) interacts with building
GLES 1.x tests... if at all.

It should not affect as those tests are not using the 'probe_texel' functions (using probe_pixel instead). It should be fine to go with this:

Reviewed-by: Tapani Pälli <tapani.pa...@intel.com>



  static GLuint
  create_fbo_from_texture(GLenum target, GLint texture, GLint level, GLint 
layer)
  {
@@ -1995,6 +1996,7 @@ read_texture_via_fbo(int target, int level, int x, int y, 
int layer, int w,
return buffer;
  }
+#endif
/**

_______________________________________________
Piglit mailing list
Piglit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to