diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Common/HDRenderPipelineAssetDeferred.asset b/TestProjects/HDRP_DXR_Tests/Assets/Common/HDRenderPipelineAssetDeferred.asset
index a58b5678c11..8cd1608a85b 100644
--- a/TestProjects/HDRP_DXR_Tests/Assets/Common/HDRenderPipelineAssetDeferred.asset
+++ b/TestProjects/HDRP_DXR_Tests/Assets/Common/HDRenderPipelineAssetDeferred.asset
@@ -12,142 +12,6 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 0cf1dab834d4ec34195b920ea7bbf9ec, type: 3}
m_Name: HDRenderPipelineAssetDeferred
m_EditorClassIdentifier:
- m_Version: 17
- m_ObsoleteFrameSettings:
- overrides: 0
- enableShadow: 0
- enableContactShadows: 0
- enableShadowMask: 0
- enableSSR: 0
- enableSSAO: 0
- enableSubsurfaceScattering: 0
- enableTransmission: 0
- enableAtmosphericScattering: 0
- enableVolumetrics: 0
- enableReprojectionForVolumetrics: 0
- enableLightLayers: 0
- enableExposureControl: 1
- diffuseGlobalDimmer: 0
- specularGlobalDimmer: 0
- shaderLitMode: 0
- enableDepthPrepassWithDeferredRendering: 0
- enableTransparentPrepass: 0
- enableMotionVectors: 0
- enableObjectMotionVectors: 0
- enableDecals: 0
- enableRoughRefraction: 0
- enableTransparentPostpass: 0
- enableDistortion: 0
- enablePostprocess: 0
- enableOpaqueObjects: 0
- enableTransparentObjects: 0
- enableRealtimePlanarReflection: 0
- enableMSAA: 0
- enableAsyncCompute: 0
- runLightListAsync: 0
- runSSRAsync: 0
- runSSAOAsync: 0
- runContactShadowsAsync: 0
- runVolumeVoxelizationAsync: 0
- lightLoopSettings:
- overrides: 0
- enableDeferredTileAndCluster: 0
- enableComputeLightEvaluation: 0
- enableComputeLightVariants: 0
- enableComputeMaterialVariants: 0
- enableFptlForForwardOpaque: 0
- enableBigTilePrepass: 0
- isFptlEnabled: 0
- m_ObsoleteBakedOrCustomReflectionFrameSettings:
- overrides: 0
- enableShadow: 0
- enableContactShadows: 0
- enableShadowMask: 0
- enableSSR: 0
- enableSSAO: 0
- enableSubsurfaceScattering: 0
- enableTransmission: 0
- enableAtmosphericScattering: 0
- enableVolumetrics: 0
- enableReprojectionForVolumetrics: 0
- enableLightLayers: 0
- enableExposureControl: 1
- diffuseGlobalDimmer: 0
- specularGlobalDimmer: 0
- shaderLitMode: 0
- enableDepthPrepassWithDeferredRendering: 0
- enableTransparentPrepass: 0
- enableMotionVectors: 0
- enableObjectMotionVectors: 0
- enableDecals: 0
- enableRoughRefraction: 0
- enableTransparentPostpass: 0
- enableDistortion: 0
- enablePostprocess: 0
- enableOpaqueObjects: 0
- enableTransparentObjects: 0
- enableRealtimePlanarReflection: 0
- enableMSAA: 0
- enableAsyncCompute: 0
- runLightListAsync: 0
- runSSRAsync: 0
- runSSAOAsync: 0
- runContactShadowsAsync: 0
- runVolumeVoxelizationAsync: 0
- lightLoopSettings:
- overrides: 0
- enableDeferredTileAndCluster: 0
- enableComputeLightEvaluation: 0
- enableComputeLightVariants: 0
- enableComputeMaterialVariants: 0
- enableFptlForForwardOpaque: 0
- enableBigTilePrepass: 0
- isFptlEnabled: 0
- m_ObsoleteRealtimeReflectionFrameSettings:
- overrides: 0
- enableShadow: 0
- enableContactShadows: 0
- enableShadowMask: 0
- enableSSR: 0
- enableSSAO: 0
- enableSubsurfaceScattering: 0
- enableTransmission: 0
- enableAtmosphericScattering: 0
- enableVolumetrics: 0
- enableReprojectionForVolumetrics: 0
- enableLightLayers: 0
- enableExposureControl: 1
- diffuseGlobalDimmer: 0
- specularGlobalDimmer: 0
- shaderLitMode: 0
- enableDepthPrepassWithDeferredRendering: 0
- enableTransparentPrepass: 0
- enableMotionVectors: 0
- enableObjectMotionVectors: 0
- enableDecals: 0
- enableRoughRefraction: 0
- enableTransparentPostpass: 0
- enableDistortion: 0
- enablePostprocess: 0
- enableOpaqueObjects: 0
- enableTransparentObjects: 0
- enableRealtimePlanarReflection: 0
- enableMSAA: 0
- enableAsyncCompute: 0
- runLightListAsync: 0
- runSSRAsync: 0
- runSSAOAsync: 0
- runContactShadowsAsync: 0
- runVolumeVoxelizationAsync: 0
- lightLoopSettings:
- overrides: 0
- enableDeferredTileAndCluster: 0
- enableComputeLightEvaluation: 0
- enableComputeLightVariants: 0
- enableComputeMaterialVariants: 0
- enableFptlForForwardOpaque: 0
- enableBigTilePrepass: 0
- isFptlEnabled: 0
m_RenderPipelineResources: {fileID: 11400000, guid: 3ce144cff5783da45aa5d4fdc2da14b7,
type: 2}
m_RenderPipelineRayTracingResources: {fileID: 11400000, guid: ba6e7f30e5cffc249a8bf7ee5756c196,
@@ -155,13 +19,12 @@ MonoBehaviour:
m_DefaultVolumeProfile: {fileID: 11400000, guid: 4414889870ba0db42b20b120a434b7f5,
type: 2}
m_LensAttenuation: 0
- m_UseRenderGraph: 1
m_DefaultLookDevProfile: {fileID: 11400000, guid: 254c4fe87beb7be4fa72e1681edbed02,
type: 2}
m_RenderingPathDefaultCameraFrameSettings:
bitDatas:
data1: 136268574097245
- data2: 4539628428617252872
+ data2: 4539628428617252888
lodBias: 1
lodBiasMode: 0
lodBiasQualityLevel: 0
@@ -175,7 +38,7 @@ MonoBehaviour:
m_RenderingPathDefaultBakedOrCustomReflectionFrameSettings:
bitDatas:
data1: 139713129479965
- data2: 4539628424389459976
+ data2: 4539628424389459992
lodBias: 1
lodBiasMode: 0
lodBiasQualityLevel: 0
@@ -189,7 +52,7 @@ MonoBehaviour:
m_RenderingPathDefaultRealtimeReflectionFrameSettings:
bitDatas:
data1: 140065159257885
- data2: 4539628424389459976
+ data2: 4539628424389459992
lodBias: 1
lodBiasMode: 0
lodBiasQualityLevel: 0
@@ -212,6 +75,7 @@ MonoBehaviour:
m_SchemaId:
m_Id: With3Levels
supportVolumetrics: 1
+ supportVolumetricClouds: 0
supportLightLayers: 0
lightLayerName0: Light Layer default
lightLayerName1: Light Layer 1
@@ -250,11 +114,10 @@ MonoBehaviour:
supportDitheringCrossFade: 1
supportTerrainHole: 0
supportProbeVolume: 0
+ probeVolumeMemoryBudget: 1024
+ probeVolumeSHBands: 1
supportRayTracing: 1
supportedRayTracingMode: 3
- probeVolumeSettings:
- atlasResolution: 128
- atlasOctahedralDepthResolution: 2048
lightLoopSettings:
cookieAtlasSize: 2048
cookieFormat: 74
@@ -277,6 +140,8 @@ MonoBehaviour:
maxDecalsOnScreen: 512
maxPlanarReflectionOnScreen: 16
maxLightsPerClusterCell: 8
+ maxDensityVolumeSize: 32
+ maxDensityVolumesOnScreen: 64
hdShadowInitParams:
maxShadowRequests: 128
directionalShadowsDepthBits: 32
@@ -377,6 +242,8 @@ MonoBehaviour:
AODirectionCount: 010000000200000004000000
ContactShadowSampleCount: 060000000a00000010000000
SSRMaxRaySteps: 100000002000000040000000
+ SSGIRaySteps: 200000004000000080000000
+ SSGIFilterRadius: 100000000e0000000c000000
RTAORayLength:
- 0.5
- 3
@@ -404,10 +271,6 @@ MonoBehaviour:
- 0.5
- 0.25
RTGISecondDenoise: 010101
- RTGISecondDenoiserRadius:
- - 0
- - 0
- - 0
RTRMinSmoothness:
- 0.6
- 0.4
@@ -424,10 +287,19 @@ MonoBehaviour:
- 0.8
- 1
- 1.2
- RTRUpScaleRadius: 040000000400000003000000
RTRFullResolution: 000001
RTRDenoise: 010101
RTRDenoiserRadius: 080000000c00000010000000
+ RTRSmoothDenoising: 010000
+ Fog_ControlMode: 000000000000000000000000
+ Fog_Budget:
+ - 0.166
+ - 0.33
+ - 0.666
+ Fog_DepthRatio:
+ - 0.666
+ - 0.666
+ - 0.5
allowShaderVariantStripping: 1
enableSRPBatcher: 1
shaderVariantLogLevel: 0
@@ -444,6 +316,7 @@ MonoBehaviour:
- {fileID: 11400000, guid: 57e246e5f8d6a8b4395e2070883735d5, type: 2}
- {fileID: 11400000, guid: d48d38dbecb5bf44db08516376edc733, type: 2}
- {fileID: 11400000, guid: b9b40238eefdcf841834c152892f8196, type: 2}
+ - {fileID: 11400000, guid: 458d5c32111ea5749a494da813d01275, type: 2}
beforeTransparentCustomPostProcesses: []
beforeTAACustomPostProcesses: []
beforePostProcessCustomPostProcesses: []
@@ -453,3 +326,139 @@ MonoBehaviour:
streamingGpuCacheSettings:
- format: 0
sizeInMegaBytes: 128
+ m_Version: 18
+ m_ObsoleteFrameSettings:
+ overrides: 0
+ enableShadow: 0
+ enableContactShadows: 0
+ enableShadowMask: 0
+ enableSSR: 0
+ enableSSAO: 0
+ enableSubsurfaceScattering: 0
+ enableTransmission: 0
+ enableAtmosphericScattering: 0
+ enableVolumetrics: 0
+ enableReprojectionForVolumetrics: 0
+ enableLightLayers: 0
+ enableExposureControl: 1
+ diffuseGlobalDimmer: 0
+ specularGlobalDimmer: 0
+ shaderLitMode: 0
+ enableDepthPrepassWithDeferredRendering: 0
+ enableTransparentPrepass: 0
+ enableMotionVectors: 0
+ enableObjectMotionVectors: 0
+ enableDecals: 0
+ enableRoughRefraction: 0
+ enableTransparentPostpass: 0
+ enableDistortion: 0
+ enablePostprocess: 0
+ enableOpaqueObjects: 0
+ enableTransparentObjects: 0
+ enableRealtimePlanarReflection: 0
+ enableMSAA: 0
+ enableAsyncCompute: 0
+ runLightListAsync: 0
+ runSSRAsync: 0
+ runSSAOAsync: 0
+ runContactShadowsAsync: 0
+ runVolumeVoxelizationAsync: 0
+ lightLoopSettings:
+ overrides: 0
+ enableDeferredTileAndCluster: 0
+ enableComputeLightEvaluation: 0
+ enableComputeLightVariants: 0
+ enableComputeMaterialVariants: 0
+ enableFptlForForwardOpaque: 0
+ enableBigTilePrepass: 0
+ isFptlEnabled: 0
+ m_ObsoleteBakedOrCustomReflectionFrameSettings:
+ overrides: 0
+ enableShadow: 0
+ enableContactShadows: 0
+ enableShadowMask: 0
+ enableSSR: 0
+ enableSSAO: 0
+ enableSubsurfaceScattering: 0
+ enableTransmission: 0
+ enableAtmosphericScattering: 0
+ enableVolumetrics: 0
+ enableReprojectionForVolumetrics: 0
+ enableLightLayers: 0
+ enableExposureControl: 1
+ diffuseGlobalDimmer: 0
+ specularGlobalDimmer: 0
+ shaderLitMode: 0
+ enableDepthPrepassWithDeferredRendering: 0
+ enableTransparentPrepass: 0
+ enableMotionVectors: 0
+ enableObjectMotionVectors: 0
+ enableDecals: 0
+ enableRoughRefraction: 0
+ enableTransparentPostpass: 0
+ enableDistortion: 0
+ enablePostprocess: 0
+ enableOpaqueObjects: 0
+ enableTransparentObjects: 0
+ enableRealtimePlanarReflection: 0
+ enableMSAA: 0
+ enableAsyncCompute: 0
+ runLightListAsync: 0
+ runSSRAsync: 0
+ runSSAOAsync: 0
+ runContactShadowsAsync: 0
+ runVolumeVoxelizationAsync: 0
+ lightLoopSettings:
+ overrides: 0
+ enableDeferredTileAndCluster: 0
+ enableComputeLightEvaluation: 0
+ enableComputeLightVariants: 0
+ enableComputeMaterialVariants: 0
+ enableFptlForForwardOpaque: 0
+ enableBigTilePrepass: 0
+ isFptlEnabled: 0
+ m_ObsoleteRealtimeReflectionFrameSettings:
+ overrides: 0
+ enableShadow: 0
+ enableContactShadows: 0
+ enableShadowMask: 0
+ enableSSR: 0
+ enableSSAO: 0
+ enableSubsurfaceScattering: 0
+ enableTransmission: 0
+ enableAtmosphericScattering: 0
+ enableVolumetrics: 0
+ enableReprojectionForVolumetrics: 0
+ enableLightLayers: 0
+ enableExposureControl: 1
+ diffuseGlobalDimmer: 0
+ specularGlobalDimmer: 0
+ shaderLitMode: 0
+ enableDepthPrepassWithDeferredRendering: 0
+ enableTransparentPrepass: 0
+ enableMotionVectors: 0
+ enableObjectMotionVectors: 0
+ enableDecals: 0
+ enableRoughRefraction: 0
+ enableTransparentPostpass: 0
+ enableDistortion: 0
+ enablePostprocess: 0
+ enableOpaqueObjects: 0
+ enableTransparentObjects: 0
+ enableRealtimePlanarReflection: 0
+ enableMSAA: 0
+ enableAsyncCompute: 0
+ runLightListAsync: 0
+ runSSRAsync: 0
+ runSSAOAsync: 0
+ runContactShadowsAsync: 0
+ runVolumeVoxelizationAsync: 0
+ lightLoopSettings:
+ overrides: 0
+ enableDeferredTileAndCluster: 0
+ enableComputeLightEvaluation: 0
+ enableComputeLightVariants: 0
+ enableComputeMaterialVariants: 0
+ enableFptlForForwardOpaque: 0
+ enableBigTilePrepass: 0
+ isFptlEnabled: 0
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/717_DirectionalLightTransmission.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/717_DirectionalLightTransmission.png
new file mode 100644
index 00000000000..f2aa7f7e75e
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/717_DirectionalLightTransmission.png
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1020ddde1f446fa21c81a2d691a5b4ccc439173781b9b3f51088b8b4d283efb7
+size 73271
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/717_DirectionalLightTransmission.png.meta b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/717_DirectionalLightTransmission.png.meta
new file mode 100644
index 00000000000..a461d26e0df
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/717_DirectionalLightTransmission.png.meta
@@ -0,0 +1,97 @@
+fileFormatVersion: 2
+guid: 4e2d8629664078d4db743c638e9cdf94
+TextureImporter:
+ internalIDToNameTable: []
+ externalObjects: {}
+ serializedVersion: 11
+ mipmaps:
+ mipMapMode: 0
+ enableMipMap: 0
+ sRGBTexture: 1
+ linearTexture: 0
+ fadeOut: 0
+ borderMipMap: 0
+ mipMapsPreserveCoverage: 0
+ alphaTestReferenceValue: 0.5
+ mipMapFadeDistanceStart: 1
+ mipMapFadeDistanceEnd: 3
+ bumpmap:
+ convertToNormalMap: 0
+ externalNormalMap: 0
+ heightScale: 0.25
+ normalMapFilter: 0
+ isReadable: 1
+ streamingMipmaps: 0
+ streamingMipmapsPriority: 0
+ vTOnly: 0
+ grayScaleToAlpha: 0
+ generateCubemap: 6
+ cubemapConvolution: 0
+ seamlessCubemap: 0
+ textureFormat: 1
+ maxTextureSize: 2048
+ textureSettings:
+ serializedVersion: 2
+ filterMode: 1
+ aniso: 1
+ mipBias: 0
+ wrapU: 0
+ wrapV: 0
+ wrapW: 0
+ nPOTScale: 0
+ lightmap: 0
+ compressionQuality: 50
+ spriteMode: 0
+ spriteExtrude: 1
+ spriteMeshType: 1
+ alignment: 0
+ spritePivot: {x: 0.5, y: 0.5}
+ spritePixelsToUnits: 100
+ spriteBorder: {x: 0, y: 0, z: 0, w: 0}
+ spriteGenerateFallbackPhysicsShape: 1
+ alphaUsage: 1
+ alphaIsTransparency: 0
+ spriteTessellationDetail: -1
+ textureType: 0
+ textureShape: 1
+ singleChannelComponent: 0
+ flipbookRows: 1
+ flipbookColumns: 1
+ maxTextureSizeSet: 0
+ compressionQualitySet: 0
+ textureFormatSet: 0
+ ignorePngGamma: 0
+ applyGammaDecoding: 0
+ platformSettings:
+ - serializedVersion: 3
+ buildTarget: DefaultTexturePlatform
+ maxTextureSize: 2048
+ resizeAlgorithm: 0
+ textureFormat: -1
+ textureCompression: 0
+ compressionQuality: 50
+ crunchedCompression: 0
+ allowsAlphaSplitting: 0
+ overridden: 0
+ androidETC2FallbackOverride: 0
+ forceMaximumCompressionQuality_BC6H_BC7: 0
+ spriteSheet:
+ serializedVersion: 2
+ sprites: []
+ outline: []
+ physicsShape: []
+ bones: []
+ spriteID:
+ internalID: 0
+ vertices: []
+ indices:
+ edges: []
+ weights: []
+ secondaryTextures: []
+ nameFileIdTable: {}
+ spritePackingTag:
+ pSDRemoveMatte: 0
+ pSDShowRemoveMatteOption: 0
+ userData:
+ assetBundleName:
+ assetBundleVariant:
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/717_DirectionalLightTransmission.unity b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/717_DirectionalLightTransmission.unity
new file mode 100644
index 00000000000..92efa6be81a
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/717_DirectionalLightTransmission.unity
@@ -0,0 +1,708 @@
+%YAML 1.1
+%TAG !u! tag:unity3d.com,2011:
+--- !u!29 &1
+OcclusionCullingSettings:
+ m_ObjectHideFlags: 0
+ serializedVersion: 2
+ m_OcclusionBakeSettings:
+ smallestOccluder: 5
+ smallestHole: 0.25
+ backfaceThreshold: 100
+ m_SceneGUID: 00000000000000000000000000000000
+ m_OcclusionCullingData: {fileID: 0}
+--- !u!104 &2
+RenderSettings:
+ m_ObjectHideFlags: 0
+ serializedVersion: 9
+ m_Fog: 0
+ m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
+ m_FogMode: 3
+ m_FogDensity: 0.01
+ m_LinearFogStart: 0
+ m_LinearFogEnd: 300
+ m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
+ m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
+ m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
+ m_AmbientIntensity: 1
+ m_AmbientMode: 0
+ m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
+ m_SkyboxMaterial: {fileID: 0}
+ m_HaloStrength: 0.5
+ m_FlareStrength: 1
+ m_FlareFadeSpeed: 3
+ m_HaloTexture: {fileID: 0}
+ m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
+ m_DefaultReflectionMode: 0
+ m_DefaultReflectionResolution: 128
+ m_ReflectionBounces: 1
+ m_ReflectionIntensity: 1
+ m_CustomReflection: {fileID: 0}
+ m_Sun: {fileID: 0}
+ m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1}
+ m_UseRadianceAmbientProbe: 0
+--- !u!157 &3
+LightmapSettings:
+ m_ObjectHideFlags: 0
+ serializedVersion: 12
+ m_GIWorkflowMode: 1
+ m_GISettings:
+ serializedVersion: 2
+ m_BounceScale: 1
+ m_IndirectOutputScale: 1
+ m_AlbedoBoost: 1
+ m_EnvironmentLightingMode: 0
+ m_EnableBakedLightmaps: 1
+ m_EnableRealtimeLightmaps: 0
+ m_LightmapEditorSettings:
+ serializedVersion: 12
+ m_Resolution: 2
+ m_BakeResolution: 40
+ m_AtlasSize: 1024
+ m_AO: 0
+ m_AOMaxDistance: 1
+ m_CompAOExponent: 1
+ m_CompAOExponentDirect: 0
+ m_ExtractAmbientOcclusion: 0
+ m_Padding: 2
+ m_LightmapParameters: {fileID: 0}
+ m_LightmapsBakeMode: 1
+ m_TextureCompression: 1
+ m_FinalGather: 0
+ m_FinalGatherFiltering: 1
+ m_FinalGatherRayCount: 256
+ m_ReflectionCompression: 2
+ m_MixedBakeMode: 2
+ m_BakeBackend: 1
+ m_PVRSampling: 1
+ m_PVRDirectSampleCount: 32
+ m_PVRSampleCount: 512
+ m_PVRBounces: 2
+ m_PVREnvironmentSampleCount: 256
+ m_PVREnvironmentReferencePointCount: 2048
+ m_PVRFilteringMode: 1
+ m_PVRDenoiserTypeDirect: 1
+ m_PVRDenoiserTypeIndirect: 1
+ m_PVRDenoiserTypeAO: 1
+ m_PVRFilterTypeDirect: 0
+ m_PVRFilterTypeIndirect: 0
+ m_PVRFilterTypeAO: 0
+ m_PVREnvironmentMIS: 1
+ m_PVRCulling: 1
+ m_PVRFilteringGaussRadiusDirect: 1
+ m_PVRFilteringGaussRadiusIndirect: 5
+ m_PVRFilteringGaussRadiusAO: 2
+ m_PVRFilteringAtrousPositionSigmaDirect: 0.5
+ m_PVRFilteringAtrousPositionSigmaIndirect: 2
+ m_PVRFilteringAtrousPositionSigmaAO: 1
+ m_ExportTrainingData: 0
+ m_TrainingDataDestination: TrainingData
+ m_LightProbeSampleCountMultiplier: 4
+ m_LightingDataAsset: {fileID: 0}
+ m_LightingSettings: {fileID: 0}
+--- !u!196 &4
+NavMeshSettings:
+ serializedVersion: 2
+ m_ObjectHideFlags: 0
+ m_BuildSettings:
+ serializedVersion: 2
+ agentTypeID: 0
+ agentRadius: 0.5
+ agentHeight: 2
+ agentSlope: 45
+ agentClimb: 0.4
+ ledgeDropHeight: 0
+ maxJumpAcrossDistance: 0
+ minRegionArea: 2
+ manualCellSize: 0
+ cellSize: 0.16666667
+ manualTileSize: 0
+ tileSize: 256
+ accuratePlacement: 0
+ maxJobWorkers: 0
+ preserveTilesOutsideBounds: 0
+ debug:
+ m_Flags: 0
+ m_NavMeshData: {fileID: 0}
+--- !u!1001 &31115525
+PrefabInstance:
+ m_ObjectHideFlags: 0
+ serializedVersion: 2
+ m_Modification:
+ m_TransformParent: {fileID: 0}
+ m_Modifications:
+ - target: {fileID: 1132393308280272, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_Name
+ value: HDRP_Test_Camera
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_RootOrder
+ value: 2
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalPosition.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalPosition.y
+ value: 0.5
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalPosition.z
+ value: 2
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalRotation.w
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalRotation.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalRotation.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalRotation.z
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalEulerAnglesHint.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalEulerAnglesHint.y
+ value: 180
+ objectReference: {fileID: 0}
+ - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+ propertyPath: m_LocalEulerAnglesHint.z
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 20109210616973140, guid: c07ace9ab142ca9469fa377877c2f1e7,
+ type: 3}
+ propertyPath: far clip plane
+ value: 1000
+ objectReference: {fileID: 0}
+ - target: {fileID: 20109210616973140, guid: c07ace9ab142ca9469fa377877c2f1e7,
+ type: 3}
+ propertyPath: near clip plane
+ value: 0.1
+ objectReference: {fileID: 0}
+ - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7,
+ type: 3}
+ propertyPath: renderPipelineAsset
+ value:
+ objectReference: {fileID: 11400000, guid: 14a0f3aaa5e78a3439ec76d270471ebe,
+ type: 2}
+ - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7,
+ type: 3}
+ propertyPath: checkMemoryAllocation
+ value: 0
+ objectReference: {fileID: 0}
+ m_RemovedComponents: []
+ m_SourcePrefab: {fileID: 100100000, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3}
+--- !u!1 &424870423
+GameObject:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ serializedVersion: 6
+ m_Component:
+ - component: {fileID: 424870427}
+ - component: {fileID: 424870426}
+ - component: {fileID: 424870425}
+ - component: {fileID: 424870424}
+ m_Layer: 0
+ m_Name: Plane (1)
+ m_TagString: Untagged
+ m_Icon: {fileID: 0}
+ m_NavMeshLayer: 0
+ m_StaticEditorFlags: 0
+ m_IsActive: 1
+--- !u!64 &424870424
+MeshCollider:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 424870423}
+ m_Material: {fileID: 0}
+ m_IsTrigger: 0
+ m_Enabled: 1
+ serializedVersion: 4
+ m_Convex: 0
+ m_CookingOptions: 30
+ m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
+--- !u!23 &424870425
+MeshRenderer:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 424870423}
+ m_Enabled: 1
+ m_CastShadows: 1
+ m_ReceiveShadows: 1
+ m_DynamicOccludee: 1
+ m_StaticShadowCaster: 0
+ m_MotionVectors: 1
+ m_LightProbeUsage: 1
+ m_ReflectionProbeUsage: 1
+ m_RayTracingMode: 2
+ m_RayTraceProcedural: 0
+ m_RenderingLayerMask: 257
+ m_RendererPriority: 0
+ m_Materials:
+ - {fileID: 2100000, guid: 1b14afd6a65c4e54ea1808ec196447a3, type: 2}
+ m_StaticBatchInfo:
+ firstSubMesh: 0
+ subMeshCount: 0
+ m_StaticBatchRoot: {fileID: 0}
+ m_ProbeAnchor: {fileID: 0}
+ m_LightProbeVolumeOverride: {fileID: 0}
+ m_ScaleInLightmap: 1
+ m_ReceiveGI: 1
+ m_PreserveUVs: 0
+ m_IgnoreNormalsForChartDetection: 0
+ m_ImportantGI: 0
+ m_StitchLightmapSeams: 1
+ m_SelectedEditorRenderState: 3
+ m_MinimumChartSize: 4
+ m_AutoUVMaxDistance: 0.5
+ m_AutoUVMaxAngle: 89
+ m_LightmapParameters: {fileID: 0}
+ m_SortingLayerID: 0
+ m_SortingLayer: 0
+ m_SortingOrder: 0
+ m_AdditionalVertexStreams: {fileID: 0}
+--- !u!33 &424870426
+MeshFilter:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 424870423}
+ m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
+--- !u!4 &424870427
+Transform:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 424870423}
+ m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
+ m_LocalPosition: {x: 0, y: 0, z: 0}
+ m_LocalScale: {x: 1, y: 1, z: 1}
+ m_Children: []
+ m_Father: {fileID: 0}
+ m_RootOrder: 1
+ m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
+--- !u!1 &427000171
+GameObject:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ serializedVersion: 6
+ m_Component:
+ - component: {fileID: 427000174}
+ - component: {fileID: 427000173}
+ - component: {fileID: 427000172}
+ m_Layer: 0
+ m_Name: Directional Light
+ m_TagString: Untagged
+ m_Icon: {fileID: 0}
+ m_NavMeshLayer: 0
+ m_StaticEditorFlags: 0
+ m_IsActive: 1
+--- !u!114 &427000172
+MonoBehaviour:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 427000171}
+ m_Enabled: 1
+ m_EditorHideFlags: 0
+ m_Script: {fileID: 11500000, guid: 7a68c43fe1f2a47cfa234b5eeaa98012, type: 3}
+ m_Name:
+ m_EditorClassIdentifier:
+ m_Intensity: 0.91254795
+ m_EnableSpotReflector: 1
+ m_LuxAtDistance: 1
+ m_InnerSpotPercent: 0
+ m_SpotIESCutoffPercent: 100
+ m_LightDimmer: 1
+ m_VolumetricDimmer: 1
+ m_LightUnit: 2
+ m_FadeDistance: 10000
+ m_VolumetricFadeDistance: 10000
+ m_AffectDiffuse: 1
+ m_AffectSpecular: 1
+ m_NonLightmappedOnly: 0
+ m_ShapeWidth: 0.5
+ m_ShapeHeight: 0.5
+ m_AspectRatio: 1
+ m_ShapeRadius: 0.025
+ m_SoftnessScale: 1
+ m_UseCustomSpotLightShadowCone: 0
+ m_CustomSpotLightShadowCone: 30
+ m_MaxSmoothness: 0.99
+ m_ApplyRangeAttenuation: 1
+ m_DisplayAreaLightEmissiveMesh: 0
+ m_AreaLightCookie: {fileID: 0}
+ m_IESPoint: {fileID: 0}
+ m_IESSpot: {fileID: 0}
+ m_IncludeForRayTracing: 1
+ m_AreaLightShadowCone: 120
+ m_UseScreenSpaceShadows: 1
+ m_InteractsWithSky: 1
+ m_AngularDiameter: 10
+ m_FlareSize: 2
+ m_FlareTint: {r: 1, g: 1, b: 1, a: 1}
+ m_FlareFalloff: 4
+ m_SurfaceTexture: {fileID: 0}
+ m_SurfaceTint: {r: 1, g: 1, b: 1, a: 1}
+ m_Distance: 1.5e+11
+ m_UseRayTracedShadows: 1
+ m_NumRayTracingSamples: 2
+ m_FilterTracedShadow: 1
+ m_FilterSizeTraced: 8
+ m_SunLightConeAngle: 0.5
+ m_LightShadowRadius: 0.5
+ m_SemiTransparentShadow: 0
+ m_ColorShadow: 1
+ m_DistanceBasedFiltering: 0
+ m_EvsmExponent: 15
+ m_EvsmLightLeakBias: 0
+ m_EvsmVarianceBias: 0.00001
+ m_EvsmBlurPasses: 0
+ m_LightlayersMask: 1
+ m_LinkShadowLayers: 1
+ m_ShadowNearPlane: 0.1
+ m_BlockerSampleCount: 24
+ m_FilterSampleCount: 16
+ m_MinFilterSize: 0.1
+ m_KernelSize: 5
+ m_LightAngle: 1
+ m_MaxDepthBias: 0.001
+ m_ShadowResolution:
+ m_Override: 512
+ m_UseOverride: 0
+ m_Level: 2
+ m_ShadowDimmer: 1
+ m_VolumetricShadowDimmer: 1
+ m_ShadowFadeDistance: 10000
+ m_UseContactShadow:
+ m_Override: 0
+ m_UseOverride: 1
+ m_Level: 0
+ m_RayTracedContactShadow: 0
+ m_ShadowTint: {r: 0, g: 0, b: 0, a: 1}
+ m_PenumbraTint: 0
+ m_NormalBias: 0.75
+ m_SlopeBias: 0.5
+ m_ShadowUpdateMode: 0
+ m_AlwaysDrawDynamicShadows: 0
+ m_UpdateShadowOnLightMovement: 0
+ m_CachedShadowTranslationThreshold: 0.01
+ m_CachedShadowAngularThreshold: 0.5
+ m_BarnDoorAngle: 90
+ m_BarnDoorLength: 0.05
+ m_preserveCachedShadow: 0
+ m_OnDemandShadowRenderOnPlacement: 1
+ m_ShadowCascadeRatios:
+ - 0.05
+ - 0.2
+ - 0.3
+ m_ShadowCascadeBorders:
+ - 0.2
+ - 0.2
+ - 0.2
+ - 0.2
+ m_ShadowAlgorithm: 0
+ m_ShadowVariant: 0
+ m_ShadowPrecision: 0
+ useOldInspector: 0
+ useVolumetric: 1
+ featuresFoldout: 1
+ m_AreaLightEmissiveMeshShadowCastingMode: 0
+ m_AreaLightEmissiveMeshMotionVectorGenerationMode: 0
+ m_AreaLightEmissiveMeshLayer: -1
+ m_Version: 11
+ m_ObsoleteShadowResolutionTier: 1
+ m_ObsoleteUseShadowQualitySettings: 0
+ m_ObsoleteCustomShadowResolution: 512
+ m_ObsoleteContactShadows: 0
+ m_PointlightHDType: 0
+ m_SpotLightShape: 0
+ m_AreaLightShape: 0
+--- !u!108 &427000173
+Light:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 427000171}
+ m_Enabled: 1
+ serializedVersion: 10
+ m_Type: 1
+ m_Shape: 0
+ m_Color: {r: 1, g: 1, b: 1, a: 1}
+ m_Intensity: 0.91254795
+ m_Range: 10
+ m_SpotAngle: 30
+ m_InnerSpotAngle: 21.80208
+ m_CookieSize: 10
+ m_Shadows:
+ m_Type: 1
+ m_Resolution: -1
+ m_CustomResolution: -1
+ m_Strength: 1
+ m_Bias: 0.05
+ m_NormalBias: 0.4
+ m_NearPlane: 0.2
+ m_CullingMatrixOverride:
+ e00: 1
+ e01: 0
+ e02: 0
+ e03: 0
+ e10: 0
+ e11: 1
+ e12: 0
+ e13: 0
+ e20: 0
+ e21: 0
+ e22: 1
+ e23: 0
+ e30: 0
+ e31: 0
+ e32: 0
+ e33: 1
+ m_UseCullingMatrixOverride: 0
+ m_Cookie: {fileID: 0}
+ m_DrawHalo: 0
+ m_Flare: {fileID: 0}
+ m_RenderMode: 0
+ m_CullingMask:
+ serializedVersion: 2
+ m_Bits: 4294967295
+ m_RenderingLayerMask: 1
+ m_Lightmapping: 4
+ m_LightShadowCasterMode: 2
+ m_AreaSize: {x: 0.5, y: 0.5}
+ m_BounceIntensity: 1
+ m_ColorTemperature: 6570
+ m_UseColorTemperature: 1
+ m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0}
+ m_UseBoundingSphereOverride: 0
+ m_UseViewFrustumForShadowCasterCull: 1
+ m_ShadowRadius: 0
+ m_ShadowAngle: 10
+--- !u!4 &427000174
+Transform:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 427000171}
+ m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261}
+ m_LocalPosition: {x: -0.34632424, y: 0.6943784, z: -3.69}
+ m_LocalScale: {x: 1, y: 1, z: 1}
+ m_Children: []
+ m_Father: {fileID: 0}
+ m_RootOrder: 3
+ m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0}
+--- !u!1 &573097141
+GameObject:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ serializedVersion: 6
+ m_Component:
+ - component: {fileID: 573097145}
+ - component: {fileID: 573097144}
+ - component: {fileID: 573097143}
+ - component: {fileID: 573097142}
+ m_Layer: 0
+ m_Name: Cube
+ m_TagString: Untagged
+ m_Icon: {fileID: 0}
+ m_NavMeshLayer: 0
+ m_StaticEditorFlags: 0
+ m_IsActive: 1
+--- !u!65 &573097142
+BoxCollider:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 573097141}
+ m_Material: {fileID: 0}
+ m_IsTrigger: 0
+ m_Enabled: 1
+ serializedVersion: 2
+ m_Size: {x: 1, y: 1, z: 1}
+ m_Center: {x: 0, y: 0, z: 0}
+--- !u!23 &573097143
+MeshRenderer:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 573097141}
+ m_Enabled: 1
+ m_CastShadows: 1
+ m_ReceiveShadows: 1
+ m_DynamicOccludee: 1
+ m_StaticShadowCaster: 0
+ m_MotionVectors: 1
+ m_LightProbeUsage: 1
+ m_ReflectionProbeUsage: 1
+ m_RayTracingMode: 2
+ m_RayTraceProcedural: 0
+ m_RenderingLayerMask: 257
+ m_RendererPriority: 0
+ m_Materials:
+ - {fileID: 2100000, guid: 9b2ba6a71192622429945206d1a902be, type: 2}
+ m_StaticBatchInfo:
+ firstSubMesh: 0
+ subMeshCount: 0
+ m_StaticBatchRoot: {fileID: 0}
+ m_ProbeAnchor: {fileID: 0}
+ m_LightProbeVolumeOverride: {fileID: 0}
+ m_ScaleInLightmap: 1
+ m_ReceiveGI: 1
+ m_PreserveUVs: 0
+ m_IgnoreNormalsForChartDetection: 0
+ m_ImportantGI: 0
+ m_StitchLightmapSeams: 1
+ m_SelectedEditorRenderState: 3
+ m_MinimumChartSize: 4
+ m_AutoUVMaxDistance: 0.5
+ m_AutoUVMaxAngle: 89
+ m_LightmapParameters: {fileID: 0}
+ m_SortingLayerID: 0
+ m_SortingLayer: 0
+ m_SortingOrder: 0
+ m_AdditionalVertexStreams: {fileID: 0}
+--- !u!33 &573097144
+MeshFilter:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 573097141}
+ m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
+--- !u!4 &573097145
+Transform:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 573097141}
+ m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
+ m_LocalPosition: {x: 0, y: 0.5, z: 0.212}
+ m_LocalScale: {x: 1, y: 1, z: 0.05}
+ m_Children: []
+ m_Father: {fileID: 0}
+ m_RootOrder: 0
+ m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
+--- !u!1 &582172468
+GameObject:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ serializedVersion: 6
+ m_Component:
+ - component: {fileID: 582172472}
+ - component: {fileID: 582172471}
+ - component: {fileID: 582172470}
+ - component: {fileID: 582172469}
+ m_Layer: 0
+ m_Name: Cube (1)
+ m_TagString: Untagged
+ m_Icon: {fileID: 0}
+ m_NavMeshLayer: 0
+ m_StaticEditorFlags: 0
+ m_IsActive: 1
+--- !u!65 &582172469
+BoxCollider:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 582172468}
+ m_Material: {fileID: 0}
+ m_IsTrigger: 0
+ m_Enabled: 1
+ serializedVersion: 2
+ m_Size: {x: 1, y: 1, z: 1}
+ m_Center: {x: 0, y: 0, z: 0}
+--- !u!23 &582172470
+MeshRenderer:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 582172468}
+ m_Enabled: 1
+ m_CastShadows: 1
+ m_ReceiveShadows: 1
+ m_DynamicOccludee: 1
+ m_StaticShadowCaster: 0
+ m_MotionVectors: 1
+ m_LightProbeUsage: 1
+ m_ReflectionProbeUsage: 1
+ m_RayTracingMode: 2
+ m_RayTraceProcedural: 0
+ m_RenderingLayerMask: 257
+ m_RendererPriority: 0
+ m_Materials:
+ - {fileID: 2100000, guid: 9b2ba6a71192622429945206d1a902be, type: 2}
+ m_StaticBatchInfo:
+ firstSubMesh: 0
+ subMeshCount: 0
+ m_StaticBatchRoot: {fileID: 0}
+ m_ProbeAnchor: {fileID: 0}
+ m_LightProbeVolumeOverride: {fileID: 0}
+ m_ScaleInLightmap: 1
+ m_ReceiveGI: 1
+ m_PreserveUVs: 0
+ m_IgnoreNormalsForChartDetection: 0
+ m_ImportantGI: 0
+ m_StitchLightmapSeams: 1
+ m_SelectedEditorRenderState: 3
+ m_MinimumChartSize: 4
+ m_AutoUVMaxDistance: 0.5
+ m_AutoUVMaxAngle: 89
+ m_LightmapParameters: {fileID: 0}
+ m_SortingLayerID: 0
+ m_SortingLayer: 0
+ m_SortingOrder: 0
+ m_AdditionalVertexStreams: {fileID: 0}
+--- !u!33 &582172471
+MeshFilter:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 582172468}
+ m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
+--- !u!4 &582172472
+Transform:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 582172468}
+ m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
+ m_LocalPosition: {x: 0, y: 1, z: 0}
+ m_LocalScale: {x: 0.5, y: 1, z: 0.05}
+ m_Children: []
+ m_Father: {fileID: 0}
+ m_RootOrder: 4
+ m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/717_DirectionalLightTransmission.unity.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/717_DirectionalLightTransmission.unity.meta
new file mode 100644
index 00000000000..c990857185e
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/717_DirectionalLightTransmission.unity.meta
@@ -0,0 +1,7 @@
+fileFormatVersion: 2
+guid: ba799739088f73744873fb5720fcddd3
+DefaultImporter:
+ externalObjects: {}
+ userData:
+ assetBundleName:
+ assetBundleVariant:
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/M_OpaqueTransmission.mat b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/M_OpaqueTransmission.mat
new file mode 100644
index 00000000000..6e070117bee
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/M_OpaqueTransmission.mat
@@ -0,0 +1,278 @@
+%YAML 1.1
+%TAG !u! tag:unity3d.com,2011:
+--- !u!21 &2100000
+Material:
+ serializedVersion: 6
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_Name: M_OpaqueTransmission
+ m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3}
+ m_ShaderKeywords: _DISABLE_SSR_TRANSPARENT _MATERIAL_FEATURE_TRANSMISSION _NORMALMAP_TANGENT_SPACE
+ m_LightmapFlags: 4
+ m_EnableInstancingVariants: 0
+ m_DoubleSidedGI: 0
+ m_CustomRenderQueue: 2225
+ stringTagMap: {}
+ disabledShaderPasses:
+ - TransparentDepthPrepass
+ - TransparentDepthPostpass
+ - TransparentBackface
+ - RayTracingPrepass
+ - MOTIONVECTORS
+ - ForwardEmissiveForDeferred
+ m_SavedProperties:
+ serializedVersion: 3
+ m_TexEnvs:
+ - _AnisotropyMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _BaseColorMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _BentNormalMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _BentNormalMapOS:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _CoatMaskMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _DetailMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _EmissiveColorMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _HeightMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _IridescenceMaskMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _IridescenceThicknessMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _MainTex:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _MaskMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _NormalMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _NormalMapOS:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _SpecularColorMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _SubsurfaceMaskMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _TangentMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _TangentMapOS:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _ThicknessMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - _TransmittanceColorMap:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - unity_Lightmaps:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - unity_LightmapsInd:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ - unity_ShadowMasks:
+ m_Texture: {fileID: 0}
+ m_Scale: {x: 1, y: 1}
+ m_Offset: {x: 0, y: 0}
+ m_Ints: []
+ m_Floats:
+ - _AORemapMax: 1
+ - _AORemapMin: 0
+ - _ATDistance: 1
+ - _AddPrecomputedVelocity: 0
+ - _AlbedoAffectEmissive: 0
+ - _AlphaCutoff: 0.5
+ - _AlphaCutoffEnable: 0
+ - _AlphaCutoffPostpass: 0.5
+ - _AlphaCutoffPrepass: 0.5
+ - _AlphaCutoffShadow: 0.5
+ - _AlphaDstBlend: 0
+ - _AlphaSrcBlend: 1
+ - _AlphaToMask: 0
+ - _AlphaToMaskInspectorValue: 0
+ - _Anisotropy: 0
+ - _BlendMode: 0
+ - _CoatMask: 0
+ - _CullMode: 2
+ - _CullModeForward: 2
+ - _Cutoff: 0.5
+ - _DepthOffsetEnable: 0
+ - _DetailAlbedoScale: 1
+ - _DetailNormalScale: 1
+ - _DetailSmoothnessScale: 1
+ - _DiffusionProfile: 0
+ - _DiffusionProfileHash: 3.8731465
+ - _DisplacementLockObjectScale: 1
+ - _DisplacementLockTilingScale: 1
+ - _DisplacementMode: 0
+ - _DoubleSidedEnable: 0
+ - _DoubleSidedGIMode: 0
+ - _DoubleSidedNormalMode: 1
+ - _DstBlend: 0
+ - _EmissiveColorMode: 1
+ - _EmissiveExposureWeight: 1
+ - _EmissiveIntensity: 1
+ - _EmissiveIntensityUnit: 0
+ - _EnableBlendModePreserveSpecularLighting: 1
+ - _EnableFogOnTransparent: 1
+ - _EnableGeometricSpecularAA: 0
+ - _EnergyConservingSpecularColor: 1
+ - _ForceForwardEmissive: 0
+ - _HeightAmplitude: 0.02
+ - _HeightCenter: 0.5
+ - _HeightMapParametrization: 0
+ - _HeightMax: 1
+ - _HeightMin: -1
+ - _HeightOffset: 0
+ - _HeightPoMAmplitude: 2
+ - _HeightTessAmplitude: 2
+ - _HeightTessCenter: 0.5
+ - _InvTilingScale: 1
+ - _Ior: 1.5
+ - _IridescenceMask: 1
+ - _IridescenceThickness: 1
+ - _LinkDetailsWithBase: 1
+ - _MaterialID: 5
+ - _Metallic: 0
+ - _MetallicRemapMax: 1
+ - _MetallicRemapMin: 0
+ - _NormalMapSpace: 0
+ - _NormalScale: 1
+ - _OpaqueCullMode: 2
+ - _PPDLodThreshold: 5
+ - _PPDMaxSamples: 15
+ - _PPDMinSamples: 5
+ - _PPDPrimitiveLength: 1
+ - _PPDPrimitiveWidth: 1
+ - _RayTracing: 0
+ - _ReceivesSSR: 1
+ - _ReceivesSSRTransparent: 0
+ - _RefractionModel: 0
+ - _Smoothness: 0.5
+ - _SmoothnessRemapMax: 1
+ - _SmoothnessRemapMin: 0
+ - _SpecularAAScreenSpaceVariance: 0.1
+ - _SpecularAAThreshold: 0.2
+ - _SpecularOcclusionMode: 1
+ - _SrcBlend: 1
+ - _StencilRef: 0
+ - _StencilRefDepth: 8
+ - _StencilRefGBuffer: 10
+ - _StencilRefMV: 40
+ - _StencilWriteMask: 6
+ - _StencilWriteMaskDepth: 8
+ - _StencilWriteMaskGBuffer: 14
+ - _StencilWriteMaskMV: 40
+ - _SubsurfaceMask: 1
+ - _SupportDecals: 1
+ - _SurfaceType: 0
+ - _TexWorldScale: 1
+ - _TexWorldScaleEmissive: 1
+ - _Thickness: 0.314
+ - _TransmissionEnable: 1
+ - _TransparentBackfaceEnable: 0
+ - _TransparentCullMode: 2
+ - _TransparentDepthPostpassEnable: 0
+ - _TransparentDepthPrepassEnable: 0
+ - _TransparentSortPriority: 0
+ - _TransparentWritingMotionVec: 0
+ - _TransparentZWrite: 0
+ - _UVBase: 0
+ - _UVDetail: 0
+ - _UVEmissive: 0
+ - _UseEmissiveIntensity: 0
+ - _UseShadowThreshold: 0
+ - _ZTestDepthEqualForOpaque: 3
+ - _ZTestGBuffer: 4
+ - _ZTestTransparent: 4
+ - _ZWrite: 1
+ m_Colors:
+ - _BaseColor: {r: 1, g: 1, b: 1, a: 1}
+ - _BaseColorMap_MipInfo: {r: 0, g: 0, b: 0, a: 0}
+ - _Color: {r: 1, g: 1, b: 1, a: 1}
+ - _DiffusionProfileAsset: {r: 0.000000012837806, g: 1.0465562e+32, b: -1.1395746e-14,
+ a: 1.8610732e+32}
+ - _DoubleSidedConstants: {r: 1, g: 1, b: -1, a: 0}
+ - _EmissionColor: {r: 1, g: 1, b: 1, a: 1}
+ - _EmissiveColor: {r: 0, g: 0, b: 0, a: 1}
+ - _EmissiveColorLDR: {r: 0, g: 0, b: 0, a: 1}
+ - _InvPrimScale: {r: 1, g: 1, b: 0, a: 0}
+ - _IridescenceThicknessRemap: {r: 0, g: 1, b: 0, a: 0}
+ - _SpecularColor: {r: 1, g: 1, b: 1, a: 1}
+ - _ThicknessRemap: {r: 0, g: 1, b: 0, a: 0}
+ - _TransmittanceColor: {r: 1, g: 1, b: 1, a: 1}
+ - _UVDetailsMappingMask: {r: 1, g: 0, b: 0, a: 0}
+ - _UVMappingMask: {r: 1, g: 0, b: 0, a: 0}
+ - _UVMappingMaskEmissive: {r: 1, g: 0, b: 0, a: 0}
+ m_BuildTextureStacks: []
+--- !u!114 &2848747090874986145
+MonoBehaviour:
+ m_ObjectHideFlags: 11
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 0}
+ m_Enabled: 1
+ m_EditorHideFlags: 0
+ m_Script: {fileID: 11500000, guid: aa486462e6be1764e89c788ba30e61f7, type: 3}
+ m_Name:
+ m_EditorClassIdentifier:
+ m_DiffusionProfileReferences:
+ - {fileID: 11400000, guid: 458d5c32111ea5749a494da813d01275, type: 2}
+ m_MaterialReferences: []
+--- !u!114 &4199369940823022338
+MonoBehaviour:
+ m_ObjectHideFlags: 11
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 0}
+ m_Enabled: 1
+ m_EditorHideFlags: 0
+ m_Script: {fileID: 11500000, guid: da692e001514ec24dbc4cca1949ff7e8, type: 3}
+ m_Name:
+ m_EditorClassIdentifier:
+ version: 12
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/M_OpaqueTransmission.mat.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/M_OpaqueTransmission.mat.meta
new file mode 100644
index 00000000000..c4560225b9a
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/M_OpaqueTransmission.mat.meta
@@ -0,0 +1,8 @@
+fileFormatVersion: 2
+guid: 9b2ba6a71192622429945206d1a902be
+NativeFormatImporter:
+ externalObjects: {}
+ mainObjectFileID: 2100000
+ userData:
+ assetBundleName:
+ assetBundleVariant:
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/TransmissionDiffusionProfile.asset b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/TransmissionDiffusionProfile.asset
new file mode 100644
index 00000000000..9c91f28cffb
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/TransmissionDiffusionProfile.asset
@@ -0,0 +1,24 @@
+%YAML 1.1
+%TAG !u! tag:unity3d.com,2011:
+--- !u!114 &11400000
+MonoBehaviour:
+ m_ObjectHideFlags: 0
+ m_CorrespondingSourceObject: {fileID: 0}
+ m_PrefabInstance: {fileID: 0}
+ m_PrefabAsset: {fileID: 0}
+ m_GameObject: {fileID: 0}
+ m_Enabled: 1
+ m_EditorHideFlags: 0
+ m_Script: {fileID: 11500000, guid: b2686e09ec7aef44bad2843e4416f057, type: 3}
+ m_Name: TransmissionDiffusionProfile
+ m_EditorClassIdentifier:
+ profile:
+ scatteringDistance: {r: 1.2569526, g: 0.8976935, b: 0.37352836, a: 1}
+ transmissionTint: {r: 1, g: 1, b: 1, a: 1}
+ texturingMode: 0
+ transmissionMode: 1
+ thicknessRemap: {x: 0, y: 2.693727}
+ worldScale: 1
+ ior: 1.053
+ hash: 1081598370
+ m_Version: 1
diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/TransmissionDiffusionProfile.asset.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/TransmissionDiffusionProfile.asset.meta
new file mode 100644
index 00000000000..204367e8cbb
--- /dev/null
+++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/ShadowData/TransmissionDiffusionProfile.asset.meta
@@ -0,0 +1,8 @@
+fileFormatVersion: 2
+guid: 458d5c32111ea5749a494da813d01275
+NativeFormatImporter:
+ externalObjects: {}
+ mainObjectFileID: 11400000
+ userData:
+ assetBundleName:
+ assetBundleVariant:
diff --git a/TestProjects/HDRP_DXR_Tests/ProjectSettings/EditorBuildSettings.asset b/TestProjects/HDRP_DXR_Tests/ProjectSettings/EditorBuildSettings.asset
index a1c98a2d8b3..30f63a1259c 100644
--- a/TestProjects/HDRP_DXR_Tests/ProjectSettings/EditorBuildSettings.asset
+++ b/TestProjects/HDRP_DXR_Tests/ProjectSettings/EditorBuildSettings.asset
@@ -164,6 +164,9 @@ EditorBuildSettings:
- enabled: 1
path: Assets/Scenes/713_PointShadow_Matte.unity
guid: 7e23108915e5705409db2943ac41fc38
+ - enabled: 1
+ path: Assets/Scenes/717_DirectionalLightTransmission.unity
+ guid: ba799739088f73744873fb5720fcddd3
- enabled: 1
path: Assets/Scenes/801_SubSurfaceScatteringDeferred.unity
guid: c939ce56b901d264baab16d584624b30
diff --git a/com.unity.render-pipelines.high-definition/CHANGELOG.md b/com.unity.render-pipelines.high-definition/CHANGELOG.md
index 628297f2a3f..3ab3141c9f8 100644
--- a/com.unity.render-pipelines.high-definition/CHANGELOG.md
+++ b/com.unity.render-pipelines.high-definition/CHANGELOG.md
@@ -34,6 +34,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Added the support of interpolators for SV_POSITION in shader graph.
- Added a "Conservative" mode for shader graph depth offset.
- Added an error message when trying to use disk lights with realtime GI (case 1317808).
+- Added a fallback for the ray traced directional shadow in case of a transmission (case 1307870).
### Fixed
- Fixed Intensity Multiplier not affecting realtime global illumination.
diff --git a/com.unity.render-pipelines.high-definition/Documentation~/Light-Component.md b/com.unity.render-pipelines.high-definition/Documentation~/Light-Component.md
index e64b68bcc17..a3433ebc34f 100644
--- a/com.unity.render-pipelines.high-definition/Documentation~/Light-Component.md
+++ b/com.unity.render-pipelines.high-definition/Documentation~/Light-Component.md
@@ -63,9 +63,9 @@ To make the Light work with the **Animation window**, when you click on the **Ad
| **Type** | **Description** |
| --------------- | ------------------------------------------------------------ |
| **Spot** | Emits light from a specified location and range over which the light diminishes. A Spot Light constrains the light it emits to an angle, which results in a cone-shaped region of illumination. The center of the cone points in the forward direction (z-axis) of the Light GameObject. Light also diminishes at the edges of the Spot Light’s cone. Increase the **Spot Angle** to increase the width of the cone. |
-| **Directional** | Creates effects that are similar to sunlight in your Scene. Like sunlight, Directional Lights are distant light sources that HDRP treats as though they are infinitely far away. A Directional Light does not have any identifiable source position, and you can place the Light GameObject anywhere in the Scene. A **Directional Light** illuminates all GameObjects in the Scene as if the Light rays are parallel and always from the same direction. The Light disregards the distance between the Light itself and the target GameObject, so the Light does not diminish with distance. |
-| **Point** | Projects light out equally in all directions from a point in space. The direction of light hitting a surface is the line from the point of contact back to the center of the Light GameObject. The light intensity diminishes with increased distance from the Light, and it reaches zero at the distance specified in the **Range** field. Light intensity is inversely proportional to the square of the distance from the source. This is known as the [Inverse-square law](https://en.wikipedia.org/wiki/Inverse-square_law), and is similar to how light behaves in the real world. |
-| **Area** | Projects light from a surface. Light shines in all directions uniformly from the surface of the rectangle.|
+| **Directional** | Creates effects that are similar to sunlight in your Scene. Like sunlight, Directional Lights are distant light sources that HDRP treats as though they are infinitely far away. A Directional Light does not have any identifiable source position, and you can place the Light GameObject anywhere in the Scene.
A **Directional Light** illuminates all GameObjects in the Scene as if the Light rays are parallel and always from the same direction. The Light disregards the distance between the Light itself and the target GameObject, so the Light does not diminish with distance |
+| **Point** | Projects light out equally in all directions from a point in space. The direction of light hitting a surface is the line from the point of contact back to the center of the Light GameObject. The light intensity diminishes with increased distance from the Light, and it reaches zero at the distance specified in the **Range** field.
Light intensity is inversely proportional to the square of the distance from the source. This is known as the [Inverse-square law](https://en.wikipedia.org/wiki/Inverse-square_law), and is similar to how light behaves in the real world. |
+| **Area** | Projects light from a surface. Light shines in all directions uniformly from the surface of the rectangle. |
##### Limitations
diff --git a/com.unity.render-pipelines.high-definition/Documentation~/Ray-Traced-Shadows.md b/com.unity.render-pipelines.high-definition/Documentation~/Ray-Traced-Shadows.md
index 13bac8a3757..6f514837fb1 100644
--- a/com.unity.render-pipelines.high-definition/Documentation~/Ray-Traced-Shadows.md
+++ b/com.unity.render-pipelines.high-definition/Documentation~/Ray-Traced-Shadows.md
@@ -51,6 +51,8 @@ Ray-traced shadows offer an alternative to the cascade shadow map that Direction
Ray-traced shadows allow for transparent and transmissive GameObjects, lit by Directional Lights, to cast colored shadows.
+**Note**: When you use a Directional Light with a transmissive GameObject, HDRP displays rasterized shadows on the reverse side of the GameObject.
+

**Ray-traced Directional Light shadows with colored shadows**
@@ -87,7 +89,7 @@ Ray-traced shadows offer an alternative to the shadow map that Point and Spot Li
**Ray-traced Point Light shadows (radius = 0.5m)**
-Ray-traced shadows offer the possibility of semi-transparent shadows for Point Lights cast by tranparent and transmissive GameObjects.
+Ray-traced shadows offer the possibility of semi-transparent shadows for Point Lights cast by transparent and transmissive GameObjects.

@@ -122,6 +124,8 @@ Ray-traced shadows offer an alternative to the [exponential variance shadow map]
**Note**: When rendering in [deferred mode](Forward-And-Deferred-Rendering.md), HDRP provides accurate ray-traced area light shadows for the [Lit](Lit-Shader.md) shader. When HDRP renders for any other shader, or for the Lit shader in forward mode, it uses an approximation to calculate ray-traced shadows for area lights. This approximation is not perfectly accurate, but does produce plausible results.
+When you use a Rectangle Light with a transmissive GameObject, HDRP displays rasterized shadows on the reverse side of the GameObject
+
### Properties
| Property | Description |
diff --git a/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs b/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs
index bf933ed2426..bfb10092124 100644
--- a/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs
+++ b/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs
@@ -118,6 +118,7 @@ class LightDefinitions
public static uint s_MaterialFeatureMaskFlags = 0x000FFF; // don't use all bits just to be safe from signed and/or float conversions :/
// Screen space shadow flags
+ public static uint s_RayTracedScreenSpaceShadowFlag = 0x1000;
public static uint s_ScreenSpaceColorShadowFlag = 0x100;
public static uint s_InvalidScreenSpaceShadow = 0xff;
public static uint s_ScreenSpaceShadowIndexMask = 0xff;
@@ -1184,6 +1185,11 @@ internal void GetDirectionalLightData(CommandBuffer cmd, HDCamera hdCamera, Visi
{
screenSpaceShadowslot++;
}
+
+ // Raise the ray tracing flag in case the light is ray traced
+ if (additionalLightData.WillRenderRayTracedShadow())
+ lightData.screenSpaceShadowIndex |= (int)LightDefinitions.s_RayTracedScreenSpaceShadowFlag;
+
screenSpaceShadowIndex++;
m_ScreenSpaceShadowsUnion.Add(additionalLightData);
}
diff --git a/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs.hlsl b/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs.hlsl
index 123382ceff5..dca8236c2c2 100644
--- a/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs.hlsl
+++ b/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs.hlsl
@@ -55,6 +55,7 @@
#define LIGHT_FEATURE_MASK_FLAGS_OPAQUE (16642048)
#define LIGHT_FEATURE_MASK_FLAGS_TRANSPARENT (16510976)
#define MATERIAL_FEATURE_MASK_FLAGS (4095)
+#define RAY_TRACED_SCREEN_SPACE_SHADOW_FLAG (4096)
#define SCREEN_SPACE_COLOR_SHADOW_FLAG (256)
#define INVALID_SCREEN_SPACE_SHADOW (255)
#define SCREEN_SPACE_SHADOW_INDEX_MASK (255)
diff --git a/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.hlsl b/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.hlsl
index 7cc10b88a80..a73a4affc82 100644
--- a/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.hlsl
+++ b/com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.hlsl
@@ -81,6 +81,17 @@ void ApplyDebugToLighting(LightLoopContext context, inout BuiltinData builtinDat
#endif
}
+bool UseScreenSpaceShadow(DirectionalLightData light, float3 normalWS)
+{
+ // Two different options are possible here
+ // - We have a ray trace shadow in which case we have no valid signal for a transmission and we need to fallback on the rasterized shadow
+ // - We have a screen space shadow and it already contains the transmission shadow and we can use it straight away
+ bool visibleLight = dot(normalWS, -light.forward) > 0.0;
+ bool validScreenSpaceShadow = (light.screenSpaceShadowIndex & SCREEN_SPACE_SHADOW_INDEX_MASK) != INVALID_SCREEN_SPACE_SHADOW;
+ bool rayTracedShadow = (light.screenSpaceShadowIndex & RAY_TRACED_SCREEN_SPACE_SHADOW_FLAG) != 0;
+ return (validScreenSpaceShadow && ((rayTracedShadow && visibleLight) || !rayTracedShadow));
+}
+
void ApplyDebug(LightLoopContext context, PositionInputs posInput, BSDFData bsdfData, inout LightLoopOutput lightLoopOutput)
{
#ifdef DEBUG_DISPLAY
@@ -122,7 +133,7 @@ void ApplyDebug(LightLoopContext context, PositionInputs posInput, BSDFData bsdf
DirectionalLightData light = _DirectionalLightDatas[_DirectionalShadowIndex];
#if defined(SCREEN_SPACE_SHADOWS_ON) && !defined(_SURFACE_TYPE_TRANSPARENT)
- if ((light.screenSpaceShadowIndex & SCREEN_SPACE_SHADOW_INDEX_MASK) != INVALID_SCREEN_SPACE_SHADOW)
+ if (UseScreenSpaceShadow(light, bsdfData.normalWS))
{
shadow = GetScreenSpaceColorShadow(posInput, light.screenSpaceShadowIndex).SHADOW_TYPE_SWIZZLE;
}
@@ -202,7 +213,7 @@ void LightLoop( float3 V, PositionInputs posInput, PreLightData preLightData, BS
DirectionalLightData light = _DirectionalLightDatas[_DirectionalShadowIndex];
#if defined(SCREEN_SPACE_SHADOWS_ON) && !defined(_SURFACE_TYPE_TRANSPARENT)
- if ((light.screenSpaceShadowIndex & SCREEN_SPACE_SHADOW_INDEX_MASK) != INVALID_SCREEN_SPACE_SHADOW)
+ if (UseScreenSpaceShadow(light, bsdfData.normalWS))
{
context.shadowValue = GetScreenSpaceColorShadow(posInput, light.screenSpaceShadowIndex).SHADOW_TYPE_SWIZZLE;
}