Skip to content

Commit

Permalink
Use xvp for multiview + debug view (#8222)
Browse files Browse the repository at this point in the history
When multiview is enabled with the combining debug option toggled on, we
use an intermediate buffer that requires us to use the entire area of
the buffer as the viewport. Use xvp in this case.
  • Loading branch information
z3moon authored Oct 22, 2024
1 parent 17e4d2b commit fa3a5d9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion filament/src/details/Renderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1110,7 +1110,9 @@ void FRenderer::renderJob(RootArenaScope& rootArenaScope, FView& view) {
// FIXME: we probably should take the dynamic scaling into account too
// if MSAA is enabled, we end-up rendering in an intermediate buffer. This is the only case where
// "!hasPostProcess" doesn't guarantee rendering into the swapchain.
passBuilder.scissorViewport(hasPostProcess || msaaOptions.enabled ? xvp : vp);
const bool useIntermediateBuffer = hasPostProcess || msaaOptions.enabled ||
(isRenderingMultiview && engine.debug.stereo.combine_multiview_images);
passBuilder.scissorViewport(useIntermediateBuffer ? xvp : vp);

// This one doesn't need to be a FrameGraph pass because it always happens by construction
// (i.e. it won't be culled, unless everything is culled), so no need to complexify things.
Expand Down

0 comments on commit fa3a5d9

Please sign in to comment.