Class HDUtils
Syntax
Fields
k_RendererConfigurationBakedLighting
Declaration
public const PerObjectData k_RendererConfigurationBakedLighting = null
Field Value
| Type |
Description |
| PerObjectData |
|
k_RendererConfigurationBakedLightingWithShadowMask
Declaration
public const PerObjectData k_RendererConfigurationBakedLightingWithShadowMask = null
Field Value
| Type |
Description |
| PerObjectData |
|
Properties
clearTexture3D
Declaration
public static Texture3D clearTexture3D { get; }
Property Value
| Type |
Description |
| Texture3D |
|
debugStep
Declaration
public static int debugStep { get; }
Property Value
hdrpSettings
Declaration
public static RenderPipelineSettings hdrpSettings { get; }
Property Value
s_DefaultAdditionalShadowData
Declaration
public static AdditionalShadowData s_DefaultAdditionalShadowData { get; }
Property Value
s_DefaultHDAdditionalCameraData
Declaration
public static HDAdditionalCameraData s_DefaultHDAdditionalCameraData { get; }
Property Value
s_DefaultHDAdditionalLightData
Declaration
public static HDAdditionalLightData s_DefaultHDAdditionalLightData { get; }
Property Value
s_DefaultHDAdditionalReflectionData
Declaration
public static HDAdditionalReflectionData s_DefaultHDAdditionalReflectionData { get; }
Property Value
Methods
BlitCameraTexture(CommandBuffer, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, Rect, Single, Boolean)
Declaration
public static void BlitCameraTexture(CommandBuffer cmd, RTHandleSystem.RTHandle source, RTHandleSystem.RTHandle destination, Rect destViewport, float mipLevel = 0F, bool bilinear = false)
Parameters
BlitCameraTexture(CommandBuffer, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, Single, Boolean)
Declaration
public static void BlitCameraTexture(CommandBuffer cmd, RTHandleSystem.RTHandle source, RTHandleSystem.RTHandle destination, float mipLevel = 0F, bool bilinear = false)
Parameters
BlitCameraTexture(CommandBuffer, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, Vector4, Single, Boolean)
Declaration
public static void BlitCameraTexture(CommandBuffer cmd, RTHandleSystem.RTHandle source, RTHandleSystem.RTHandle destination, Vector4 scaleBias, float mipLevel = 0F, bool bilinear = false)
Parameters
BlitQuad(CommandBuffer, Texture, Vector4, Vector4, Int32, Boolean)
Declaration
public static void BlitQuad(CommandBuffer cmd, Texture source, Vector4 scaleBiasTex, Vector4 scaleBiasRT, int mipLevelTex, bool bilinear)
Parameters
| Type |
Name |
Description |
| CommandBuffer |
cmd |
|
| Texture |
source |
|
| Vector4 |
scaleBiasTex |
|
| Vector4 |
scaleBiasRT |
|
| Int32 |
mipLevelTex |
|
| Boolean |
bilinear |
|
BlitTexture(CommandBuffer, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, Vector4, Single, Boolean)
Declaration
public static void BlitTexture(CommandBuffer cmd, RTHandleSystem.RTHandle source, RTHandleSystem.RTHandle destination, Vector4 scaleBias, float mipLevel, bool bilinear)
Parameters
CheckRTCreated(RenderTexture)
Declaration
public static void CheckRTCreated(RenderTexture rt)
Parameters
| Type |
Name |
Description |
| RenderTexture |
rt |
|
ComputeLinearDistanceFade(Single, Single)
Declaration
public static float ComputeLinearDistanceFade(float distanceToCamera, float fadeDistance)
Parameters
| Type |
Name |
Description |
| Single |
distanceToCamera |
|
| Single |
fadeDistance |
|
Returns
ComputePixelCoordToWorldSpaceViewDirectionMatrix(Single, Vector2, Vector4, Matrix4x4, Boolean)
Declaration
public static Matrix4x4 ComputePixelCoordToWorldSpaceViewDirectionMatrix(float verticalFoV, Vector2 lensShift, Vector4 screenSize, Matrix4x4 worldToViewMatrix, bool renderToCubemap)
Parameters
| Type |
Name |
Description |
| Single |
verticalFoV |
|
| Vector2 |
lensShift |
|
| Vector4 |
screenSize |
|
| Matrix4x4 |
worldToViewMatrix |
|
| Boolean |
renderToCubemap |
|
Returns
| Type |
Description |
| Matrix4x4 |
|
ComputeUvScaleAndLimit(Vector2Int, Vector2Int)
Declaration
public static Vector4 ComputeUvScaleAndLimit(Vector2Int viewportResolution, Vector2Int bufferSize)
Parameters
| Type |
Name |
Description |
| Vector2Int |
viewportResolution |
|
| Vector2Int |
bufferSize |
|
Returns
ComputZPlaneTexelSpacing(Single, Single, Single)
Declaration
public static float ComputZPlaneTexelSpacing(float planeDepth, float verticalFoV, float resolutionY)
Parameters
Returns
ConvertGUIDToVector4(String)
Declaration
public static Vector4 ConvertGUIDToVector4(string guid)
Parameters
| Type |
Name |
Description |
| String |
guid |
|
Returns
ConvertVector4ToGUID(Vector4)
Declaration
public static string ConvertVector4ToGUID(Vector4 vector)
Parameters
| Type |
Name |
Description |
| Vector4 |
vector |
|
Returns
DivRoundUp(Int32, Int32)
Declaration
public static int DivRoundUp(int x, int y)
Parameters
Returns
DrawFullScreen(CommandBuffer, Material, RenderTargetIdentifier[], RTHandleSystem.RTHandle, MaterialPropertyBlock, Int32)
Declaration
public static void DrawFullScreen(CommandBuffer commandBuffer, Material material, RenderTargetIdentifier[] colorBuffers, RTHandleSystem.RTHandle depthStencilBuffer, MaterialPropertyBlock properties = null, int shaderPassId = 0)
Parameters
| Type |
Name |
Description |
| CommandBuffer |
commandBuffer |
|
| Material |
material |
|
| RenderTargetIdentifier[] |
colorBuffers |
|
| RTHandleSystem.RTHandle |
depthStencilBuffer |
|
| MaterialPropertyBlock |
properties |
|
| Int32 |
shaderPassId |
|
DrawFullScreen(CommandBuffer, Material, RTHandleSystem.RTHandle, MaterialPropertyBlock, Int32)
Declaration
public static void DrawFullScreen(CommandBuffer commandBuffer, Material material, RTHandleSystem.RTHandle colorBuffer, MaterialPropertyBlock properties = null, int shaderPassId = 0)
Parameters
| Type |
Name |
Description |
| CommandBuffer |
commandBuffer |
|
| Material |
material |
|
| RTHandleSystem.RTHandle |
colorBuffer |
|
| MaterialPropertyBlock |
properties |
|
| Int32 |
shaderPassId |
|
DrawFullScreen(CommandBuffer, Material, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, MaterialPropertyBlock, Int32)
Declaration
public static void DrawFullScreen(CommandBuffer commandBuffer, Material material, RTHandleSystem.RTHandle colorBuffer, RTHandleSystem.RTHandle depthStencilBuffer, MaterialPropertyBlock properties = null, int shaderPassId = 0)
Parameters
DrawFullScreen(CommandBuffer, Rect, Material, RenderTargetIdentifier, MaterialPropertyBlock, Int32)
Declaration
public static void DrawFullScreen(CommandBuffer commandBuffer, Rect viewport, Material material, RenderTargetIdentifier destination, MaterialPropertyBlock properties = null, int shaderPassId = 0)
Parameters
| Type |
Name |
Description |
| CommandBuffer |
commandBuffer |
|
| Rect |
viewport |
|
| Material |
material |
|
| RenderTargetIdentifier |
destination |
|
| MaterialPropertyBlock |
properties |
|
| Int32 |
shaderPassId |
|
DrawFullScreen(CommandBuffer, RTHandleProperties, Material, RenderTargetIdentifier, MaterialPropertyBlock, Int32)
Declaration
public static void DrawFullScreen(CommandBuffer commandBuffer, RTHandleProperties rtHandleProperties, Material material, RenderTargetIdentifier colorBuffer, MaterialPropertyBlock properties = null, int shaderPassId = 0)
Parameters
| Type |
Name |
Description |
| CommandBuffer |
commandBuffer |
|
| RTHandleProperties |
rtHandleProperties |
|
| Material |
material |
|
| RenderTargetIdentifier |
colorBuffer |
|
| MaterialPropertyBlock |
properties |
|
| Int32 |
shaderPassId |
|
DrawRendererList(ScriptableRenderContext, CommandBuffer, RendererList)
Declaration
public static void DrawRendererList(ScriptableRenderContext renderContext, CommandBuffer cmd, RendererList rendererList)
Parameters
| Type |
Name |
Description |
| ScriptableRenderContext |
renderContext |
|
| CommandBuffer |
cmd |
|
| RendererList |
rendererList |
|
GetBlitMaterial(TextureDimension)
Declaration
public static Material GetBlitMaterial(TextureDimension dimension)
Parameters
| Type |
Name |
Description |
| TextureDimension |
dimension |
|
Returns
| Type |
Description |
| Material |
|
GetCorePath()
Declaration
public static string GetCorePath()
Returns
GetHDRenderPipelinePath()
Declaration
public static string GetHDRenderPipelinePath()
Returns
GetMouseClickCoordinates(HDCamera)
Declaration
public static Vector4 GetMouseClickCoordinates(HDCamera camera)
Parameters
Returns
GetMouseCoordinates(HDCamera)
Declaration
public static Vector4 GetMouseCoordinates(HDCamera camera)
Parameters
Returns
GetRenderPipelineMaterialList()
Declaration
public static List<RenderPipelineMaterial> GetRenderPipelineMaterialList()
Returns
GetScaleAndBiasForLinearDistanceFade(Single, out Single, out Single)
Declaration
public static void GetScaleAndBiasForLinearDistanceFade(float fadeDistance, out float scale, out float bias)
Parameters
GetViewProjectionMatrix(Matrix4x4, Matrix4x4)
Declaration
public static Matrix4x4 GetViewProjectionMatrix(Matrix4x4 worldToViewMatrix, Matrix4x4 projectionMatrix)
Parameters
| Type |
Name |
Description |
| Matrix4x4 |
worldToViewMatrix |
|
| Matrix4x4 |
projectionMatrix |
|
Returns
| Type |
Description |
| Matrix4x4 |
|
IsOperatingSystemSupported(String)
Declaration
public static bool IsOperatingSystemSupported(string os)
Parameters
| Type |
Name |
Description |
| String |
os |
|
Returns
IsQuaternionValid(Quaternion)
Declaration
public static bool IsQuaternionValid(Quaternion q)
Parameters
| Type |
Name |
Description |
| Quaternion |
q |
|
Returns
IsRegularPreviewCamera(Camera)
Declaration
public static bool IsRegularPreviewCamera(Camera camera)
Parameters
| Type |
Name |
Description |
| Camera |
camera |
|
Returns
IsSupportedGraphicDevice(GraphicsDeviceType)
Declaration
public static bool IsSupportedGraphicDevice(GraphicsDeviceType graphicDevice)
Parameters
| Type |
Name |
Description |
| GraphicsDeviceType |
graphicDevice |
|
Returns
NextOverlayCoord(ref Single, ref Single, Single, Single, HDCamera)
Declaration
public static void NextOverlayCoord(ref float x, ref float y, float overlayWidth, float overlayHeight, HDCamera hdCamera)
Parameters
NormalizeColor(Color)
Declaration
public static Color NormalizeColor(Color color)
Parameters
| Type |
Name |
Description |
| Color |
color |
|
Returns
PostProcessIsFinalPass()
Declaration
public static bool PostProcessIsFinalPass()
Returns
ResetOverlay()
Declaration
public static void ResetOverlay()
SetRenderTarget(CommandBuffer, RenderTargetIdentifier[], RTHandleSystem.RTHandle)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RenderTargetIdentifier[] colorBuffers, RTHandleSystem.RTHandle depthBuffer)
Parameters
SetRenderTarget(CommandBuffer, RenderTargetIdentifier[], RTHandleSystem.RTHandle, ClearFlag)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RenderTargetIdentifier[] colorBuffers, RTHandleSystem.RTHandle depthBuffer, ClearFlag clearFlag = null)
Parameters
| Type |
Name |
Description |
| CommandBuffer |
cmd |
|
| RenderTargetIdentifier[] |
colorBuffers |
|
| RTHandleSystem.RTHandle |
depthBuffer |
|
| ClearFlag |
clearFlag |
|
SetRenderTarget(CommandBuffer, RenderTargetIdentifier[], RTHandleSystem.RTHandle, ClearFlag, Color)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RenderTargetIdentifier[] colorBuffers, RTHandleSystem.RTHandle depthBuffer, ClearFlag clearFlag, Color clearColor)
Parameters
| Type |
Name |
Description |
| CommandBuffer |
cmd |
|
| RenderTargetIdentifier[] |
colorBuffers |
|
| RTHandleSystem.RTHandle |
depthBuffer |
|
| ClearFlag |
clearFlag |
|
| Color |
clearColor |
|
SetRenderTarget(CommandBuffer, RTHandleSystem.RTHandle, ClearFlag, Color, Int32, CubemapFace, Int32)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RTHandleSystem.RTHandle buffer, ClearFlag clearFlag, Color clearColor, int miplevel = 0, CubemapFace cubemapFace = null, int depthSlice = -1)
Parameters
SetRenderTarget(CommandBuffer, RTHandleSystem.RTHandle, ClearFlag, Int32, CubemapFace, Int32)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RTHandleSystem.RTHandle buffer, ClearFlag clearFlag = null, int miplevel = 0, CubemapFace cubemapFace = null, int depthSlice = -1)
Parameters
SetRenderTarget(CommandBuffer, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, ClearFlag, Color, Int32, CubemapFace, Int32)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RTHandleSystem.RTHandle colorBuffer, RTHandleSystem.RTHandle depthBuffer, ClearFlag clearFlag, Color clearColor, int miplevel = 0, CubemapFace cubemapFace = null, int depthSlice = -1)
Parameters
SetRenderTarget(CommandBuffer, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, ClearFlag, Int32, CubemapFace, Int32)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RTHandleSystem.RTHandle colorBuffer, RTHandleSystem.RTHandle depthBuffer, ClearFlag clearFlag, int miplevel = 0, CubemapFace cubemapFace = null, int depthSlice = -1)
Parameters
SetRenderTarget(CommandBuffer, RTHandleSystem.RTHandle, RTHandleSystem.RTHandle, Int32, CubemapFace, Int32)
Declaration
public static void SetRenderTarget(CommandBuffer cmd, RTHandleSystem.RTHandle colorBuffer, RTHandleSystem.RTHandle depthBuffer, int miplevel = 0, CubemapFace cubemapFace = null, int depthSlice = -1)
Parameters
SetViewport(CommandBuffer, RTHandleSystem.RTHandle)
Declaration
public static void SetViewport(CommandBuffer cmd, RTHandleSystem.RTHandle target)
Parameters