Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Bug Path Tracing not progressing in play mode or build

Discussion in 'High Definition Render Pipeline' started by ben_johncock, Nov 7, 2023.

  1. ben_johncock

    ben_johncock

    Joined:
    Sep 18, 2023
    Posts:
    3
    Hey,
    Im trying to get Path Tracing working in build as an initial test to eventually have it togglable for a screenshot mode.
    My issue is that when in editor play mode or running a build, the image doesnt resolve and the loading bar doesnt move.

    Using HDRP version 2023.1.18f1
    Thanks
     

    Attached Files:

  2. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    755
    Can you share which version you are using?
    It completely should work as many other have implemented this solution.
     
    ben_johncock likes this.
  3. Remy_Unity

    Remy_Unity

    Unity Technologies

    Joined:
    Oct 3, 2017
    Posts:
    690
    I did a try with the HDRP sample, and can also confirm that it works.
    But you need to fully freeze the camera movement, else any small change will trigger a refresh of the path-tracer rendering. In the case of the sample scene, disabling the CinemachineBrain was enough.
     
    ben_johncock likes this.
  4. ben_johncock

    ben_johncock

    Joined:
    Sep 18, 2023
    Posts:
    3
    Thanks for the responses, my issue turned out to be animated people preventing it from resolving. I ended up just setting the timescale to 0 before getting the screenshot and that worked.
    Im pretty happy with it now. The only issue is now is that I need "Realtime Raytracing" enabled for the path tracer but I dont need it for my SSGI settings that I use when im not in screenshot mode.
    upload_2023-11-8_12-1-47.png
    Just having Realtime Raytracing enabled has dropped my average FPS from around 90 to 40. So I was wandering if its possible to enable and disable this on runtime / have it toggleable with the path tracing?
    Thanks
     
  5. chap-unity

    chap-unity

    Unity Technologies

    Joined:
    Nov 4, 2019
    Posts:
    755
    This seems odd to me as well, thanks for reporting it, toggling this should allocate more buffers but until you actually use any ray traced effects (like RT shadows or RTGI) it shouldn't have that big of an impact on FPS alone, I'll try to investigate when I have some time.

    In the meantime, you could create a new quality setting (by duplicating your HDRP Asset) and toggle realtime raytracing on the new one.
    That way, you just need to switch quality setting when going from/to screenshot mode.
     
    ben_johncock likes this.