HDRP, Scene is not visible with Fog in preview window

Hello,

I encountered a bug with the lastest Beta version and HDRP.
My scene uses volumetric fog and PBR sky.
When I toggle the Fog in the Scene preview window, my whole scene disappears and I only get a grey background. Also in the console the following messages appear:

Error: NullReferenceException: Object reference not set to an instance of an object (Line 342 in “\Library\PackageCache\com.unity.render-pipelines.high-definition@7.1.6\Runtime\Lighting\VolumetricLighting\VolumetricLighting.cs”

hdCamera.vBufferParams[1] = hdCamera.vBufferParams[0];```

Warning: XRSystem.ReleaseFrame() was not called!

While this seems to have no negative impact when running the build, it is pretty annoying to work with that in the editor. Despite the fact I can no longer make light adjustments without a Fog preview to compare.

Edit: Same bug found by another user: https://discussions.unity.com/t/768338

![5258291--525722--fog_error.png|1361x773](upload://jXBUXSreTC2XqNE7qFnHBKKX8OS.png)

Hey, while we are working on a fix, you can find an easy workaround for this here

1 Like