Bring Back Scene View Nebulae

Previous commit broke scene view raymarching, now it's back
This commit is contained in:
Reinier Vens 2022-07-16 23:14:25 +01:00
commit 424010584c
4 changed files with 6 additions and 54 deletions

View file

@ -40,7 +40,7 @@ public enum Quality
/// <summary>
/// Cloud renderer post processing.
/// </summary>
//[ImageEffectAllowedInSceneView]
[ImageEffectAllowedInSceneView]
[ExecuteInEditMode,RequireComponent(typeof(Camera))]
[ImageEffectOpaque]
public class VolumeCloudRenderer : EffectBase
@ -134,6 +134,7 @@ public class VolumeCloudRenderer : EffectBase
mat.EnableKeyword("LOW_QUALITY");
}
mat.SetMatrix("_CamInvProj", (Camera.current.projectionMatrix * Camera.current.worldToCameraMatrix).inverse);
mat.SetVector("_ProjectionExtents", mcam.GetProjectionExtents());
mat.SetFloat("_RaymarchOffset", sequence.Get());
mat.SetVector("_TexelSize", undersampleBuffer.texelSize);