// This file should be used as a container for things on its
// way to being deprecated and removed in future releases
using System;
using System.ComponentModel;
namespace UnityEngine.Rendering.Universal
{
public abstract partial class ScriptableRenderPass
{
// This callback method will be removed. Please use OnCameraCleanup() instead.
///
/// Cleanup any allocated resources that were created during the execution of this render pass.
///
/// Use this CommandBuffer to cleanup any generated data.
[EditorBrowsable(EditorBrowsableState.Never)]
public virtual void FrameCleanup(CommandBuffer cmd) => OnCameraCleanup(cmd);
}
namespace Internal
{
public partial class AdditionalLightsShadowCasterPass
{
///
/// The ID for the additional shadows buffer ID.
/// This has been deprecated. Shadow slice matrix is now passed to the GPU using an entry in buffer m_AdditionalLightsWorldToShadow_SSBO.
///
[Obsolete("AdditionalLightsShadowCasterPass.m_AdditionalShadowsBufferId was deprecated. Shadow slice matrix is now passed to the GPU using an entry in buffer m_AdditionalLightsWorldToShadow_SSBO #from(2021.1) #breakingFrom(2023.1)", true)]
public static int m_AdditionalShadowsBufferId;
///
/// The ID for the additional shadows buffer ID.
/// This has been deprecated. hadow slice index is now passed to the GPU using last member of an entry in buffer m_AdditionalShadowParams_SSBO.
///
[Obsolete("AdditionalLightsShadowCasterPass.m_AdditionalShadowsIndicesId was deprecated. Shadow slice index is now passed to the GPU using last member of an entry in buffer m_AdditionalShadowParams_SSBO #from(2021.1) #breakingFrom(2023.1)", true)]
public static int m_AdditionalShadowsIndicesId;
}
}
///
/// Previously contained the settings to control how many cascades to use. It is now deprecated.
///
[Obsolete("This is obsolete, please use shadowCascadeCount instead. #from(2021.1) #breakingFrom(2023.1)", true)]
public enum ShadowCascadesOption
{
///
/// No cascades used for the shadows
///
NoCascades,
///
/// Two cascades used for the shadows
///
TwoCascades,
///
/// Four cascades used for the shadows
///
FourCascades,
}
///
/// Specifies the logging level for shader variants.
/// This is obsolete, UnityEngine.Rendering.ShaderVariantLogLevel instead.
///
[Obsolete("This is obsolete, UnityEngine.Rendering.ShaderVariantLogLevel instead. #from(2022.2) #breakingFrom(2023.1)", true)]
public enum ShaderVariantLogLevel
{
/// Disable all log for shader variants.
Disabled,
/// Only logs SRP Shaders when logging shader variants.
[InspectorName("Only URP Shaders")]
OnlyUniversalRPShaders,
/// Logs all shader variants.
[InspectorName("All Shaders")]
AllShaders
}
public partial class UniversalRenderPipelineAsset
{
#if UNITY_EDITOR
[Obsolete("Editor resources are stored directly into GraphicsSettings. #from(2023.3)")]
public static readonly string editorResourcesGUID = "a3d8d823eedde654bb4c11a1cfaf1abb";
#endif
[SerializeField] int m_ShaderVariantLogLevel;
#pragma warning disable 618 // Obsolete warning
///
/// Previously returned the shader variant log level for this Render Pipeline Asset but is now deprecated.
///
[Obsolete("Use GraphicsSettings.GetRenderPipelineSettings().shaderVariantLogLevel instead. #from(2022.2)")]
public ShaderVariantLogLevel shaderVariantLogLevel
{
get => (ShaderVariantLogLevel)GraphicsSettings.GetRenderPipelineSettings().shaderVariantLogLevel;
set => GraphicsSettings.GetRenderPipelineSettings().shaderVariantLogLevel = (Rendering.ShaderVariantLogLevel)value;
}
#pragma warning restore 618 // Obsolete warning
#pragma warning disable 618 // Obsolete warning
[Obsolete("This is obsolete, please use shadowCascadeCount instead. #from(2021.1)")]
[SerializeField] ShadowCascadesOption m_ShadowCascades = ShadowCascadesOption.NoCascades;
///
/// Previously used insted of shadowCascadeCount. Please use that instead.
///
[Obsolete("This is obsolete, please use shadowCascadeCount instead. #from(2021.1) #breakingFrom(2023.1)", true)]
public ShadowCascadesOption shadowCascadeOption
{
get
{
switch (shadowCascadeCount)
{
case 1: return ShadowCascadesOption.NoCascades;
case 2: return ShadowCascadesOption.TwoCascades;
case 4: return ShadowCascadesOption.FourCascades;
default: throw new InvalidOperationException("Cascade count is not compatible with obsolete API, please use shadowCascadeCount instead.");
}
;
}
set
{
switch (value)
{
case ShadowCascadesOption.NoCascades:
shadowCascadeCount = 1;
break;
case ShadowCascadesOption.TwoCascades:
shadowCascadeCount = 2;
break;
case ShadowCascadesOption.FourCascades:
shadowCascadeCount = 4;
break;
default:
throw new InvalidOperationException("Cascade count is not compatible with obsolete API, please use shadowCascadeCount instead.");
}
}
}
#pragma warning restore 618 // Obsolete warning
///
/// Class containing texture resources used in URP.
///
[Serializable, ReloadGroup]
[Obsolete("Moved to UniversalRenderPipelineRuntimeTextures on GraphicsSettings. #from(2023.3)")]
public sealed class TextureResources
{
///
/// Pre-baked blue noise textures.
///
[Reload("Textures/BlueNoise64/L/LDR_LLL1_0.png")]
public Texture2D blueNoise64LTex;
///
/// Bayer matrix texture.
///
[Reload("Textures/BayerMatrix.png")]
public Texture2D bayerMatrixTex;
///
/// Check if the textures need reloading.
///
/// True if any of the textures need reloading.
public bool NeedsReload()
{
return blueNoise64LTex == null || bayerMatrixTex == null;
}
}
[Obsolete("Moved to UniversalRenderPipelineRuntimeTextures on GraphicsSettings. #from(2023.3)")]
[SerializeField]
TextureResources m_Textures;
///
/// Returns asset texture resources
///
[Obsolete("Moved to UniversalRenderPipelineRuntimeTextures on GraphicsSettings. #from(2023.3)")]
public TextureResources textures
{
get
{
if (m_Textures == null)
m_Textures = new TextureResources();
#if UNITY_EDITOR
if (m_Textures.NeedsReload())
ResourceReloader.ReloadAllNullIn(this, packagePath);
#endif
return m_Textures;
}
}
///
/// Controls when URP renders via an intermediate texture.
///
[Obsolete("This property is not used. #from(6000.3)", false)]
public IntermediateTextureMode intermediateTextureMode
{
get => default;
set {}
}
}
public abstract partial class ScriptableRenderer
{
// Deprecated in 10.x
///
/// The render target identifier for camera depth.
/// This is obsolete, cameraDepth has been renamed to cameraDepthTarget.
///
[Obsolete("cameraDepth has been renamed to cameraDepthTarget. #from(2021.1) #breakingFrom(2023.1) (UnityUpgradable) -> cameraDepthTarget", true)]
[EditorBrowsable(EditorBrowsableState.Never)]
public RenderTargetIdentifier cameraDepth
{
get => m_CameraDepthTarget.nameID;
}
}
public abstract partial class ScriptableRendererData
{
///
/// Class contains references to shader resources used by Rendering Debugger.
///
[Obsolete("Moved to UniversalRenderPipelineDebugShaders on GraphicsSettings. #from(2023.3)")]
[Serializable, ReloadGroup]
public sealed class DebugShaderResources
{
///
/// Debug shader used to output interpolated vertex attributes.
///
[Obsolete("Moved to UniversalRenderPipelineDebugShaders on GraphicsSettings. #from(2023.3)")]
[Reload("Shaders/Debug/DebugReplacement.shader")]
public Shader debugReplacementPS;
///
/// Debug shader used to output HDR Chromacity mapping.
///
[Obsolete("Moved to UniversalRenderPipelineDebugShaders on GraphicsSettings. #from(2023.3)")]
[Reload("Shaders/Debug/HDRDebugView.shader")]
public Shader hdrDebugViewPS;
#if UNITY_EDITOR
///
/// Debug shader used to output world position and world normal for the pixel under the cursor.
///
[Obsolete("Moved to UniversalRenderPipelineDebugShaders on GraphicsSettings. #from(2023.3)")]
[Reload("Shaders/Debug/ProbeVolumeSamplingDebugPositionNormal.compute")]
public ComputeShader probeVolumeSamplingDebugComputeShader;
#endif
}
///
/// Container for shader resources used by Rendering Debugger.
///
[Obsolete("Moved to UniversalRenderPipelineDebugShaders on GraphicsSettings. #from(2023.3)")]
public DebugShaderResources debugShaders;
///
/// Class contains references to shader resources used by APV.
///
[Serializable, ReloadGroup]
[Obsolete("Probe volume debug resource are now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public sealed class ProbeVolumeResources
{
///
/// Debug shader used to render probes in the volume.
///
[Obsolete("This shader is now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public Shader probeVolumeDebugShader;
///
/// Debug shader used to display fragmentation of the GPU memory.
///
[Obsolete("This shader is now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public Shader probeVolumeFragmentationDebugShader;
///
/// Debug shader used to draw the offset direction used for a probe.
///
[Obsolete("This shader is now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public Shader probeVolumeOffsetDebugShader;
///
/// Debug shader used to draw the sampling weights of the probe volume.
///
[Obsolete("This shader is now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public Shader probeVolumeSamplingDebugShader;
///
/// Debug mesh used to draw the sampling weights of the probe volume.
///
[Obsolete("This shader is now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public Mesh probeSamplingDebugMesh;
///
/// Texture with the numbers dor sampling weights.
///
[Obsolete("This shader is now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public Texture2D probeSamplingDebugTexture;
///
/// Compute Shader used for Blending.
///
[Obsolete("This shader is now in the ProbeVolumeRuntimeResources class. #from(2023.3)")]
public ComputeShader probeVolumeBlendStatesCS;
}
///
/// Probe volume resources used by URP
///
[Obsolete("Probe volume debug resource are now in the ProbeVolumeDebugResources class. #from(2023.3)")]
public ProbeVolumeResources probeVolumeResources;
}
public sealed partial class Bloom : VolumeComponent, IPostProcessComponent
{
// Deprecated in 13.x.x
///
/// The number of final iterations to skip in the effect processing sequence.
/// This is obsolete, please use maxIterations instead.
///
[Obsolete("This is obsolete, please use maxIterations instead. #from(2022.2) #breakingFrom(2023.1)", true)]
[Tooltip("The number of final iterations to skip in the effect processing sequence.")]
public ClampedIntParameter skipIterations = new ClampedIntParameter(1, 0, 16);
}
///
/// Class containing shader resources needed in URP for XR.
///
///
[Serializable]
[Obsolete("Moved to UniversalRenderPipelineRuntimeXRResources on GraphicsSettings. #from(2023.3)")]
public class XRSystemData : ScriptableObject
{
///
/// Class containing shader resources used in URP for XR.
///
[Serializable, ReloadGroup]
[Obsolete("Moved to UniversalRenderPipelineRuntimeXRResources on GraphicsSettings. #from(2023.3)")]
public sealed class ShaderResources
{
///
/// XR Occlusion mesh shader.
///
[Reload("Shaders/XR/XROcclusionMesh.shader")]
public Shader xrOcclusionMeshPS;
///
/// XR Mirror View shader.
///
[Reload("Shaders/XR/XRMirrorView.shader")]
public Shader xrMirrorViewPS;
}
///
/// Shader resources used in URP for XR.
///
[Obsolete("Moved to UniversalRenderPipelineRuntimeXRResources on GraphicsSettings. #from(2023.3)")]
public ShaderResources shaders;
}
public partial class UniversalRendererData
{
#if ENABLE_VR && ENABLE_XR_MODULE
///
/// Shader resources needed in URP for XR.
///
[Obsolete("Moved to UniversalRenderPipelineRuntimeXRResources on GraphicsSettings. #from(2023.3)")]
//[Reload("Runtime/Data/XRSystemData.asset")]
public XRSystemData xrSystemData;
#endif
}
/// Class containing shader and texture resources needed in URP.
///
///
///
[Obsolete("Moved to GraphicsSettings. #from(2023.3)")]
public class UniversalRenderPipelineEditorResources : ScriptableObject
{
///
/// Class containing shader resources used in URP.
///
[Serializable, ReloadGroup]
[Obsolete("UniversalRenderPipelineEditorResources.ShaderResources is obsolete GraphicsSettings.TryGetRenderPipelineSettings(). #from(2023.3)")]
public sealed class ShaderResources
{
///
/// Autodesk Interactive ShaderGraph shader.
///
[Reload("Shaders/AutodeskInteractive/AutodeskInteractive.shadergraph")]
public Shader autodeskInteractivePS;
///
/// Autodesk Interactive Transparent ShaderGraph shader.
///
[Reload("Shaders/AutodeskInteractive/AutodeskInteractiveTransparent.shadergraph")]
public Shader autodeskInteractiveTransparentPS;
///
/// Autodesk Interactive Masked ShaderGraph shader.
///
[Reload("Shaders/AutodeskInteractive/AutodeskInteractiveMasked.shadergraph")]
public Shader autodeskInteractiveMaskedPS;
///
/// Terrain Detail Lit shader.
///
[Reload("Shaders/Terrain/TerrainDetailLit.shader")]
public Shader terrainDetailLitPS;
///
/// Terrain Detail Grass shader.
///
[Reload("Shaders/Terrain/WavingGrass.shader")]
public Shader terrainDetailGrassPS;
///
/// Waving Grass Billboard shader.
///
[Reload("Shaders/Terrain/WavingGrassBillboard.shader")]
public Shader terrainDetailGrassBillboardPS;
///
/// SpeedTree7 shader.
///
[Reload("Shaders/Nature/SpeedTree7.shader")]
public Shader defaultSpeedTree7PS;
///
/// SpeedTree8 ShaderGraph shader.
///
[Reload("Shaders/Nature/SpeedTree8_PBRLit.shadergraph")]
public Shader defaultSpeedTree8PS;
}
///
/// Class containing material resources used in URP.
///
[Serializable, ReloadGroup]
[Obsolete("UniversalRenderPipelineEditorResources.MaterialResources is obsolete GraphicsSettings.TryGetRenderPipelineSettings(). #from(2023.3)")]
public sealed class MaterialResources
{
///
/// Lit material.
///
[Reload("Runtime/Materials/Lit.mat")]
public Material lit;
// particleLit is the URP default material for new particle systems.
// ParticlesUnlit.mat is closest match to the built-in shader.
// This is correct (current 22.2) despite the Lit/Unlit naming conflict.
///
/// Particle Lit material.
///
[Reload("Runtime/Materials/ParticlesUnlit.mat")]
public Material particleLit;
///
/// Terrain Lit material.
///
[Reload("Runtime/Materials/TerrainLit.mat")]
public Material terrainLit;
///
/// Decal material.
///
[Reload("Runtime/Materials/Decal.mat")]
public Material decal;
}
///
/// Shader resources used in URP.
///
[Obsolete("UniversalRenderPipelineEditorResources.ShaderResources is obsolete GraphicsSettings.TryGetRenderPipelineSettings(). #from(2023.3)")]
public ShaderResources shaders;
///
/// Material resources used in URP.
///
[Obsolete("UniversalRenderPipelineEditorResources.MaterialResources is obsolete GraphicsSettings.TryGetRenderPipelineSettings(). #from(2023.3)")]
public MaterialResources materials;
}
#if UNITY_EDITOR
[UnityEditor.CustomEditor(typeof(UniversalRenderPipelineEditorResources), true)]
[Obsolete("Deprectated alongside with UniversalRenderPipelineEditorResources. #from(2023.3)")]
class UniversalRenderPipelineEditorResourcesEditor : UnityEditor.Editor
{
///
public override void OnInspectorGUI()
{
DrawDefaultInspector();
// Add a "Reload All" button in inspector when we are in developer's mode
if (UnityEditor.EditorPrefs.GetBool("DeveloperMode") && GUILayout.Button("Reload All"))
{
var resources = target as UniversalRenderPipelineEditorResources;
resources.materials = null;
resources.shaders = null;
ResourceReloader.ReloadAllNullIn(target, UniversalRenderPipelineAsset.packagePath);
}
}
}
#endif
///
/// Class containing shader resources used in URP.
///
[Serializable, ReloadGroup]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public sealed class ShaderResources
{
///
/// Blit shader.
///
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
[Reload("Shaders/Utils/Blit.shader")]
public Shader blitPS;
///
/// Copy Depth shader.
///
[Reload("Shaders/Utils/CopyDepth.shader")]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public Shader copyDepthPS;
///
/// Screen Space Shadows shader.
///
[Obsolete("Obsolete, this feature will be supported by new 'ScreenSpaceShadows' renderer feature. #from(2023.3) #breakingFrom(2023.3)", true)]
public Shader screenSpaceShadowPS = null;
///
/// Sampling shader.
///
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
[Reload("Shaders/Utils/Sampling.shader")]
public Shader samplingPS;
///
/// Stencil Deferred shader.
///
[Reload("Shaders/Utils/StencilDeferred.shader")]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public Shader stencilDeferredPS;
///
/// Fallback error shader.
///
[Reload("Shaders/Utils/FallbackError.shader")]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public Shader fallbackErrorPS;
///
/// Fallback loading shader.
///
[Reload("Shaders/Utils/FallbackLoading.shader")]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public Shader fallbackLoadingPS;
///
/// Material Error shader.
///
[Obsolete("Use fallbackErrorPS instead. #from(2023.3) #breakingFrom(2023.3)", true)]
public Shader materialErrorPS = null;
// Core blitter shaders, adapted from HDRP
// TODO: move to core and share with HDRP
[Reload("Shaders/Utils/CoreBlit.shader"), SerializeField]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
internal Shader coreBlitPS;
[Reload("Shaders/Utils/CoreBlitColorAndDepth.shader"), SerializeField]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
internal Shader coreBlitColorAndDepthPS;
///
/// Blit shader that blits UI Overlay and performs HDR encoding.
///
[Reload("Shaders/Utils/BlitHDROverlay.shader"), SerializeField]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
internal Shader blitHDROverlay;
///
/// Camera Motion Vectors shader.
///
[Reload("Shaders/CameraMotionVectors.shader")]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public Shader cameraMotionVector;
///
/// Screen Space Lens Flare shader.
///
[Reload("Shaders/PostProcessing/LensFlareScreenSpace.shader")]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public Shader screenSpaceLensFlare;
///
/// Data Driven Lens Flare shader.
///
[Reload("Shaders/PostProcessing/LensFlareDataDriven.shader")]
[Obsolete("Moved to UniversalRenderPipelineRuntimeShaders on GraphicsSettings. #from(2023.3)")]
public Shader dataDrivenLensFlare;
}
partial class UniversalRenderPipelineGlobalSettings
{
#pragma warning disable 0414
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal ShaderStrippingSetting m_ShaderStrippingSetting = new();
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal URPShaderStrippingSetting m_URPShaderStrippingSetting = new();
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal Rendering.ShaderVariantLogLevel m_ShaderVariantLogLevel = Rendering.ShaderVariantLogLevel.Disabled;
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal bool m_ExportShaderVariants = true;
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal bool m_StripDebugVariants = true;
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal bool m_StripUnusedPostProcessingVariants = false;
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal bool m_StripUnusedVariants = true;
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal bool m_StripScreenCoordOverrideVariants = true;
#pragma warning restore 0414
///
/// If this property is true, Unity strips the LOD variants if the LOD cross-fade feature (UniversalRenderingPipelineAsset.enableLODCrossFade) is disabled.
///
[Obsolete("No longer used as Shader Prefiltering automatically strips out unused LOD Crossfade variants. Please use the LOD Crossfade setting in the URP Asset to disable the feature if not used. #from(2023.1)")]
public bool stripUnusedLODCrossFadeVariants { get => false; set { } }
///
/// Controls whether debug display shaders for Rendering Debugger are available in Player builds.
///
[Obsolete("Please use stripRuntimeDebugShaders instead. #from(2023.1)")]
public bool supportRuntimeDebugDisplay = false;
[SerializeField, Obsolete("Keep for migration. #from(2023.2)")] internal bool m_EnableRenderGraph;
}
#if !URP_COMPATIBILITY_MODE
internal struct DeprecationMessage
{
internal const string CompatibilityScriptingAPIHidden = "This rendering path is for Compatibility Mode only which has been deprecated and hidden behind URP_COMPATIBILITY_MODE define. This will do nothing.";
}
partial class UniversalCameraData
{
///
/// Returns the camera GPU projection matrix. This contains platform specific changes to handle y-flip and reverse z. Includes camera jitter if required by active features.
/// Similar to GL.GetGPUProjectionMatrix but queries URP internal state to know if the pipeline is rendering to render texture.
/// For more info on platform differences regarding camera projection check: https://docs.unity3d.com/Manual/SL-PlatformDifferences.html
///
/// View index in case of stereo rendering. By default viewIndex is set to 0.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public Matrix4x4 GetGPUProjectionMatrix(int viewIndex = 0) => default;
///
/// Returns the camera GPU projection matrix. This contains platform specific changes to handle y-flip and reverse z. Does not include any camera jitter.
/// Similar to GL.GetGPUProjectionMatrix but queries URP internal state to know if the pipeline is rendering to render texture.
/// For more info on platform differences regarding camera projection check: https://docs.unity3d.com/Manual/SL-PlatformDifferences.html
///
/// View index in case of stereo rendering. By default viewIndex is set to 0.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public Matrix4x4 GetGPUProjectionMatrixNoJitter(int viewIndex = 0) => default;
///
/// True if the camera device projection matrix is flipped. This happens when the pipeline is rendering
/// to a render texture in non OpenGL platforms. If you are doing a custom Blit pass to copy camera textures
/// (_CameraColorTexture, _CameraDepthAttachment) you need to check this flag to know if you should flip the
/// matrix when rendering with for cmd.Draw* and reading from camera textures.
///
/// True if the camera device projection matrix is flipped.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public bool IsCameraProjectionMatrixFlipped() => default;
}
public abstract partial class ScriptableRenderPass
{
///
/// RTHandle alias for BuiltinRenderTextureType.CameraTarget which is the backbuffer.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public static RTHandle k_CameraTarget = null;
///
/// List for the g-buffer attachment handles.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public RTHandle[] colorAttachmentHandles => null;
///
/// The main color attachment handle.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public RTHandle colorAttachmentHandle => null;
///
/// The depth attachment handle.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public RTHandle depthAttachmentHandle => null;
///
/// The store actions for Color.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public RenderBufferStoreAction[] colorStoreActions => null;
///
/// The store actions for Depth.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public RenderBufferStoreAction depthStoreAction => default;
///
/// The flag to use when clearing.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public ClearFlag clearFlag => default;
///
/// The color value to use when clearing.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public Color clearColor => default;
///
/// Configures the Store Action for a color attachment of this render pass.
///
/// RenderBufferStoreAction to use
/// Index of the color attachment
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureColorStoreAction(RenderBufferStoreAction storeAction, uint attachmentIndex = 0) { }
///
/// Configures the Store Actions for all the color attachments of this render pass.
///
/// Array of RenderBufferStoreActions to use
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureColorStoreActions(RenderBufferStoreAction[] storeActions) { }
///
/// Configures the Store Action for the depth attachment of this render pass.
///
/// RenderBufferStoreAction to use
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureDepthStoreAction(RenderBufferStoreAction storeAction) { }
///
/// Resets render targets to default.
/// This method effectively reset changes done by ConfigureTarget.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ResetTarget() { }
///
/// Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget.
/// This method should be called inside Configure.
///
/// Color attachment handle.
/// Depth attachment handle.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureTarget(RTHandle colorAttachment, RTHandle depthAttachment) { }
///
/// Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget.
/// This method should be called inside Configure.
///
/// Color attachment handle.
/// Depth attachment handle.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureTarget(RTHandle[] colorAttachments, RTHandle depthAttachment) { }
///
/// Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget.
/// This method should be called inside Configure.
///
/// Color attachment handle.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureTarget(RTHandle colorAttachment) { }
///
/// Configures render targets for this render pass. Call this instead of CommandBuffer.SetRenderTarget.
/// This method should be called inside Configure.
///
/// Color attachment handle.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureTarget(RTHandle[] colorAttachments) { }
///
/// Configures clearing for the render targets for this render pass. Call this inside Configure.
///
/// ClearFlag containing information about what targets to clear.
/// Clear color.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureClear(ClearFlag clearFlag, Color clearColor) { }
///
/// This method is called by the renderer before rendering a camera
/// Override this method if you need to to configure render targets and their clear state, and to create temporary render target textures.
/// If a render pass doesn't override this method, this render pass renders to the active Camera's render target.
/// You should never call CommandBuffer.SetRenderTarget. Instead call ConfigureTarget and ConfigureClear.
///
/// CommandBuffer to enqueue rendering commands. This will be executed by the pipeline.
/// Current rendering state information
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public virtual void OnCameraSetup(CommandBuffer cmd, ref RenderingData renderingData) { }
///
/// This method is called by the renderer before executing the render pass.
/// Override this method if you need to to configure render targets and their clear state, and to create temporary render target textures.
/// If a render pass doesn't override this method, this render pass renders to the active Camera's render target.
/// You should never call CommandBuffer.SetRenderTarget. Instead call ConfigureTarget and ConfigureClear.
///
/// CommandBuffer to enqueue rendering commands. This will be executed by the pipeline.
/// Render texture descriptor of the camera render target.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public virtual void Configure(CommandBuffer cmd, RenderTextureDescriptor cameraTextureDescriptor) { }
///
/// Called upon finish rendering a camera stack. You can use this callback to release any resources created
/// by this render pass that need to be cleanup once all cameras in the stack have finished rendering.
/// This method will be called once after rendering the last camera in the camera stack.
/// Cameras that don't have an explicit camera stack are also considered stacked rendering.
/// In that case the Base camera is the first and last camera in the stack.
///
/// Use this CommandBuffer to cleanup any generated data
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public virtual void OnFinishCameraStackRendering(CommandBuffer cmd) { }
///
/// Execute the pass. This is where custom rendering occurs. Specific details are left to the implementation
///
/// Use this render context to issue any draw commands during execution
/// Current rendering state information
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public virtual void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
///
/// Add a blit command to the context for execution. This changes the active render target in the ScriptableRenderer to
/// destination.
///
/// Command buffer to record command for execution.
/// Source texture or target handle to blit from.
/// Destination texture or target handle to blit into. This becomes the renderer active render target.
/// Material to use.
/// Shader pass to use. Default is 0.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void Blit(CommandBuffer cmd, RTHandle source, RTHandle destination, Material material = null, int passIndex = 0) { }
///
/// Add a blit command to the context for execution. This applies the material to the color target.
///
/// Command buffer to record command for execution.
/// RenderingData to access the active renderer.
/// Material to use.
/// Shader pass to use. Default is 0.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void Blit(CommandBuffer cmd, ref RenderingData data, Material material, int passIndex = 0) { }
///
/// Add a blit command to the context for execution. This applies the material to the color target.
///
/// Command buffer to record command for execution.
/// RenderingData to access the active renderer.
/// Source texture or target identifier to blit from.
/// Material to use.
/// Shader pass to use. Default is 0.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void Blit(CommandBuffer cmd, ref RenderingData data, RTHandle source, Material material, int passIndex = 0) { }
}
#if ENABLE_VR && ENABLE_XR_MODULE
partial class XROcclusionMeshPass
{
///
/// Used to indicate if the active target of the pass is the back buffer
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public bool m_IsActiveTargetBackBuffer;
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
#endif
partial class DecalRendererFeature
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void SetupRenderPasses(ScriptableRenderer renderer, in RenderingData renderingData) { }
}
partial class ScriptableRenderer
{
///
/// Override to provide a custom profiling name
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
protected ProfilingSampler profilingExecute { get; set; }
///
/// Set camera matrices. This method will set UNITY_MATRIX_V, UNITY_MATRIX_P, UNITY_MATRIX_VP to the camera matrices.
/// Additionally this will also set unity_CameraProjection and unity_CameraProjection.
/// If setInverseMatrices is set to true this function will also set UNITY_MATRIX_I_V and UNITY_MATRIX_I_VP.
/// This function has no effect when rendering in stereo. When in stereo rendering you cannot override camera matrices.
/// If you need to set general purpose view and projection matrices call instead.
///
/// CommandBuffer to submit data to GPU.
/// CameraData containing camera matrices information.
/// Set this to true if you also need to set inverse camera matrices.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public static void SetCameraMatrices(CommandBuffer cmd, ref CameraData cameraData, bool setInverseMatrices) { }
///
/// Set camera matrices. This method will set UNITY_MATRIX_V, UNITY_MATRIX_P, UNITY_MATRIX_VP to camera matrices.
/// Additionally this will also set unity_CameraProjection and unity_CameraProjection.
/// If setInverseMatrices is set to true this function will also set UNITY_MATRIX_I_V and UNITY_MATRIX_I_VP.
/// This function has no effect when rendering in stereo. When in stereo rendering you cannot override camera matrices.
/// If you need to set general purpose view and projection matrices call instead.
///
/// CommandBuffer to submit data to GPU.
/// CameraData containing camera matrices information.
/// Set this to true if you also need to set inverse camera matrices.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public static void SetCameraMatrices(CommandBuffer cmd, UniversalCameraData cameraData, bool setInverseMatrices) { }
///
/// Returns the camera color target for this renderer.
/// It's only valid to call cameraColorTargetHandle in the scope of ScriptableRenderPass.
/// .
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public RTHandle cameraColorTargetHandle { get => null; set { } }
///
/// Returns the camera depth target for this renderer.
/// It's only valid to call cameraDepthTargetHandle in the scope of ScriptableRenderPass.
/// .
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public RTHandle cameraDepthTargetHandle { get => null; set { } }
///
/// Configures the camera target.
///
/// Camera color target. Pass k_CameraTarget if rendering to backbuffer.
/// Camera depth target. Pass k_CameraTarget if color has depth or rendering to backbuffer.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void ConfigureCameraTarget(RTHandle colorTarget, RTHandle depthTarget) { }
///
/// Configures the render passes that will execute for this renderer.
/// This method is called per-camera every frame.
///
/// Use this render context to issue any draw commands during execution.
/// Current render state information.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public virtual void Setup(ScriptableRenderContext context, ref RenderingData renderingData) { }
///
/// Override this method to implement the lighting setup for the renderer. You can use this to
/// compute and upload light CBUFFER for example.
///
/// Use this render context to issue any draw commands during execution.
/// Current render state information.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public virtual void SetupLights(ScriptableRenderContext context, ref RenderingData renderingData) { }
///
/// Execute the enqueued render passes. This automatically handles editor and stereo rendering.
///
/// Use this render context to issue any draw commands during execution.
/// Current render state information.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
///
/// Calls Setup for each feature added to this renderer.
///
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
protected void SetupRenderPasses(in RenderingData renderingData) { }
}
partial class ScriptableRendererFeature
{
///
/// Callback after render targets are initialized. This allows for accessing targets from renderer after they are created and ready.
///
/// Renderer used for adding render passes.
/// Rendering state. Use this to setup render passes.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public virtual void SetupRenderPasses(ScriptableRenderer renderer, in RenderingData renderingData) { }
}
partial struct CameraData
{
///
/// Returns the camera GPU projection matrix. This contains platform specific changes to handle y-flip and reverse z. Includes camera jitter if required by active features.
/// Similar to GL.GetGPUProjectionMatrix but queries URP internal state to know if the pipeline is rendering to render texture.
/// For more info on platform differences regarding camera projection check: https://docs.unity3d.com/Manual/SL-PlatformDifferences.html
///
/// View index in case of stereo rendering. By default viewIndex is set to 0.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public Matrix4x4 GetGPUProjectionMatrix(int viewIndex = 0) => default;
///
/// Returns the camera GPU projection matrix. This contains platform specific changes to handle y-flip and reverse z. Does not include any camera jitter.
/// Similar to GL.GetGPUProjectionMatrix but queries URP internal state to know if the pipeline is rendering to render texture.
/// For more info on platform differences regarding camera projection check: https://docs.unity3d.com/Manual/SL-PlatformDifferences.html
///
/// View index in case of stereo rendering. By default viewIndex is set to 0.
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public Matrix4x4 GetGPUProjectionMatrixNoJitter(int viewIndex = 0) => default;
///
/// True if the camera device projection matrix is flipped. This happens when the pipeline is rendering
/// to a render texture in non OpenGL platforms. If you are doing a custom Blit pass to copy camera textures
/// (_CameraColorTexture, _CameraDepthAttachment) you need to check this flag to know if you should flip the
/// matrix when rendering with for cmd.Draw* and reading from camera textures.
///
/// True if the camera device projection matrix is flipped.
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public bool IsCameraProjectionMatrixFlipped() => default;
}
namespace Internal
{
partial class AdditionalLightsShadowCasterPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Configure(CommandBuffer cmd, RenderTextureDescriptor cameraTextureDescriptor) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class ColorGradingLutPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class CopyColorPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void OnCameraSetup(CommandBuffer cmd, ref RenderingData renderingData) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class CopyDepthPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void OnCameraSetup(CommandBuffer cmd, ref RenderingData renderingData) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class DepthNormalOnlyPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void OnCameraSetup(CommandBuffer cmd, ref RenderingData renderingData) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class DepthOnlyPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void OnCameraSetup(CommandBuffer cmd, ref RenderingData renderingData) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class DrawObjectsPass
{
///
/// Used to indicate if the active target of the pass is the back buffer
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public bool m_IsActiveTargetBackBuffer; // TODO: Remove this when we remove non-RG path
///
/// Sets up the pass.
///
/// Color attachment handle.
/// Texture used with rendering layers.
/// Depth attachment handle.
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void Setup(RTHandle colorAttachment, RTHandle renderingLayersTexture, RTHandle depthAttachment) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Configure(CommandBuffer cmd, RenderTextureDescriptor cameraTextureDescriptor) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class ForwardLights
{
///
/// Sets up the keywords and data for forward lighting.
///
///
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public void Setup(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class FinalBlitPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void OnCameraSetup(CommandBuffer cmd, ref RenderingData renderingData) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class MainLightShadowCasterPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Configure(CommandBuffer cmd, RenderTextureDescriptor cameraTextureDescriptor) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
}
partial class DrawSkyboxPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class RenderObjectsPass
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Execute(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
partial class UniversalRenderer
{
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void Setup(ScriptableRenderContext context, ref RenderingData renderingData) { }
///
[Obsolete(DeprecationMessage.CompatibilityScriptingAPIHidden)]
public override void SetupLights(ScriptableRenderContext context, ref RenderingData renderingData) { }
}
#endif //!URP_COMPATIBILITY_MODE
}