Module: Mesa Branch: master Commit: f0606cafe8330b10ad205b29267b4fba1dfbe7b2 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=f0606cafe8330b10ad205b29267b4fba1dfbe7b2
Author: Eric Anholt <[email protected]> Date: Wed Dec 16 11:03:17 2020 -0800 mesa/st: Update FP state when textures change with an ATI_fs bound. We may have to make a new ATI_fs variant when the texture target changes. Fixes a regression on piglit ati_fragment_shader-render-textargets on llvmpipe after the switch to NIR ATI_fragment_shader. Cc: mesa-stable Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8118> --- src/mesa/state_tracker/st_context.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index 5189b0cd692..771679a6b3a 100644 --- a/src/mesa/state_tracker/st_context.c +++ b/src/mesa/state_tracker/st_context.c @@ -275,9 +275,11 @@ st_invalidate_state(struct gl_context *ctx) (ST_NEW_SAMPLER_VIEWS | ST_NEW_SAMPLERS | ST_NEW_IMAGE_UNITS); - if (ctx->FragmentProgram._Current && - ctx->FragmentProgram._Current->ExternalSamplersUsed) { - st->dirty |= ST_NEW_FS_STATE; + if (ctx->FragmentProgram._Current) { + struct st_program *stfp = st_program(ctx->FragmentProgram._Current); + + if (stfp->Base.ExternalSamplersUsed || stfp->ati_fs) + st->dirty |= ST_NEW_FS_STATE; } } } _______________________________________________ mesa-commit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-commit
