Search Issue Tracker

Won't Fix

Votes

1

Found in [Package]

8.0.1

Issue ID

1234300

Regression

No

[HDRP] Before Rendering injection point is one frame behind the BeginFrameRender method when using a Custom Pass

Package: Scriptable Render Pipeline HD

-

How to reproduce:
1. Open the "1234300 repro" project
2. Open the "SampleScene" located in Assets/Scenes folder
3. Make sure that the Scene window isn't visible
4. Press play

Expected result: the top two cubes and the bottom two cubes are in-synch with each other
Actual result: two cubes on the right side are one frame behind the two left cubes

Reproducible with package versions: 7.1.7 (2020.2.0a5), 7.1.8 (2019.3.8f1), 7.2.0 (2020.2.0a5), 7.2.1 (2020.2.0a5), 7.3.1 (2019.3.8f1), 8.0.1 (2020.1.0b3)
Could not test with package version: 7.0.1 and earlier (no Custom Pass)

Notes:
-This isn't reproducible if the Scene window is visible at the same time as the Game window
-When testing with 2020.2.05a the bug was reproducible but opening the Scene window wouldn't fix it
-This bug is reproducible most of the time, very rarely the cube pairs are in-synch without the Scene window being open
-If the project is paused, Scene window isn't open and the Game window is viewed step by step, some frames are loaded correctly immediately and some require to be moused over as shown in "MouseOverProblem.mp4"

  1. Resolution Note:

    Due to how the C++ rendering works, setting a property on a material during the frame is not supported.

    The BeginFrameRendering event is called before the rendering so you can do all the modifications in your materials here, but all the custom pass injection points are called within the frame. Note that to change something during the frame in an SRP, you must use a command buffer.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.