diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png index 58f3ec3b244..551225eaddb 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8ceb91cb624b7c428911efde6befd0b903cb4a4c0c6f429715f378c0096428f9 -size 593509 +oid sha256:1d89b80bf46ef683385d5187161549275e2e8d90e25d5a091586f3b197ed0fc1 +size 597640 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5001_PathTracing.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5001_PathTracing.png index cef90a28907..bfce5e1eb93 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5001_PathTracing.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5001_PathTracing.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e27b8251e0a49db0ac7d78e05cac6045b593d29a2aaf0c41dfa3470513d8ad5 -size 573961 +oid sha256:565701b3b6a07b250d278aaa00dd23db384f841fe2093d6811b96889e918f8d1 +size 578141 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5003_PathTracing_transparency.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5003_PathTracing_transparency.png index dd69b1a423e..0ac08f69969 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5003_PathTracing_transparency.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5003_PathTracing_transparency.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dc38ea9ae91b8ee15318c1e62948c30de267fa3f18ee31988c31db3c543ea21b -size 816829 +oid sha256:13c4b4ff33137c3ce6d6c080aef1a30da908c011c96732ed2152f576c67fcbf7 +size 817056 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5006_PathTracing_DoF.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5006_PathTracing_DoF.png index afe33c09740..52cf5c12803 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5006_PathTracing_DoF.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5006_PathTracing_DoF.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4a1be4770d57a043a2c05efdfa1b8034bc05213e4e9d377ed97d7d0effe31d6e -size 581407 +oid sha256:e6e92d500558704f06404a215aa276dbf7a83a6805ae3338ec8cd70c8d3c3698 +size 595739 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png index 39f79b0fa2f..5d7919b51d0 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:725c3b80a3d7276968bffc9deebe56c019716790f524c0473b66d68a339e6915 -size 425111 +oid sha256:67c62545982a194d91f750714063101250448bf7cfeec8bbe6dcce14a1da4312 +size 431067 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5008_PathTracing_NormalMapping.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5008_PathTracing_NormalMapping.png index d1c7830d645..5922f64dbda 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5008_PathTracing_NormalMapping.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5008_PathTracing_NormalMapping.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe758bbfeb12a3eab1223c4a4f69edb4bef9e77e14981d517dbdb444a1d20fb1 -size 689301 +oid sha256:e1bdcfe461ff21a1e3797ab8ee31f04279dc87e8c64414cfa9c529097f2c9b88 +size 708676 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5009_PathTracing_FabricMaterial.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5009_PathTracing_FabricMaterial.png index ed74818602c..b9ad42d2b7f 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5009_PathTracing_FabricMaterial.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsEditor/Direct3D12/None/5009_PathTracing_FabricMaterial.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:11c232951ae60e26202b187785c3c1ece29e9ac51c34d1c401d27169204f1439 -size 637902 +oid sha256:262f37f2c89b869bde05eab3df55d672e9902c3970f22214580a5dd8d785fe3a +size 638756 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png index 3db1baabbd5..551225eaddb 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/1000_RaytracingQualityKeyword_PathTracer_Default.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f5bd13fedf367db42d061aabe39a07b8d5e557a87fef0be971e1460c784692d7 -size 594092 +oid sha256:1d89b80bf46ef683385d5187161549275e2e8d90e25d5a091586f3b197ed0fc1 +size 597640 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5001_PathTracing.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5001_PathTracing.png index 38aa3b7635d..bfce5e1eb93 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5001_PathTracing.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5001_PathTracing.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a3895661050aac74184f0828cbedeadd6344b378ef97c7c1d638afb68956245c -size 602331 +oid sha256:565701b3b6a07b250d278aaa00dd23db384f841fe2093d6811b96889e918f8d1 +size 578141 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5003_PathTracing_transparency.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5003_PathTracing_transparency.png index 8e108fcf9d7..0ac08f69969 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5003_PathTracing_transparency.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5003_PathTracing_transparency.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0cbcabf92bd1e0b92be8ecd9bbb0f15b6f80360506edfd255407bab4c6d70942 -size 816576 +oid sha256:13c4b4ff33137c3ce6d6c080aef1a30da908c011c96732ed2152f576c67fcbf7 +size 817056 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5006_PathTracing_DoF.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5006_PathTracing_DoF.png index 949c4be4797..52cf5c12803 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5006_PathTracing_DoF.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5006_PathTracing_DoF.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3da49dbfdbe6f3c6bcfdf351991838b263e49a1e8ad83bab1ea2f0d8c7ad8ff9 -size 660038 +oid sha256:e6e92d500558704f06404a215aa276dbf7a83a6805ae3338ec8cd70c8d3c3698 +size 595739 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png index c8cbc803c52..5d7919b51d0 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5007_PathTracing_Materials_SG_Lit.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:58698111dd23aae471a3872331d06c0cd9db5b33015b8e8dcb56cb69ef337a85 -size 556660 +oid sha256:67c62545982a194d91f750714063101250448bf7cfeec8bbe6dcce14a1da4312 +size 431067 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5008_PathTracing_NormalMapping.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5008_PathTracing_NormalMapping.png new file mode 100644 index 00000000000..5922f64dbda --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5008_PathTracing_NormalMapping.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e1bdcfe461ff21a1e3797ab8ee31f04279dc87e8c64414cfa9c529097f2c9b88 +size 708676 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5008_PathTracing_NormalMapping.png.meta b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5008_PathTracing_NormalMapping.png.meta new file mode 100644 index 00000000000..a249f7976c4 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5008_PathTracing_NormalMapping.png.meta @@ -0,0 +1,97 @@ +fileFormatVersion: 2 +guid: e895d0812f0bf264bba647ecf1054527 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + 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: 0 + 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: 1 + 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: 1 + 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/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5009_PathTracing_FabricMaterial.png b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5009_PathTracing_FabricMaterial.png new file mode 100644 index 00000000000..b9ad42d2b7f --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5009_PathTracing_FabricMaterial.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:262f37f2c89b869bde05eab3df55d672e9902c3970f22214580a5dd8d785fe3a +size 638756 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5009_PathTracing_FabricMaterial.png.meta b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5009_PathTracing_FabricMaterial.png.meta new file mode 100644 index 00000000000..d29016d5464 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/ReferenceImages/Linear/WindowsPlayer/Direct3D12/None/5009_PathTracing_FabricMaterial.png.meta @@ -0,0 +1,97 @@ +fileFormatVersion: 2 +guid: a8135e09d2b70c74c903b12da90908d2 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + 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: 0 + 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: 1 + 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: 1 + 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/5008_PathTracing_NormalMapping.unity b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping.unity index 4eb61185e6c..69deff67b87 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping.unity +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping.unity @@ -38,7 +38,7 @@ RenderSettings: m_ReflectionIntensity: 1 m_CustomReflection: {fileID: 0} m_Sun: {fileID: 0} - m_IndirectSpecularColor: {r: 0.33350468, g: 0.49948496, b: 0.8330078, a: 1} + m_IndirectSpecularColor: {r: 0.33339566, g: 0.49941906, b: 0.8330078, a: 1} m_UseRadianceAmbientProbe: 0 --- !u!157 &3 LightmapSettings: @@ -168,6 +168,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -251,6 +252,102 @@ Transform: m_Father: {fileID: 0} m_RootOrder: 5 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &237343301 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 237343305} + - component: {fileID: 237343304} + - component: {fileID: 237343303} + - component: {fileID: 237343302} + m_Layer: 0 + m_Name: Sphere_Smoothness_.25 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!135 &237343302 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 237343301} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &237343303 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 237343301} + 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: 3c5ef18527c5c5149ae44ebab54cce79, 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 &237343304 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 237343301} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &237343305 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 237343301} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 4, y: 0.75, z: 8.5} + m_LocalScale: {x: 1.5, y: 1.5, z: 1.5} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 10 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &277314768 GameObject: m_ObjectHideFlags: 0 @@ -281,14 +378,6 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 7a68c43fe1f2a47cfa234b5eeaa98012, type: 3} m_Name: m_EditorClassIdentifier: - m_Version: 11 - m_ObsoleteShadowResolutionTier: 1 - m_ObsoleteUseShadowQualitySettings: 0 - m_ObsoleteCustomShadowResolution: 512 - m_ObsoleteContactShadows: 0 - m_PointlightHDType: 0 - m_SpotLightShape: 0 - m_AreaLightShape: 0 m_Intensity: 15915.494 m_EnableSpotReflector: 0 m_LuxAtDistance: 1 @@ -298,6 +387,7 @@ MonoBehaviour: m_VolumetricDimmer: 1 m_LightUnit: 2 m_FadeDistance: 10000 + m_VolumetricFadeDistance: 10000 m_AffectDiffuse: 1 m_AffectSpecular: 1 m_NonLightmappedOnly: 0 @@ -314,6 +404,7 @@ MonoBehaviour: m_AreaLightCookie: {fileID: 0} m_IESPoint: {fileID: 0} m_IESSpot: {fileID: 0} + m_IncludeForRayTracing: 1 m_AreaLightShadowCone: 120 m_UseScreenSpaceShadows: 0 m_InteractsWithSky: 1 @@ -363,9 +454,14 @@ MonoBehaviour: 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 @@ -381,10 +477,17 @@ MonoBehaviour: useOldInspector: 0 useVolumetric: 1 featuresFoldout: 1 - showAdditionalSettings: 0 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 &277314770 Light: m_ObjectHideFlags: 0 @@ -521,7 +624,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 634879374} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: -5.2, y: 0.2, z: 12} + m_LocalPosition: {x: 0, y: 0.2, z: 12} m_LocalScale: {x: 0.5, y: 0.5, z: 0.5} m_Children: [] m_Father: {fileID: 1882146458} @@ -552,6 +655,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -590,6 +694,102 @@ MeshFilter: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 634879374} m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &648018543 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 648018547} + - component: {fileID: 648018546} + - component: {fileID: 648018545} + - component: {fileID: 648018544} + m_Layer: 0 + m_Name: Sphere_Smoothness_1 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!135 &648018544 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 648018543} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &648018545 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 648018543} + 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: faf33607ada8b3943b6808704599071d, 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 &648018546 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 648018543} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &648018547 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 648018543} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -6, y: 0.75, z: 8.5} + m_LocalScale: {x: 1.5, y: 1.5, z: 1.5} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 6 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &726446113 GameObject: m_ObjectHideFlags: 0 @@ -634,6 +834,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -686,6 +887,102 @@ Transform: m_Father: {fileID: 1882146458} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} +--- !u!1 &848986946 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 848986950} + - component: {fileID: 848986949} + - component: {fileID: 848986948} + - component: {fileID: 848986947} + m_Layer: 0 + m_Name: Sphere (4) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!135 &848986947 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848986946} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &848986948 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848986946} + 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: 3431e9ceee1f099449e113d44328f6fb, 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 &848986949 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848986946} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &848986950 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 848986946} + m_LocalRotation: {x: 0, y: 0.5735764, z: 0, w: 0.8191521} + m_LocalPosition: {x: 2, y: 0.75, z: 8.5} + m_LocalScale: {x: 1.5, y: 1.5, z: 1.5} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 9 + m_LocalEulerAnglesHint: {x: 0, y: 70, z: 0} --- !u!1 &910509911 GameObject: m_ObjectHideFlags: 0 @@ -751,6 +1048,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -781,7 +1079,7 @@ MeshRenderer: m_SortingLayer: 0 m_SortingOrder: 0 m_AdditionalVertexStreams: {fileID: 0} ---- !u!1 &1157225236 +--- !u!1 &1081729457 GameObject: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -789,37 +1087,125 @@ GameObject: m_PrefabAsset: {fileID: 0} serializedVersion: 6 m_Component: - - component: {fileID: 1157225239} - - component: {fileID: 1157225238} - - component: {fileID: 1157225237} + - component: {fileID: 1081729461} + - component: {fileID: 1081729460} + - component: {fileID: 1081729459} + - component: {fileID: 1081729458} m_Layer: 0 - m_Name: Directional Light + m_Name: Sphere_Smoothness_.75 m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!114 &1157225237 -MonoBehaviour: +--- !u!135 &1081729458 +SphereCollider: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1157225236} + m_GameObject: {fileID: 1081729457} + m_Material: {fileID: 0} + m_IsTrigger: 0 m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 7a68c43fe1f2a47cfa234b5eeaa98012, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Version: 11 - m_ObsoleteShadowResolutionTier: 1 - m_ObsoleteUseShadowQualitySettings: 0 - m_ObsoleteCustomShadowResolution: 512 - m_ObsoleteContactShadows: 0 - m_PointlightHDType: 0 - m_SpotLightShape: 0 - m_AreaLightShape: 0 - m_Intensity: 5 + serializedVersion: 2 + m_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &1081729459 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1081729457} + 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: 6d46aa105532cc040b4e30aaa7bd9b3c, 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 &1081729460 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1081729457} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &1081729461 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1081729457} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -4, y: 0.75, z: 8.5} + m_LocalScale: {x: 1.5, y: 1.5, z: 1.5} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1157225236 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1157225239} + - component: {fileID: 1157225238} + - component: {fileID: 1157225237} + 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 &1157225237 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1157225236} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 7a68c43fe1f2a47cfa234b5eeaa98012, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Intensity: 5 m_EnableSpotReflector: 0 m_LuxAtDistance: 1 m_InnerSpotPercent: 0 @@ -828,6 +1214,7 @@ MonoBehaviour: m_VolumetricDimmer: 1 m_LightUnit: 2 m_FadeDistance: 10000 + m_VolumetricFadeDistance: 10000 m_AffectDiffuse: 1 m_AffectSpecular: 1 m_NonLightmappedOnly: 0 @@ -844,6 +1231,7 @@ MonoBehaviour: m_AreaLightCookie: {fileID: 0} m_IESPoint: {fileID: 0} m_IESSpot: {fileID: 0} + m_IncludeForRayTracing: 1 m_AreaLightShadowCone: 120 m_UseScreenSpaceShadows: 1 m_InteractsWithSky: 1 @@ -893,9 +1281,14 @@ MonoBehaviour: 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 @@ -911,10 +1304,17 @@ MonoBehaviour: useOldInspector: 0 useVolumetric: 1 featuresFoldout: 1 - showAdditionalSettings: 0 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 &1157225238 Light: m_ObjectHideFlags: 0 @@ -1056,6 +1456,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -1086,6 +1487,102 @@ MeshRenderer: m_SortingLayer: 0 m_SortingOrder: 0 m_AdditionalVertexStreams: {fileID: 0} +--- !u!1 &1383548813 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1383548817} + - component: {fileID: 1383548816} + - component: {fileID: 1383548815} + - component: {fileID: 1383548814} + m_Layer: 0 + m_Name: Sphere (5) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!135 &1383548814 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1383548813} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &1383548815 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1383548813} + 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: 03a51d8fe223f844f857fc9c6b8ce758, 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 &1383548816 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1383548813} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &1383548817 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1383548813} + m_LocalRotation: {x: 0, y: 0.5735764, z: 0, w: 0.8191521} + m_LocalPosition: {x: 0, y: 0.75, z: 8.5} + m_LocalScale: {x: 1.5, y: 1.5, z: 1.5} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 12 + m_LocalEulerAnglesHint: {x: 0, y: 70, z: 0} --- !u!1001 &1425876746 PrefabInstance: m_ObjectHideFlags: 0 @@ -1097,17 +1594,25 @@ PrefabInstance: propertyPath: m_Name value: HDRP_Test_Camera objectReference: {fileID: 0} + - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} + propertyPath: m_RootOrder + value: 0 + 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: 7.17 + value: 7.87 objectReference: {fileID: 0} - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} propertyPath: m_LocalPosition.z - value: 4.46 + value: 3.86 + objectReference: {fileID: 0} + - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} + propertyPath: m_LocalRotation.w + value: 0.9396927 objectReference: {fileID: 0} - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} propertyPath: m_LocalRotation.x @@ -1121,14 +1626,6 @@ PrefabInstance: propertyPath: m_LocalRotation.z value: 0 objectReference: {fileID: 0} - - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: m_LocalRotation.w - value: 0.9396927 - objectReference: {fileID: 0} - - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: m_RootOrder - value: 0 - objectReference: {fileID: 0} - target: {fileID: 4209882255362944, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} propertyPath: m_LocalEulerAnglesHint.x value: 40 @@ -1158,13 +1655,13 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 114777190906822814, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: m_RenderingPathCustomFrameSettings.bitDatas.data1 - value: 70005818916701 + propertyPath: clearColorMode + value: 0 objectReference: {fileID: 0} - target: {fileID: 114777190906822814, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: backgroundColorHDR.r - value: 0.11953845 + propertyPath: backgroundColorHDR.b + value: 0.12477186 objectReference: {fileID: 0} - target: {fileID: 114777190906822814, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} @@ -1173,23 +1670,23 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 114777190906822814, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: backgroundColorHDR.b - value: 0.12477186 + propertyPath: backgroundColorHDR.r + value: 0.11953845 objectReference: {fileID: 0} - target: {fileID: 114777190906822814, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: clearColorMode - value: 0 + propertyPath: m_RenderingPathCustomFrameSettings.bitDatas.data1 + value: 70005818916701 objectReference: {fileID: 0} - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: ImageComparisonSettings.TargetWidth - value: 768 + propertyPath: waitFrames + value: 1 objectReference: {fileID: 0} - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: ImageComparisonSettings.TargetHeight - value: 384 + propertyPath: xrCompatible + value: 0 objectReference: {fileID: 0} - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} @@ -1204,18 +1701,18 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: waitFrames + propertyPath: renderGraphCompatible value: 1 objectReference: {fileID: 0} - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: xrCompatible - value: 0 + propertyPath: ImageComparisonSettings.TargetWidth + value: 768 objectReference: {fileID: 0} - target: {fileID: 114995348509370400, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} - propertyPath: renderGraphCompatible - value: 1 + propertyPath: ImageComparisonSettings.TargetHeight + value: 384 objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: c07ace9ab142ca9469fa377877c2f1e7, type: 3} @@ -1325,6 +1822,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -1363,6 +1861,102 @@ MeshFilter: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1597749229} m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1651306499 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1651306503} + - component: {fileID: 1651306502} + - component: {fileID: 1651306501} + - component: {fileID: 1651306500} + m_Layer: 0 + m_Name: Sphere (2) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!135 &1651306500 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1651306499} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &1651306501 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1651306499} + 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: 0bc0c78cb389b3c4593c3463f43b818f, 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 &1651306502 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1651306499} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &1651306503 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1651306499} + m_LocalRotation: {x: 0, y: 0.13052616, z: 0, w: 0.9914449} + m_LocalPosition: {x: -2, y: 0.75, z: 8.5} + m_LocalScale: {x: 1.5, y: 1.5, z: 1.5} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 8 + m_LocalEulerAnglesHint: {x: 0, y: 15, z: 0} --- !u!1 &1790480761 GameObject: m_ObjectHideFlags: 0 @@ -1390,7 +1984,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1790480761} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0.2, z: 12} + m_LocalPosition: {x: -5.2, y: 0.2, z: 12} m_LocalScale: {x: 0.5, y: 0.5, z: 0.5} m_Children: [] m_Father: {fileID: 1882146458} @@ -1421,6 +2015,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -1559,6 +2154,7 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 @@ -1589,3 +2185,99 @@ MeshRenderer: m_SortingLayer: 0 m_SortingOrder: 0 m_AdditionalVertexStreams: {fileID: 0} +--- !u!1 &2132717196 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2132717200} + - component: {fileID: 2132717199} + - component: {fileID: 2132717198} + - component: {fileID: 2132717197} + m_Layer: 0 + m_Name: Sphere_Smoothness_0 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!135 &2132717197 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2132717196} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &2132717198 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2132717196} + 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: 095bca25cc5005c46a84523037248f61, 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 &2132717199 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2132717196} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!4 &2132717200 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2132717196} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 6, y: 0.75, z: 8.5} + m_LocalScale: {x: 1.5, y: 1.5, z: 1.5} + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 11 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/ReflectionMtl.mat b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/ReflectionMtl.mat index 6441fb97eb7..ee15b571105 100644 --- a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/ReflectionMtl.mat +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/ReflectionMtl.mat @@ -85,7 +85,7 @@ Material: m_Offset: {x: 0, y: 0} - _MainTex: m_Texture: {fileID: 0} - m_Scale: {x: 1, y: 1} + m_Scale: {x: 50, y: 10} m_Offset: {x: 0, y: 0} - _MaskMap: m_Texture: {fileID: 0} @@ -181,6 +181,7 @@ Material: - _DistortionVectorBias: -1 - _DistortionVectorScale: 2 - _DoubleSidedEnable: 0 + - _DoubleSidedGIMode: 0 - _DoubleSidedNormalMode: 1 - _DstBlend: 0 - _EmissiveColorMode: 1 diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_AlphaClip.mat b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_AlphaClip.mat new file mode 100644 index 00000000000..a975f583d6c --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_AlphaClip.mat @@ -0,0 +1,264 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &-2205227687880834299 +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 +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Sphere_AlphaClip + m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3} + m_ShaderKeywords: _ALPHATEST_ON _DISABLE_SSR_TRANSPARENT _DOUBLESIDED_ON _NORMALMAP + _NORMALMAP_TANGENT_SPACE + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 1 + m_CustomRenderQueue: 2475 + stringTagMap: + RenderType: TransparentCutout + 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: 2800000, guid: deef39d0b4d72ab40adc1a64bc4a5265, type: 3} + 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: 2800000, guid: deef39d0b4d72ab40adc1a64bc4a5265, type: 3} + 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: 2800000, guid: 57fce5aa5865eaa4fbb2111399715db7, type: 3} + 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: 1 + - _AlphaCutoffPostpass: 0.5 + - _AlphaCutoffPrepass: 0.5 + - _AlphaCutoffShadow: 0.5 + - _AlphaDstBlend: 0 + - _AlphaSrcBlend: 1 + - _AlphaToMask: 0 + - _AlphaToMaskInspectorValue: 0 + - _Anisotropy: 0 + - _BlendMode: 0 + - _CoatMask: 0 + - _CullMode: 0 + - _CullModeForward: 0 + - _Cutoff: 0.5 + - _DepthOffsetEnable: 0 + - _DetailAlbedoScale: 1 + - _DetailNormalScale: 1 + - _DetailSmoothnessScale: 1 + - _DiffusionProfile: 0 + - _DiffusionProfileHash: 0 + - _DisplacementLockObjectScale: 1 + - _DisplacementLockTilingScale: 1 + - _DisplacementMode: 0 + - _DoubleSidedEnable: 1 + - _DoubleSidedGIMode: 0 + - _DoubleSidedNormalMode: 0 + - _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: 1 + - _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.8 + - _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: 1 + - _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: 3 + - _ZTestTransparent: 4 + - _ZWrite: 1 + m_Colors: + - _BaseColor: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _BaseColorMap_MipInfo: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _DiffusionProfileAsset: {r: 0, g: 0, b: 0, a: 0} + - _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: [] diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_AlphaClip.mat.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_AlphaClip.mat.meta new file mode 100644 index 00000000000..c319a78ee4c --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_AlphaClip.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 03a51d8fe223f844f857fc9c6b8ce758 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_0.mat b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_0.mat new file mode 100644 index 00000000000..0cfe3836897 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_0.mat @@ -0,0 +1,262 @@ +%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: Sphere_Smoothness_0 + m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3} + m_ShaderKeywords: _DISABLE_SSR_TRANSPARENT _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: 0 + - _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: 1 + - _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 + - _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: 1 + - _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: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _BaseColorMap_MipInfo: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _DiffusionProfileAsset: {r: 0, g: 0, b: 0, a: 0} + - _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 &4407933813583323387 +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/5008_PathTracing_NormalMapping/Sphere_Smoothness_0.mat.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_0.mat.meta new file mode 100644 index 00000000000..ed25625a9e6 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_0.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 095bca25cc5005c46a84523037248f61 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_1.mat b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_1.mat new file mode 100644 index 00000000000..7ea08b264b1 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_1.mat @@ -0,0 +1,262 @@ +%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: Sphere_Smoothness_1 + m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3} + m_ShaderKeywords: _DISABLE_SSR_TRANSPARENT _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: 0 + - _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: 1 + - _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: 1 + - _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: 1 + - _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: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _BaseColorMap_MipInfo: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _DiffusionProfileAsset: {r: 0, g: 0, b: 0, a: 0} + - _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 &4407933813583323387 +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/5008_PathTracing_NormalMapping/Sphere_Smoothness_1.mat.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_1.mat.meta new file mode 100644 index 00000000000..2188ef5e36f --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_1.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: faf33607ada8b3943b6808704599071d +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_25.mat b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_25.mat new file mode 100644 index 00000000000..8db5ebd5d36 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_25.mat @@ -0,0 +1,262 @@ +%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: Sphere_Smoothness_25 + m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3} + m_ShaderKeywords: _DISABLE_SSR_TRANSPARENT _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: 0 + - _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: 1 + - _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.25 + - _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: 1 + - _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: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _BaseColorMap_MipInfo: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _DiffusionProfileAsset: {r: 0, g: 0, b: 0, a: 0} + - _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 &4407933813583323387 +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/5008_PathTracing_NormalMapping/Sphere_Smoothness_25.mat.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_25.mat.meta new file mode 100644 index 00000000000..b163865bc3b --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_25.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 3c5ef18527c5c5149ae44ebab54cce79 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_75.mat b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_75.mat new file mode 100644 index 00000000000..03a6a7d9a86 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_75.mat @@ -0,0 +1,262 @@ +%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: Sphere_Smoothness_75 + m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3} + m_ShaderKeywords: _DISABLE_SSR_TRANSPARENT _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: 0 + - _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: 1 + - _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.75 + - _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: 1 + - _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: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _BaseColorMap_MipInfo: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 1} + - _DiffusionProfileAsset: {r: 0, g: 0, b: 0, a: 0} + - _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 &4407933813583323387 +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/5008_PathTracing_NormalMapping/Sphere_Smoothness_75.mat.meta b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_75.mat.meta new file mode 100644 index 00000000000..ca5dc24ff48 --- /dev/null +++ b/TestProjects/HDRP_DXR_Tests/Assets/Scenes/5008_PathTracing_NormalMapping/Sphere_Smoothness_75.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6d46aa105532cc040b4e30aaa7bd9b3c +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/com.unity.render-pipelines.high-definition/CHANGELOG.md b/com.unity.render-pipelines.high-definition/CHANGELOG.md index ed3f4116836..cb97818af68 100644 --- a/com.unity.render-pipelines.high-definition/CHANGELOG.md +++ b/com.unity.render-pipelines.high-definition/CHANGELOG.md @@ -217,6 +217,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - Increased path tracing max samples from 4K to 16K (case 1327729). - Film grain does not affect the alpha channel. - Disable TAA sharpening on alpha channel. +- Enforced more consistent shading normal computation for path tracing, so that impossible shading/geometric normal combinations are avoided (case 1323455). ## [11.0.0] - 2020-10-21 diff --git a/com.unity.render-pipelines.high-definition/Runtime/Material/Fabric/FabricPathTracing.hlsl b/com.unity.render-pipelines.high-definition/Runtime/Material/Fabric/FabricPathTracing.hlsl index 9cbe324d922..cfb7faef2a2 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/Material/Fabric/FabricPathTracing.hlsl +++ b/com.unity.render-pipelines.high-definition/Runtime/Material/Fabric/FabricPathTracing.hlsl @@ -35,6 +35,7 @@ bool CreateMaterialData(PathIntersection pathIntersection, BuiltinData builtinDa mtlData.bsdfWeight = 0.0; mtlData.V = -WorldRayDirection(); + mtlData.Nv = ComputeConsistentShadingNormal(mtlData.V, bsdfData.geomNormalWS, bsdfData.normalWS); if (!IsAbove(mtlData)) return false; @@ -42,7 +43,7 @@ bool CreateMaterialData(PathIntersection pathIntersection, BuiltinData builtinDa mtlData.bsdfWeight[0] = Luminance(mtlData.bsdfData.diffuseColor) * mtlData.bsdfData.ambientOcclusion; // If N.V < 0 (can happen with normal mapping, or smooth normals on coarsely tesselated objects) we want to avoid spec sampling - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); if (NdotV > 0.001) { // For the cotton/wool material, diffuse and sheen BRDFs share the same cosine-weighted sampling, so we only give the upper hemisphere @@ -76,7 +77,7 @@ bool CreateMaterialData(PathIntersection pathIntersection, BuiltinData builtinDa SSS::Result subsurfaceResult; float3 meanFreePath = 0.001 / (_ShapeParamsAndMaxScatterDists[mtlData.bsdfData.diffusionProfileIndex].rgb * _WorldScalesAndFilterRadiiAndThicknessRemaps[mtlData.bsdfData.diffusionProfileIndex].x); - if (!SSS::RandomWalk(shadingPosition, mtlData.bsdfData.normalWS, mtlData.bsdfData.diffuseColor, meanFreePath, pathIntersection.pixelCoord, subsurfaceResult)) + if (!SSS::RandomWalk(shadingPosition, GetDiffuseNormal(mtlData), mtlData.bsdfData.diffuseColor, meanFreePath, pathIntersection.pixelCoord, subsurfaceResult)) return false; shadingPosition = subsurfaceResult.exitPosition; @@ -215,44 +216,36 @@ void EvaluateMaterial(MaterialData mtlData, float3 sampleDir, out MaterialResult if (IsAbove(mtlData)) { - if (IsAbove(mtlData.bsdfData.normalWS, sampleDir)) // BRDFs + if (HasFlag(mtlData.bsdfData.materialFeatures, MATERIALFEATUREFLAGS_FABRIC_COTTON_WOOL)) { - if (HasFlag(mtlData.bsdfData.materialFeatures, MATERIALFEATUREFLAGS_FABRIC_COTTON_WOOL)) + if (mtlData.bsdfWeight[0] > BSDF_WEIGHT_EPSILON) { - if (mtlData.bsdfWeight[0] > BSDF_WEIGHT_EPSILON) - { - BRDF::EvaluateLambert(mtlData, sampleDir, result.diffValue, result.diffPdf); - result.diffPdf *= mtlData.bsdfWeight[0]; - } + BRDF::EvaluateLambert(mtlData, sampleDir, result.diffValue, result.diffPdf); + result.diffPdf *= mtlData.bsdfWeight[0]; + } - if (mtlData.bsdfWeight[1] > BSDF_WEIGHT_EPSILON) - { - BRDF::EvaluateSheen(mtlData, sampleDir, result.specValue, result.specPdf); - result.specPdf *= mtlData.bsdfWeight[1]; - } + if (mtlData.bsdfWeight[1] > BSDF_WEIGHT_EPSILON) + { + BRDF::EvaluateSheen(mtlData, sampleDir, result.specValue, result.specPdf); + result.specPdf *= mtlData.bsdfWeight[1]; } - else // MATERIALFEATUREFLAGS_FABRIC_SILK + } + else // MATERIALFEATUREFLAGS_FABRIC_SILK + { + if (mtlData.bsdfWeight[0] > BSDF_WEIGHT_EPSILON) { - if (mtlData.bsdfWeight[0] > BSDF_WEIGHT_EPSILON) - { - BRDF::EvaluateBurley(mtlData, sampleDir, result.diffValue, result.diffPdf); - result.diffPdf *= mtlData.bsdfWeight[0]; - } - - if (mtlData.bsdfWeight[1] > BSDF_WEIGHT_EPSILON) - { - BRDF::EvaluateAnisoGGX(mtlData, mtlData.bsdfData.fresnel0, sampleDir, result.specValue, result.specPdf); - result.specPdf *= mtlData.bsdfWeight[1]; - } + BRDF::EvaluateBurley(mtlData, sampleDir, result.diffValue, result.diffPdf); + result.diffPdf *= mtlData.bsdfWeight[0]; } - if (HasFlag(mtlData.bsdfData.materialFeatures, MATERIALFEATUREFLAGS_FABRIC_SUBSURFACE_SCATTERING)) + if (mtlData.bsdfWeight[1] > BSDF_WEIGHT_EPSILON) { - // We compensate for the fact that there is no spec when computing SSS - result.specValue /= mtlData.subsurfaceWeightFactor; + BRDF::EvaluateAnisoGGX(mtlData, mtlData.bsdfData.fresnel0, sampleDir, result.specValue, result.specPdf); + result.specPdf *= mtlData.bsdfWeight[1]; } } - else if (mtlData.bsdfWeight[2] > BSDF_WEIGHT_EPSILON) // Diffuse BTDF + + if (IsBelow(GetDiffuseNormal(mtlData), sampleDir) && mtlData.bsdfWeight[2] > BSDF_WEIGHT_EPSILON) { BTDF::EvaluateLambert(mtlData, sampleDir, result.diffValue, result.diffPdf); result.diffValue *= mtlData.bsdfData.transmittance; @@ -264,6 +257,12 @@ void EvaluateMaterial(MaterialData mtlData, float3 sampleDir, out MaterialResult result.diffValue /= mtlData.subsurfaceWeightFactor; } } + + if (HasFlag(mtlData.bsdfData.materialFeatures, MATERIALFEATUREFLAGS_FABRIC_SUBSURFACE_SCATTERING)) + { + // We compensate for the fact that there is no spec when computing SSS + result.specValue /= mtlData.subsurfaceWeightFactor; + } } } diff --git a/com.unity.render-pipelines.high-definition/Runtime/Material/Lit/LitPathTracing.hlsl b/com.unity.render-pipelines.high-definition/Runtime/Material/Lit/LitPathTracing.hlsl index c17e0d4ca67..28ecddcee0e 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/Material/Lit/LitPathTracing.hlsl +++ b/com.unity.render-pipelines.high-definition/Runtime/Material/Lit/LitPathTracing.hlsl @@ -9,13 +9,13 @@ // bsdfWeight2 Spec GGX BRDF // bsdfWeight3 Spec GGX BTDF -void ProcessBSDFData(PathIntersection pathIntersection, BuiltinData builtinData, inout BSDFData bsdfData) +void ProcessBSDFData(PathIntersection pathIntersection, BuiltinData builtinData, MaterialData mtlData, inout BSDFData bsdfData) { // Adjust roughness to reduce fireflies bsdfData.roughnessT = max(pathIntersection.maxRoughness, bsdfData.roughnessT); bsdfData.roughnessB = max(pathIntersection.maxRoughness, bsdfData.roughnessB); - float NdotV = abs(dot(bsdfData.normalWS, WorldRayDirection())); + float NdotV = abs(dot(GetSpecularNormal(mtlData), mtlData.V)); // Modify fresnel0 value to take iridescence into account (code adapted from Lit.hlsl to produce identical results) if (bsdfData.iridescenceMask > 0.0) @@ -46,41 +46,38 @@ void ProcessBSDFData(PathIntersection pathIntersection, BuiltinData builtinData, bool CreateMaterialData(PathIntersection pathIntersection, BuiltinData builtinData, BSDFData bsdfData, inout float3 shadingPosition, inout float theSample, out MaterialData mtlData) { // Alter values in the material's bsdfData struct, to better suit path tracing + mtlData.V = -WorldRayDirection(); + mtlData.Nv = ComputeConsistentShadingNormal(mtlData.V, bsdfData.geomNormalWS, bsdfData.normalWS); mtlData.bsdfData = bsdfData; - ProcessBSDFData(pathIntersection, builtinData, mtlData.bsdfData); + ProcessBSDFData(pathIntersection, builtinData, mtlData, mtlData.bsdfData); mtlData.bsdfWeight = 0.0; mtlData.ior = mtlData.bsdfData.ior; - mtlData.V = -WorldRayDirection(); // Assume no coating by default float coatingTransmission = 1.0; // First determine if our incoming direction V is above (exterior) or below (interior) the surface - if (IsAbove(mtlData.bsdfData.geomNormalWS, mtlData.V)) + if (IsAbove(mtlData)) { - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); float Fcoat = F_Schlick(CLEAR_COAT_F0, NdotV) * mtlData.bsdfData.coatMask; float Fspec = Luminance(F_Schlick(mtlData.bsdfData.fresnel0, NdotV)); - // If N.V < 0 (can happen with normal mapping, or smooth normals on coarsely tesselated objects) we want to avoid spec sampling - bool consistentNormal = (NdotV > 0.001); - mtlData.bsdfWeight[1] = consistentNormal ? Fcoat : 0.0; + mtlData.bsdfWeight[1] = Fcoat; coatingTransmission = 1.0 - mtlData.bsdfWeight[1]; - mtlData.bsdfWeight[2] = consistentNormal ? coatingTransmission * lerp(Fspec, 0.5, 0.5 * (mtlData.bsdfData.roughnessT + mtlData.bsdfData.roughnessB)) * (1.0 + Fspec * mtlData.bsdfData.specularOcclusion) : 0.0; - mtlData.bsdfWeight[3] = consistentNormal ? (coatingTransmission - mtlData.bsdfWeight[2]) * mtlData.bsdfData.transmittanceMask : 0.0; + mtlData.bsdfWeight[2] = coatingTransmission * lerp(Fspec, 0.5, 0.5 * (mtlData.bsdfData.roughnessT + mtlData.bsdfData.roughnessB)) * (1.0 + Fspec * mtlData.bsdfData.specularOcclusion); + mtlData.bsdfWeight[3] = (coatingTransmission - mtlData.bsdfWeight[2]) * mtlData.bsdfData.transmittanceMask; mtlData.bsdfWeight[0] = coatingTransmission * (1.0 - mtlData.bsdfData.transmittanceMask) * Luminance(mtlData.bsdfData.diffuseColor) * mtlData.bsdfData.ambientOcclusion; } #ifdef _SURFACE_TYPE_TRANSPARENT else // Below { - float NdotV = -dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = -dot(GetSpecularNormal(mtlData), mtlData.V); float F = F_FresnelDielectric(1.0 / mtlData.ior, NdotV); - // If N.V < 0 (can happen with normal mapping) we want to avoid spec sampling - bool consistentNormal = (NdotV > 0.001); - mtlData.bsdfWeight[2] = consistentNormal ? F : 0.0; - mtlData.bsdfWeight[3] = consistentNormal ? (1.0 - mtlData.bsdfWeight[1]) * mtlData.bsdfData.transmittanceMask : 0.0; + mtlData.bsdfWeight[2] = F; + mtlData.bsdfWeight[3] = (1.0 - mtlData.bsdfWeight[1]) * mtlData.bsdfData.transmittanceMask; } #endif @@ -105,7 +102,7 @@ bool CreateMaterialData(PathIntersection pathIntersection, BuiltinData builtinDa SSS::Result subsurfaceResult; float3 meanFreePath = 0.001 / (_ShapeParamsAndMaxScatterDists[mtlData.bsdfData.diffusionProfileIndex].rgb * _WorldScalesAndFilterRadiiAndThicknessRemaps[mtlData.bsdfData.diffusionProfileIndex].x); - if (!SSS::RandomWalk(shadingPosition, mtlData.bsdfData.normalWS, mtlData.bsdfData.diffuseColor, meanFreePath, pathIntersection.pixelCoord, subsurfaceResult)) + if (!SSS::RandomWalk(shadingPosition, GetDiffuseNormal(mtlData), mtlData.bsdfData.diffuseColor, meanFreePath, pathIntersection.pixelCoord, subsurfaceResult)) return false; shadingPosition = subsurfaceResult.exitPosition; @@ -236,7 +233,7 @@ bool SampleMaterial(MaterialData mtlData, float3 inputSample, out float3 sampleD return false; #ifdef _REFRACTION_THIN - sampleDir = refract(sampleDir, mtlData.bsdfData.normalWS, mtlData.ior); + sampleDir = refract(sampleDir, GetSpecularNormal(mtlData), mtlData.ior); if (!any(sampleDir)) return false; #endif diff --git a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingBSDF.hlsl b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingBSDF.hlsl index 5211edaf607..a4edf8befa9 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingBSDF.hlsl +++ b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingBSDF.hlsl @@ -44,7 +44,7 @@ bool SampleGGX(MaterialData mtlData, roughness = clamp(roughness, MIN_GGX_ROUGHNESS, MAX_GGX_ROUGHNESS); float NdotL, NdotH, VdotH; - float3x3 localToWorld = GetLocalFrame(mtlData.bsdfData.normalWS); + float3x3 localToWorld = GetLocalFrame(GetSpecularNormal(mtlData)); SampleGGXDir(inputSample.xy, mtlData.V, localToWorld, roughness, outgoingDir, NdotL, NdotH, VdotH); if (NdotL < 0.001 || !IsAbove(mtlData, outgoingDir)) @@ -56,7 +56,7 @@ bool SampleGGX(MaterialData mtlData, if (pdf < 0.001) return false; - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); float Vg = V_SmithJointGGX(NdotL, NdotV, roughness); fresnel = F_Schlick(fresnel0, VdotH); @@ -85,19 +85,19 @@ void EvaluateGGX(MaterialData mtlData, out float pdf, out float3 fresnel) { - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); if (NdotV < 0.001) { value = 0.0; pdf = 0.0; return; } - float NdotL = dot(mtlData.bsdfData.normalWS, outgoingDir); + float NdotL = dot(GetSpecularNormal(mtlData), outgoingDir); roughness = clamp(roughness, MIN_GGX_ROUGHNESS, MAX_GGX_ROUGHNESS); float3 H = normalize(mtlData.V + outgoingDir); - float NdotH = dot(mtlData.bsdfData.normalWS, H); + float NdotH = dot(GetSpecularNormal(mtlData), H); float VdotH = dot(mtlData.V, H); float D = D_GGX(NdotH, roughness); pdf = D * NdotH / (4.0 * VdotH); @@ -132,7 +132,7 @@ bool SampleAnisoGGX(MaterialData mtlData, float VdotH; float3 localV, localH; - float3x3 localToWorld = GetTangentFrame(mtlData); + float3x3 localToWorld = GetSpecularTangentFrame(mtlData); SampleAnisoGGXVisibleNormal(inputSample.xy, mtlData.V, localToWorld, roughnessX, roughnessY, localV, localH, VdotH); // Compute the reflection direction @@ -174,7 +174,7 @@ void EvaluateAnisoGGX(MaterialData mtlData, out float pdf, out float3 fresnel) { - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); if (NdotV < 0.001) { value = 0.0; @@ -185,7 +185,7 @@ void EvaluateAnisoGGX(MaterialData mtlData, float roughnessX = clamp(mtlData.bsdfData.roughnessT, MIN_GGX_ROUGHNESS, MAX_GGX_ROUGHNESS); float roughnessY = clamp(mtlData.bsdfData.roughnessB, MIN_GGX_ROUGHNESS, MAX_GGX_ROUGHNESS); - float3x3 worldToLocal = transpose(GetTangentFrame(mtlData)); + float3x3 worldToLocal = transpose(GetSpecularTangentFrame(mtlData)); float3 localV = mul(mtlData.V, worldToLocal); float3 localL = mul(outgoingDir, worldToLocal); float3 localH = normalize(localV + localL); @@ -217,14 +217,14 @@ bool SampleDelta(MaterialData mtlData, { if (IsAbove(mtlData)) { - outgoingDir = reflect(-mtlData.V, mtlData.bsdfData.normalWS); - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + outgoingDir = reflect(-mtlData.V, GetSpecularNormal(mtlData)); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); value = F_Schlick(mtlData.bsdfData.fresnel0, NdotV); } else // Below { - outgoingDir = -reflect(mtlData.V, mtlData.bsdfData.normalWS); - float NdotV = -dot(mtlData.bsdfData.normalWS, mtlData.V); + outgoingDir = -reflect(mtlData.V, GetSpecularNormal(mtlData)); + float NdotV = -dot(GetSpecularNormal(mtlData), mtlData.V); value = F_FresnelDielectric(1.0 / mtlData.ior, NdotV); } @@ -240,12 +240,12 @@ bool SampleLambert(MaterialData mtlData, out float3 value, out float pdf) { - outgoingDir = SampleHemisphereCosine(inputSample.x, inputSample.y, mtlData.bsdfData.normalWS); + outgoingDir = SampleHemisphereCosine(inputSample.x, inputSample.y, GetDiffuseNormal(mtlData)); if (!IsAbove(mtlData, outgoingDir)) return false; - pdf = dot(mtlData.bsdfData.normalWS, outgoingDir) * INV_PI; + pdf = dot(GetDiffuseNormal(mtlData), outgoingDir) * INV_PI; if (pdf < 0.001) return false; @@ -260,7 +260,7 @@ void EvaluateLambert(MaterialData mtlData, out float3 value, out float pdf) { - pdf = dot(mtlData.bsdfData.normalWS, outgoingDir) * INV_PI; + pdf = saturate(dot(GetDiffuseNormal(mtlData), outgoingDir)) * INV_PI; value = mtlData.bsdfData.diffuseColor * pdf; } @@ -270,18 +270,18 @@ bool SampleBurley(MaterialData mtlData, out float3 value, out float pdf) { - outgoingDir = SampleHemisphereCosine(inputSample.x, inputSample.y, mtlData.bsdfData.normalWS); + outgoingDir = SampleHemisphereCosine(inputSample.x, inputSample.y, GetDiffuseNormal(mtlData)); if (!IsAbove(mtlData, outgoingDir)) return false; - float NdotL = dot(mtlData.bsdfData.normalWS, outgoingDir); + float NdotL = dot(GetDiffuseNormal(mtlData), outgoingDir); pdf = NdotL * INV_PI; if (pdf < 0.001) return false; - float NdotV = saturate(dot(mtlData.bsdfData.normalWS, mtlData.V)); + float NdotV = saturate(dot(GetDiffuseNormal(mtlData), mtlData.V)); float LdotV = saturate(dot(outgoingDir, mtlData.V)); value = mtlData.bsdfData.diffuseColor * DisneyDiffuseNoPI(NdotV, NdotL, LdotV, mtlData.bsdfData.perceptualRoughness) * pdf; @@ -293,8 +293,8 @@ void EvaluateBurley(MaterialData mtlData, out float3 value, out float pdf) { - float NdotL = dot(mtlData.bsdfData.normalWS, outgoingDir); - float NdotV = saturate(dot(mtlData.bsdfData.normalWS, mtlData.V)); + float NdotL = saturate(dot(GetDiffuseNormal(mtlData), outgoingDir)); + float NdotV = saturate(dot(GetDiffuseNormal(mtlData), mtlData.V)); float LdotV = saturate(dot(outgoingDir, mtlData.V)); pdf = NdotL * INV_PI; @@ -332,10 +332,10 @@ void EvaluateSheen(MaterialData mtlData, out float pdf) { // We use cosine-weighted sampling for this lobe - float NdotL = dot(mtlData.bsdfData.normalWS, outgoingDir); + float NdotL = saturate(dot(GetSpecularNormal(mtlData), outgoingDir)); pdf = NdotL * INV_PI; - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); if (NdotV < 0.001) { value = 0.0; @@ -345,7 +345,7 @@ void EvaluateSheen(MaterialData mtlData, float roughness = clamp(mtlData.bsdfData.roughnessT, MIN_GGX_ROUGHNESS, MAX_GGX_ROUGHNESS); float3 H = normalize(mtlData.V + outgoingDir); - float NdotH = dot(mtlData.bsdfData.normalWS, H); + float NdotH = dot(GetSpecularNormal(mtlData), H); float D = D_Charlie(NdotH, roughness); @@ -370,18 +370,18 @@ bool SampleGGX(MaterialData mtlData, float roughness = clamp(mtlData.bsdfData.roughnessT, MIN_GGX_ROUGHNESS, MAX_GGX_ROUGHNESS); float NdotL, NdotH, VdotH; - float3x3 localToWorld = GetLocalFrame(mtlData.bsdfData.normalWS); + float3x3 localToWorld = GetLocalFrame(GetSpecularNormal(mtlData)); SampleGGXDir(inputSample.xy, mtlData.V, localToWorld, roughness, outgoingDir, NdotL, NdotH, VdotH); // FIXME: won't be necessary after new version of SampleGGXDir() float3 H = normalize(mtlData.V + outgoingDir); outgoingDir = refract(-mtlData.V, H, 1.0 / mtlData.ior); - NdotL = dot(mtlData.bsdfData.normalWS, outgoingDir); + NdotL = dot(GetSpecularNormal(mtlData), outgoingDir); if (NdotL > -0.001 || !IsBelow(mtlData, outgoingDir)) return false; - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); float LdotH = dot(outgoingDir, H); float3 F = F_Schlick(mtlData.bsdfData.fresnel0, VdotH); @@ -409,7 +409,7 @@ bool SampleAnisoGGX(MaterialData mtlData, float VdotH; float3 localV, localH; - float3x3 localToWorld = GetTangentFrame(mtlData); + float3x3 localToWorld = GetSpecularTangentFrame(mtlData); SampleAnisoGGXVisibleNormal(inputSample.xy, mtlData.V, localToWorld, roughnessX, roughnessY, localV, localH, VdotH); // Compute refraction direction instead of reflection @@ -444,14 +444,14 @@ bool SampleDelta(MaterialData mtlData, { if (IsAbove(mtlData)) { - outgoingDir = refract(-mtlData.V, mtlData.bsdfData.normalWS, 1.0 / mtlData.ior); - float NdotV = dot(mtlData.bsdfData.normalWS, mtlData.V); + outgoingDir = refract(-mtlData.V, GetSpecularNormal(mtlData), 1.0 / mtlData.ior); + float NdotV = dot(GetSpecularNormal(mtlData), mtlData.V); value = 1.0 - F_Schlick(mtlData.bsdfData.fresnel0, NdotV); } else // Below { - outgoingDir = -refract(mtlData.V, mtlData.bsdfData.normalWS, mtlData.ior); - float NdotV = -dot(mtlData.bsdfData.normalWS, mtlData.V); + outgoingDir = -refract(mtlData.V, GetSpecularNormal(mtlData), mtlData.ior); + float NdotV = -dot(GetSpecularNormal(mtlData), mtlData.V); value = 1.0 - F_FresnelDielectric(1.0 / mtlData.ior, NdotV); } diff --git a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingLight.hlsl b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingLight.hlsl index 069be1b5ce3..2ee3943545d 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingLight.hlsl +++ b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingLight.hlsl @@ -300,6 +300,7 @@ bool SampleLights(LightList lightList, float3 inputSample, float3 position, float3 normal, + bool isVolume, out float3 outgoingDir, out float3 value, out float pdf, @@ -308,8 +309,8 @@ bool SampleLights(LightList lightList, if (!GetLightCount(lightList)) return false; - // Are we lighting a volume or a surface? - bool isVolume = !any(normal); + // Are we lighting a spherical (e.g. volume) or a hemi-spherical distribution (e.g. opaque surface)? + bool isSpherical = isVolume || !any(normal); if (PickLocalLights(lightList, inputSample.z)) { @@ -330,7 +331,7 @@ bool SampleLights(LightList lightList, dist = sqrt(sqDist); outgoingDir /= dist; - if (!isVolume && dot(normal, outgoingDir) < 0.001) + if (!isSpherical && dot(normal, outgoingDir) < 0.001) return false; float cosTheta = -dot(outgoingDir, lightData.forward); @@ -364,7 +365,7 @@ bool SampleLights(LightList lightList, pdf = DELTA_PDF; } - if (!isVolume && dot(normal, outgoingDir) < 0.001) + if (!isSpherical && dot(normal, outgoingDir) < 0.001) return false; value = GetPunctualEmission(lightData, outgoingDir, dist) * pdf; @@ -400,7 +401,7 @@ bool SampleLights(LightList lightList, outgoingDir = -lightData.forward; } - if (!isVolume && (dot(normal, outgoingDir) < 0.001)) + if (!isSpherical && (dot(normal, outgoingDir) < 0.001)) return false; dist = FLT_INF; diff --git a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingMaterial.hlsl b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingMaterial.hlsl index 411cf1f1cf7..040cb2dc29e 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingMaterial.hlsl +++ b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingMaterial.hlsl @@ -16,8 +16,10 @@ struct MaterialData // Index of refraction (if relevant) float ior; - // View vector + // View vector, and altered shading normal + // (to be consistent with the view vector and geometric normal) float3 V; + float3 Nv; }; struct MaterialResult @@ -78,11 +80,50 @@ bool IsBelow(MaterialData mtlData) return !IsAbove(mtlData); } -float3x3 GetTangentFrame(MaterialData mtlData) +float3 GetDiffuseNormal(MaterialData mtlData) { + return mtlData.bsdfData.normalWS; +} + +float3 GetSpecularNormal(MaterialData mtlData) +{ + return mtlData.Nv; +} + +float3 GetLightNormal(MaterialData mtlData) +{ + // If both diffuse and specular normals are quasi-indentical, return one of them, otherwise return a null vector + return dot(GetDiffuseNormal(mtlData), GetSpecularNormal(mtlData)) > 0.99 ? GetDiffuseNormal(mtlData) : float3(0.0, 0.0, 0.0); +} + +float3x3 GetSpecularTangentFrame(MaterialData mtlData) +{ + // If we have anisotropy, we want our local frame to follow tangential directions, otherwise any orientation will do return mtlData.bsdfData.anisotropy != 0.0 ? - float3x3(mtlData.bsdfData.tangentWS, mtlData.bsdfData.bitangentWS, mtlData.bsdfData.normalWS) : - GetLocalFrame(mtlData.bsdfData.normalWS); + float3x3(mtlData.bsdfData.tangentWS, mtlData.bsdfData.bitangentWS, GetSpecularNormal(mtlData)) : + GetLocalFrame(GetSpecularNormal(mtlData)); +} + +float3 ComputeConsistentShadingNormal(float3 Wi, float3 G, float3 N) +{ + // Check in which hemisphere does the incoming view vector fall + float GdotWi = dot(G, Wi); + float Hi = sign(GdotWi); + + // First project N back towards Wi if it's on the other side of the view plane + float NdotWi = Hi * dot(N, Wi); + float3 Ni = N - Hi * min(0.0, NdotWi) * Wi; + + // Then check in which hemisphere does the reflected vector fall + float3 Wo = reflect(-Wi, Ni); + float GdotWo = dot(G, Wo); + float Ho = sign(GdotWo); + + // Bring reflection direction back to the right hemisphere (slightly offset from the horizon, for more robustness) + Wo = normalize(Wo - (GdotWo + Ho * 0.001) * G); + + // Compute a new, consistent shading normal accordingly + return Hi != Ho ? Hi * normalize(Wi + Wo) : N; } #endif // UNITY_PATH_TRACING_MATERIAL_INCLUDED diff --git a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingVolume.hlsl b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingVolume.hlsl index ae8ee443015..cba0bea2484 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingVolume.hlsl +++ b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/PathTracing/Shaders/PathTracingVolume.hlsl @@ -130,7 +130,7 @@ void ComputeVolumeScattering(inout PathIntersection pathIntersection : SV_RayPay // Light sampling if (computeDirect) { - if (SampleLights(lightList, inputSample, scatteringPosition, 0.0, ray.Direction, value, pdf, ray.TMax)) + if (SampleLights(lightList, inputSample, scatteringPosition, 0.0, true, ray.Direction, value, pdf, ray.TMax)) { // FIXME: Apply phase function and divide by pdf (only isotropic for now, and not sure about sigmaS value) value *= _HeightFogBaseScattering.xyz * ComputeHeightFogMultiplier(scatteringPosition.y) * INV_FOUR_PI / pdf; diff --git a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/ShaderPass/ShaderPassPathTracing.hlsl b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/ShaderPass/ShaderPassPathTracing.hlsl index b5a3d356cc6..6313f0deac3 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/ShaderPass/ShaderPassPathTracing.hlsl +++ b/com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/ShaderPass/ShaderPassPathTracing.hlsl @@ -101,7 +101,7 @@ void ComputeSurfaceScattering(inout PathIntersection pathIntersection : SV_RayPa #ifdef _SURFACE_TYPE_TRANSPARENT float3 lightNormal = 0.0; #else - float3 lightNormal = mtlData.bsdfData.normalWS; + float3 lightNormal = GetLightNormal(mtlData); #endif LightList lightList = CreateLightList(shadingPosition, lightNormal, builtinData.renderingLayers); @@ -119,7 +119,7 @@ void ComputeSurfaceScattering(inout PathIntersection pathIntersection : SV_RayPa // Light sampling if (computeDirect) { - if (SampleLights(lightList, inputSample.xyz, rayDescriptor.Origin, mtlData.bsdfData.normalWS, rayDescriptor.Direction, value, pdf, rayDescriptor.TMax)) + if (SampleLights(lightList, inputSample.xyz, rayDescriptor.Origin, lightNormal, false, rayDescriptor.Direction, value, pdf, rayDescriptor.TMax)) { EvaluateMaterial(mtlData, rayDescriptor.Direction, mtlResult);