ssr fix and add some documents #21877
Open
+2
−2
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.
Objective
Screen space reflection didn't work for my program, so I tried cloning bevy repo and running the ssr example to see whether it works or not, and it didn't. I figured out that the problem is that
prepare_ssr_pipelinessystem only runs for views withExtractedAtmosphere. So I removed this filter because it already usesHas<ExtractedAtmosphere>. And the example works afterwards.I later found that the
With<ExtractedAtmosphere>filter is not added to bevy 0.17, so the problem in my own program is not the same as the ssr example. I compared the ssr example and my program and found that I didn't addDefaultOpaqueRendererMethod::deferred()resource. So I added a few docs to state that deferred rendering is not automatically enabled when ssr is added.Solution
With<ExtractedAtmosphere>filter inprepare_ssr_pipelines.Testing
I tested the ssr example and atmosphere example and both look fine.