Search Unity

Question Recorder not capturing motion blur HDRP

Discussion in 'High Definition Render Pipeline' started by troy_halsey, Feb 15, 2023.

  1. troy_halsey

    troy_halsey

    Joined:
    Oct 21, 2014
    Posts:
    68
    I have been experimenting with various settings and have yet to crack motion blur being captured by the recorder either as a still or in video. Even using accumulation, I can't seem to capture it in the finished video. Doing archviz animations and this would be awesome for blurring low poly background people.
     
  2. cguertin

    cguertin

    Unity Technologies

    Joined:
    Aug 20, 2019
    Posts:
    83
    Hey @troy_halsey! Do you have preference for Motion Blur Post-Process (MBPP) vs. Accumulation motion blur (AMB)?

    I'm asking because they would have slightly different troubleshooting steps (and also should not be used together as it might cause unwanted artifacts).

    You should be able to use either for recording but:
    • Motion-blur post-process is optimized to run in real-time. Quality will be slightly lower but may not be noticeable depending on the project.
    • Accumulation Motion Blur will not run in real-time. The recording will take slightly longer depending on the number of accumulation samples but will produce higher quality results than the post-process in most situations.
    The motion blur trails may also not be very visible if objects in the scene move too slowly. Just for debugging purposes until we figure this out I would suggest adding something that move very quickly in your scene (ex: a sphere translating the whole width of the GameView in a couple of frames)
     
  3. troy_halsey

    troy_halsey

    Joined:
    Oct 21, 2014
    Posts:
    68
    Thank you so much for your suggestion. I will do that debug test, but have done that test to some degree with no luck…even maxing out the settings. Also, I am using HDRP…I am not 100% tracking, but when we do final captures we will use accumulation from 12-120 in the recorder settings. As for MBPP vs accumulation - I am fuzzy on what you mean…I am using the motion blur in the post processing stack in the hdrp volume. Thank you again
     
  4. cguertin

    cguertin

    Unity Technologies

    Joined:
    Aug 20, 2019
    Posts:
    83
    Perfect, this is what I meant by MBPP (I don't think it's a real acronym, just wanted to make it easier to differentiate ;)). In this case you would not want to add accumulation because it could cause unwanted artifacts.

    For MBPP, what you see in the GameView should also be what you get from the Recorder. So if you enter PlayMode and see motion blur trails, these would also be reflected in the recording. Adjusting the intensity while in PlayMode should also visibly change the length of the motion blur trails assuming the objects are moving fast enough to be noticeable:
    mb_intensity.gif

    I did a quick recording test with a moving sphere. The MBPP settings are using the defaults except for Intensity which I set to 1 (default=0). Here is what my project looks like:
    Screenshot 2023-02-17 093641.png

    And this is the result from the Recorder (Frame 5):
    Image Sequence_002_0005.png
     
  5. eliphat

    eliphat

    Joined:
    Jul 4, 2017
    Posts:
    48
    It seems that with both MBPP and AMB on, only the first sub-frame has its MBPP while other frames are kept clear without any motion blur. I think it would be better if every sub-frame has MBPP as an initial approximation to the MB integral. I'm not sure whether it is a problem with the recorder or HDRP.
    upload_2023-2-22_14-41-51.png
    A textured cube captured at 30fps at 20m/s from left to right about 15m in front of the camera.
    Notice how the left side is clear, while the right side has some MB.
     
  6. eliphat

    eliphat

    Joined:
    Jul 4, 2017
    Posts:
    48
    upload_2023-2-22_14-47-2.png
    In case that is not clear, I crushed MBPP intensity to 20. Anyways, the render around the edges of the left cube frame is looking a bit weird.
     
  7. cguertin

    cguertin

    Unity Technologies

    Joined:
    Aug 20, 2019
    Posts:
    83
    Hey @eliphat ! AMB and MBPP are not designed to be used together. They are two different techniques to achieve motion blur and only one of them should be used depending on your project requirements:
    Is there a particular reason you would need both at the same time?
     
  8. eliphat

    eliphat

    Joined:
    Jul 4, 2017
    Posts:
    48
    AMB and MBPP are different ways to approximate the integral of light intensity among the motion path, one by sampling and one by linear convolution approximation.

    Basically, I would need 10-12 subframes in AMB to get visually good results without MBPP. But with local linear approximation MBPP inside each sub-frame, I would only need 3-4 subframes for accumulation to get almost the same MB quality (in Built-in RP I have a post-processing effect to do the accumulation, before I switched to HDRP recently). This is 4x boost in my situations as rendering each sub-frame is the most time consuming part here.