aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_atom_rasterizer.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2015-09-27 19:43:00 +0200
committerMarek Olšák <[email protected]>2015-10-03 22:06:09 +0200
commit4e9fc7e4e2fa3b3c77d08c4db545dcc279e849e9 (patch)
treef5e6a5808adf752607a274ee8772a2c852749285 /src/mesa/state_tracker/st_atom_rasterizer.c
parentf3b37e321fe5ea8a8c0ff026636d69ce90437a6f (diff)
st/mesa: set force_persample_interp if ARB_sample_shading is used
This is only a half of the work. The next patch will handle gl_SampleID/SamplePos, which is the other half of ARB_sample_shading. Reviewed-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker/st_atom_rasterizer.c')
-rw-r--r--src/mesa/state_tracker/st_atom_rasterizer.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_atom_rasterizer.c b/src/mesa/state_tracker/st_atom_rasterizer.c
index cceed42c828..0f01e9939de 100644
--- a/src/mesa/state_tracker/st_atom_rasterizer.c
+++ b/src/mesa/state_tracker/st_atom_rasterizer.c
@@ -237,6 +237,14 @@ static void update_raster_state( struct st_context *st )
/* _NEW_MULTISAMPLE */
raster->multisample = ctx->Multisample._Enabled;
+ /* _NEW_MULTISAMPLE | _NEW_BUFFERS */
+ raster->force_persample_interp =
+ st->can_force_persample_interp &&
+ ctx->Multisample._Enabled &&
+ ctx->Multisample.SampleShading &&
+ ctx->Multisample.MinSampleShadingValue *
+ ctx->DrawBuffer->Visual.samples > 1;
+
/* _NEW_SCISSOR */
raster->scissor = ctx->Scissor.EnableFlags;