Page MenuHome

Fix T74782: WorkBench TAA Artifacts During Painting/Drawing
ClosedPublic

Authored by Jeroen Bakker (jbakker) on Mar 24 2020, 3:32 PM.

Details

Summary

When the TAA is finished the screen can still be redrawn by other
operations without the TAA resets.
If that happened the TAA did add a blank sample to the result as the
scene wasn't drawn, but the was processed.

This patch also keeps a copy of the final image around so when other
operations happen workbench can just blit the final result back to the
viewport.

Diff Detail

Repository
rB Blender
Branch
T74782 (branched from master)
Build Status
Buildable 7282
Build 7282: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Mar 24 2020, 3:37 PM
Clément Foucault (fclem) requested changes to this revision.Mar 24 2020, 3:46 PM

I think we can do a bit smarter/simpler.

source/blender/draw/engines/workbench/workbench_effect_antialiasing.c
456

Always do this not only for last sample.

459

wpd->taa_sample_inv = 1.0f / min_ii(wpd->taa_sample + 1, wpd->taa_sample_len);

470

only increment if !taa_finished

This revision now requires changes to proceed.Mar 24 2020, 3:46 PM

Removed additional blitting

Jeroen Bakker (jbakker) edited the summary of this revision. (Show Details)Mar 24 2020, 3:59 PM
Jeroen Bakker (jbakker) marked 2 inline comments as done.
Jeroen Bakker (jbakker) added inline comments.
source/blender/draw/engines/workbench/workbench_effect_antialiasing.c
456

The !DRW_state_is_image_render does do this already for all samples. The last_sample is to kick AA resolving for image rendering. No need to do that for all samples

Jeroen Bakker (jbakker) edited the summary of this revision. (Show Details)

Fixed comments of code review

This revision is now accepted and ready to land.Mar 24 2020, 4:02 PM