[Piglit] [PATCH] pbo: fix MSVC compile error
Vinson Lee
vlee at freedesktop.org
Thu Jan 8 16:31:51 PST 2015
On Thu, Jan 8, 2015 at 2:56 PM, Brian Paul <brianp at vmware.com> wrote:
> Arrays can't be dimensioned by variables.
> ---
> tests/spec/gl-2.1/pbo.c | 11 +++++------
> 1 file changed, 5 insertions(+), 6 deletions(-)
>
> diff --git a/tests/spec/gl-2.1/pbo.c b/tests/spec/gl-2.1/pbo.c
> index b6c51e9..26b7138 100644
> --- a/tests/spec/gl-2.1/pbo.c
> +++ b/tests/spec/gl-2.1/pbo.c
> @@ -526,16 +526,15 @@ test_tex_image(void)
> GLenum pack = GL_PIXEL_PACK_BUFFER_ARB;
> GLenum unpack = GL_PIXEL_UNPACK_BUFFER_ARB;
> int texture_size = TEXSIZE * TEXSIZE * 3;
> - GLfloat t1[texture_size];
> - GLfloat t2[texture_size];
> + GLfloat t1[TEXSIZE * TEXSIZE * 3];
> + GLfloat t2[TEXSIZE * TEXSIZE * 3];
> GLfloat *pbo_mem = NULL;
> int i, j;
> GLfloat green[3] = { 1.0, 1.0, 0.0 };
> GLfloat black[3] = { 0.0, 0.0, 0.0 };
> - int window_size = WINSIZE * WINSIZE * 3;
> - GLfloat buf[window_size];
> - GLfloat exp_tex[texture_size];
> - GLfloat exp_win[window_size];
> + GLfloat buf[WINSIZE * WINSIZE * 3];
> + GLfloat exp_tex[TEXSIZE * TEXSIZE * 3];
> + GLfloat exp_win[WINSIZE * WINSIZE * 3];
> GLfloat tolerance[4];
>
> piglit_compute_probe_tolerance(GL_RGB, tolerance);
> --
> 1.9.1
>
> _______________________________________________
> Piglit mailing list
> Piglit at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/piglit
Reviewed-by: Vinson Lee <vlee at freedesktop.org>
More information about the Piglit
mailing list