Unity.RenderPipelines.HighDefinition.Runtime.dll constantly recompiled.

Using Unity 2021.1.17f1, HDRP 11.

When entering play mode, the game starts properly, but after a couple of seconds inside play mode, the “Compiling C# scripts” dialog box pops up blocking the UI for about 10 seconds or longer before allowing to continue testing in play mode.

Checking under the project’s Library/ScriptAssemblies I can see that Unity.RenderPipelines.HighDefinition.Runtime.dll has been modified while the dialog was open. The same thing happens once again again after stopping play mode.

It’s not a small assembly (2.371 MB) so constantly recompiling is taking considerable time.

This was due to calling QualitySettings.SetQualityLevel on the Start method of a scene.
It is not completely clear if SetQualityLevel should be used at runtime with HDRP.

1 Like