Skip to content

Conversation

@kb173
Copy link

@kb173 kb173 commented Sep 27, 2023

We had performance issues with our sky shader and did some research and testing. In the announcement of sky shaders, we found this note:

If the sky is especially smooth, you can even render the entire thing to the radiance cubemap and then read from the cubemap when drawing to the screen.

We figured out that this optimization is really simple, but extremely valuable: it gives much finer control over the trade-off between visual fidelity and performance of the sky shader. With static skies, it can even completely eliminate the need to re-render the sky.

This optimization is probably a necessity for complex sky shaders, and since it was mentioned in their announcement, it seems to be an intended usage and not some optimization hack. I hope this addition to the docs helps others who struggle with optimizing their sky shader.

@Piralein Piralein added enhancement area:manual Issues and PRs related to the Manual/Tutorials section of the documentation labels Sep 27, 2023
Copy link
Member

@clayjohn clayjohn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great.

For the record, this is definitely the intended use-case of being able to read from RADIANCE, so it makes sense to have this called out clearly in the docs.

@mhilbrunner mhilbrunner merged commit 20a6f9e into godotengine:master Oct 3, 2023
@mhilbrunner
Copy link
Member

Merged. Thanks and congrats on your first merged contribution!

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

Labels

area:manual Issues and PRs related to the Manual/Tutorials section of the documentation enhancement topic:rendering

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants