Restore default sky roughness levels to 8.#116154
Merged
Merged
Conversation
…h non-metallic objects that have a very noisy HDRI
passivestar
approved these changes
Feb 11, 2026
Contributor
passivestar
left a comment
There was a problem hiding this comment.
I didn't compile this but I can confirm that setting roughness layers to 8 in 4.6 fixes the issues
akien-mga
approved these changes
Feb 11, 2026
BlueCube3310
approved these changes
Feb 11, 2026
Contributor
BlueCube3310
left a comment
There was a problem hiding this comment.
This makes me wonder if the roughness layer editor setting should just be ignored for mip-based roughness, and instead have it be automatically determined based on the envmap resolution.
It makes sense to keep it manually adjustable for layer-based roughness where the memory and computational costs are higher, and you can get away with ~4 layers and still have fairly decent-looking ambient/specular light.
Contributor
|
Thanks! |
Contributor
|
Cherry-picked for 4.6.2. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes: #116146
In 4.6 (#107902) we switched to using only 7 roughness levels by default so that we could have the same number of roughness levels when using the "update once" mode and the "update always mode". We also found it helped alleviate some artifacts along seams using our old seam blending approach. However, by the time we merged the work, we used a different approach for seam blending that didn't suffer from the same issue.
In hindsight, we should have switched back to 8 layers. But in testing we didn't notice any issues.
In the MRP from #116146, we have a very poorly formed HDR with 2 pixels that are 100x brighter than the next brightest handful of pixel and 10,000 times brighter than the average pixel. This causes really bad undersampling artifacts. Godot does the best it can to handle such HDRIs, but the results are not good (see #116146 (comment) for example).
In 4.5.1, this specific case looked okay because it uses full roughness and the environment map is downsampled so far (2x2 pixels per face) that the undersampling isn't visible. When using a lower roughness however, the problems are obvious.
In 4.6, we see an issue since the lowest mip level is 10x10 (8x8 + 1 pixel padding) and thus is slightly higher frequency and is able to show off the undersampling artifacts more.
By increasing the roughness levels by one, we decrease the final mip level to 6x6 (4x4 + 1 pixel padding) which much more closely matches the final frequency in 4.5.1. This gives the appearance of removing the artifacts in 4.6-stable. However, I want to strongly note that the generated environment map is bad in both cases. The particular case of a fully rough, non-metallic object looks better, but the actual result is still bad overall.
That being said, I think we should go ahead with this for 4.7 and 4.6.2 as matching the behaviour in 4.5.1 is important and worth doing on its own since we don't want to regress. Even though it is only going from bad behaviour to worse behaviour.
This PR

4.5.1

4.6

In the future #108127 will help tremendously. And should pave the way for further optimizations