diff options
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_context.h | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_state_upload.c | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/gen8_ps_state.c | 8 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/gen8_sf_state.c | 5 |
4 files changed, 11 insertions, 6 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_context.h b/src/mesa/drivers/dri/i965/brw_context.h index 46091b65717..1ba97922c84 100644 --- a/src/mesa/drivers/dri/i965/brw_context.h +++ b/src/mesa/drivers/dri/i965/brw_context.h @@ -226,6 +226,7 @@ enum brw_state_id { BRW_STATE_CC_STATE, BRW_STATE_BLORP, BRW_STATE_VIEWPORT_COUNT, + BRW_STATE_CONSERVATIVE_RASTERIZATION, BRW_NUM_STATE_BITS }; @@ -316,6 +317,7 @@ enum brw_state_id { #define BRW_NEW_URB_SIZE (1ull << BRW_STATE_URB_SIZE) #define BRW_NEW_CC_STATE (1ull << BRW_STATE_CC_STATE) #define BRW_NEW_BLORP (1ull << BRW_STATE_BLORP) +#define BRW_NEW_CONSERVATIVE_RASTERIZATION (1ull << BRW_STATE_CONSERVATIVE_RASTERIZATION) struct brw_state_flags { /** State update flags signalled by mesa internals */ diff --git a/src/mesa/drivers/dri/i965/brw_state_upload.c b/src/mesa/drivers/dri/i965/brw_state_upload.c index b689ae41f67..d0be6acaf0f 100644 --- a/src/mesa/drivers/dri/i965/brw_state_upload.c +++ b/src/mesa/drivers/dri/i965/brw_state_upload.c @@ -529,6 +529,7 @@ void brw_init_state( struct brw_context *brw ) ctx->DriverFlags.NewAtomicBuffer = BRW_NEW_ATOMIC_BUFFER; ctx->DriverFlags.NewImageUnits = BRW_NEW_IMAGE_UNITS; ctx->DriverFlags.NewDefaultTessLevels = BRW_NEW_DEFAULT_TESS_LEVELS; + ctx->DriverFlags.NewIntelConservativeRasterization = BRW_NEW_CONSERVATIVE_RASTERIZATION; } @@ -663,6 +664,7 @@ static struct dirty_bit_map brw_bits[] = { DEFINE_BIT(BRW_NEW_CC_STATE), DEFINE_BIT(BRW_NEW_BLORP), DEFINE_BIT(BRW_NEW_VIEWPORT_COUNT), + DEFINE_BIT(BRW_NEW_CONSERVATIVE_RASTERIZATION), {0, 0, 0} }; diff --git a/src/mesa/drivers/dri/i965/gen8_ps_state.c b/src/mesa/drivers/dri/i965/gen8_ps_state.c index e43192d3622..03468267ce6 100644 --- a/src/mesa/drivers/dri/i965/gen8_ps_state.c +++ b/src/mesa/drivers/dri/i965/gen8_ps_state.c @@ -53,7 +53,7 @@ gen8_upload_ps_extra(struct brw_context *brw, if (prog_data->persample_dispatch) dw1 |= GEN8_PSX_SHADER_IS_PER_SAMPLE; - /* _NEW_POLYGON */ + /* _NEW_MULTISAMPLE | BRW_NEW_CONSERVATIVE_RASTERIZATION */ if (prog_data->uses_sample_mask) { if (brw->gen >= 9) { if (prog_data->post_depth_coverage) @@ -131,7 +131,8 @@ const struct brw_tracked_state gen8_ps_extra = { .brw = BRW_NEW_BLORP | BRW_NEW_CONTEXT | BRW_NEW_FRAGMENT_PROGRAM | - BRW_NEW_FS_PROG_DATA, + BRW_NEW_FS_PROG_DATA | + BRW_NEW_CONSERVATIVE_RASTERIZATION, }, .emit = upload_ps_extra, }; @@ -291,8 +292,7 @@ upload_ps_state(struct brw_context *brw) const struct brw_tracked_state gen8_ps_state = { .dirty = { - .mesa = _NEW_MULTISAMPLE | - _NEW_POLYGON, + .mesa = _NEW_MULTISAMPLE, .brw = BRW_NEW_BATCH | BRW_NEW_BLORP | BRW_NEW_FS_PROG_DATA, diff --git a/src/mesa/drivers/dri/i965/gen8_sf_state.c b/src/mesa/drivers/dri/i965/gen8_sf_state.c index afe7b52b52b..41e94fb5040 100644 --- a/src/mesa/drivers/dri/i965/gen8_sf_state.c +++ b/src/mesa/drivers/dri/i965/gen8_sf_state.c @@ -319,7 +319,7 @@ upload_raster(struct brw_context *brw) } } - /* _NEW_POLYGON */ + /* BRW_NEW_CONSERVATIVE_RASTERIZATION */ if (ctx->IntelConservativeRasterization) { if (brw->gen >= 9) dw1 |= GEN9_RASTER_CONSERVATIVE_RASTERIZATION_ENABLE; @@ -344,7 +344,8 @@ const struct brw_tracked_state gen8_raster_state = { _NEW_SCISSOR | _NEW_TRANSFORM, .brw = BRW_NEW_BLORP | - BRW_NEW_CONTEXT, + BRW_NEW_CONTEXT | + BRW_NEW_CONSERVATIVE_RASTERIZATION, }, .emit = upload_raster, }; |