From: Brian Paul Date: Thu, 3 Jul 2014 18:01:09 +0000 (-0600) Subject: st/mesa: minor fix-up in st_GetSamplePosition() X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=301ffe7b26f1c8f68697626490b0e7f1c6aef65e;p=mesa.git st/mesa: minor fix-up in st_GetSamplePosition() If the driver doesn't implement get_sample_position(), let's return some non-garbage values. --- diff --git a/src/mesa/state_tracker/st_cb_msaa.c b/src/mesa/state_tracker/st_cb_msaa.c index bbf2b2c5c46..e9955b62b8f 100644 --- a/src/mesa/state_tracker/st_cb_msaa.c +++ b/src/mesa/state_tracker/st_cb_msaa.c @@ -40,7 +40,7 @@ static void st_GetSamplePosition(struct gl_context *ctx, struct gl_framebuffer *fb, GLuint index, - GLfloat *outValue) + GLfloat *outPos) { struct st_context *st = st_context(ctx); @@ -48,7 +48,9 @@ st_GetSamplePosition(struct gl_context *ctx, if (st->pipe->get_sample_position) st->pipe->get_sample_position(st->pipe, (unsigned) fb->Visual.samples, - index, outValue); + index, outPos); + else + outPos[0] = outPos[1] = 0.5f; }