Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the lightmapper not dilate before denoising. #82533

Merged
merged 1 commit into from
Sep 29, 2023

Conversation

DarioSamo
Copy link
Contributor

Dilating noisy data caused issues for the denoiser. Fixes #82526.

Upon merging the new denoiser, which filters out invalid pixels from being part of the algorithm, there was a problem where noisy pixels would be dilated first and the denoiser wouldn't be able to fix it.

In retrospect, the fix is fairly obvious and it makes sense: denoise valid data first, and then do the dilation with the valid data only, not the noisy pixels.

This fixes the noise present in seams that made its way in once the half pixel offset started being used in the denoiser branch.

Before

MASTER

After

DILATE_FIX

Dilating noisy data caused issues for the denoiser. Fixes godotengine#82526.
@DarioSamo DarioSamo requested a review from a team as a code owner September 29, 2023 15:40
@jcostello
Copy link
Contributor

I can confirm that this fixes the issue

Before
Screenshot from 2023-09-29 12-45-23

After
Screenshot from 2023-09-29 12-39-49

Sorry I moved the camera between screenshots

@akien-mga akien-mga added this to the 4.2 milestone Sep 29, 2023
@akien-mga akien-mga merged commit dd3dda7 into godotengine:master Sep 29, 2023
15 checks passed
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lightmap artifacts around geometry edges.
4 participants