UnityGame/Library/PackageCache/com.unity.shadergraph/Samples~/FeatureExamples/Custom Lighting/Simple/CustomLightingSimpleAdditionalLights.shadersubgraph

1429 lines
35 KiB
Plaintext
Raw Normal View History

2024-10-27 10:53:47 +03:00
{
"m_SGVersion": 3,
"m_Type": "UnityEditor.ShaderGraph.GraphData",
"m_ObjectId": "7c7636bc32664a6197cd3b7cb29346c3",
"m_Properties": [
{
"m_Id": "78c214dac5a14d8896c5b8dd98df66f2"
},
{
"m_Id": "7f71738800414ec99ae519c6ab2926ec"
},
{
"m_Id": "3c49dbf5eca648f799f5b531726c7ec8"
},
{
"m_Id": "70cbf5ac6da04bf6bd87eb71ccb7c48d"
},
{
"m_Id": "d0e0327aec764cb988d606fa01e1f17a"
}
],
"m_Keywords": [],
"m_Dropdowns": [],
"m_CategoryData": [
{
"m_Id": "aaacb492a6734ff6b589e422c6adfa3e"
}
],
"m_Nodes": [
{
"m_Id": "f60afd3e2b9848c6a7c34ee429cc7a64"
},
{
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
{
"m_Id": "b9f05025da4f4857a7b1b6f56259a629"
},
{
"m_Id": "25880f0697234954b8dc6ef11af3752d"
},
{
"m_Id": "ac790fc8215b4b3d8851855d2153960d"
},
{
"m_Id": "7c168e0b18c646368f6d37ae73c66db0"
},
{
"m_Id": "5a83d87c9a104574887fde7a50f41ce8"
},
{
"m_Id": "3e48999a139848e6ab2e955c61810b83"
},
{
"m_Id": "080df9ced18d4c2997c8fd68e2794fcf"
},
{
"m_Id": "d869e3d8654b48a491de945ad8af6301"
},
{
"m_Id": "1e29ad89226c4d84a936fe7530839aef"
}
],
"m_GroupDatas": [],
"m_StickyNoteDatas": [],
"m_Edges": [
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "080df9ced18d4c2997c8fd68e2794fcf"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "d869e3d8654b48a491de945ad8af6301"
},
"m_SlotId": 2
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "1e29ad89226c4d84a936fe7530839aef"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 5
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "25880f0697234954b8dc6ef11af3752d"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 4
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "3e48999a139848e6ab2e955c61810b83"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "d869e3d8654b48a491de945ad8af6301"
},
"m_SlotId": 0
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "3e48999a139848e6ab2e955c61810b83"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "d869e3d8654b48a491de945ad8af6301"
},
"m_SlotId": 1
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "5a83d87c9a104574887fde7a50f41ce8"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 3
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "7c168e0b18c646368f6d37ae73c66db0"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 1
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "ac790fc8215b4b3d8851855d2153960d"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 6
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 7
},
"m_InputSlot": {
"m_Node": {
"m_Id": "f60afd3e2b9848c6a7c34ee429cc7a64"
},
"m_SlotId": 1
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 8
},
"m_InputSlot": {
"m_Node": {
"m_Id": "f60afd3e2b9848c6a7c34ee429cc7a64"
},
"m_SlotId": 2
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 9
},
"m_InputSlot": {
"m_Node": {
"m_Id": "f60afd3e2b9848c6a7c34ee429cc7a64"
},
"m_SlotId": 3
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "b9f05025da4f4857a7b1b6f56259a629"
},
"m_SlotId": 0
},
"m_InputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 0
}
},
{
"m_OutputSlot": {
"m_Node": {
"m_Id": "d869e3d8654b48a491de945ad8af6301"
},
"m_SlotId": 3
},
"m_InputSlot": {
"m_Node": {
"m_Id": "af7e463337fa464994ef4fefeb1ef2b0"
},
"m_SlotId": 2
}
}
],
"m_VertexContext": {
"m_Position": {
"x": 0.0,
"y": 0.0
},
"m_Blocks": []
},
"m_FragmentContext": {
"m_Position": {
"x": 0.0,
"y": 0.0
},
"m_Blocks": []
},
"m_PreviewData": {
"serializedMesh": {
"m_SerializedMesh": "{\"mesh\":{\"instanceID\":0}}",
"m_Guid": ""
},
"preventRotation": false
},
"m_Path": "Sub Graphs",
"m_GraphPrecision": 1,
"m_PreviewMode": 2,
"m_OutputNode": {
"m_Id": "f60afd3e2b9848c6a7c34ee429cc7a64"
},
"m_SubDatas": [],
"m_ActiveTargets": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "01f7cc366d65489099cc74e89af039ae",
"m_Id": 2,
"m_DisplayName": "Specular",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "Specular",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "034e7f2441f645919d0e6b0f1edf5fd0",
"m_Id": 5,
"m_DisplayName": "MainSpecular",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "MainSpecular",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.NormalVectorNode",
"m_ObjectId": "080df9ced18d4c2997c8fd68e2794fcf",
"m_Group": {
"m_Id": ""
},
"m_Name": "Normal Vector",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -846.0,
"y": 106.00000762939453,
"width": 206.00006103515626,
"height": 130.5
}
},
"m_Slots": [
{
"m_Id": "e8febe5f94b549beab8c0cd882d617df"
}
],
"synonyms": [
"surface direction"
],
"m_Precision": 0,
"m_PreviewExpanded": false,
"m_DismissedVersion": 0,
"m_PreviewMode": 2,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Space": 2
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "13f2abca39da4a50a052891ab4c6b0a6",
"m_Id": 6,
"m_DisplayName": "MainColor",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "MainColor",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.PropertyNode",
"m_ObjectId": "1e29ad89226c4d84a936fe7530839aef",
"m_Group": {
"m_Id": ""
},
"m_Name": "Property",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -585.0000610351563,
"y": 354.7500305175781,
"width": 171.75,
"height": 33.0
}
},
"m_Slots": [
{
"m_Id": "c9c180a1b34442a48565753a99b40087"
}
],
"synonyms": [],
"m_Precision": 0,
"m_PreviewExpanded": true,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Property": {
"m_Id": "d0e0327aec764cb988d606fa01e1f17a"
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.PropertyNode",
"m_ObjectId": "25880f0697234954b8dc6ef11af3752d",
"m_Group": {
"m_Id": ""
},
"m_Name": "Property",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -573.9999389648438,
"y": 320.0000305175781,
"width": 163.49996948242188,
"height": 33.999969482421878
}
},
"m_Slots": [
{
"m_Id": "9d68cf4498f04363b2c3a2379355bf2d"
}
],
"synonyms": [],
"m_Precision": 0,
"m_PreviewExpanded": true,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Property": {
"m_Id": "78c214dac5a14d8896c5b8dd98df66f2"
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot",
"m_ObjectId": "2b53e0ba123249889a9a7f8c8a0b6d1f",
"m_Id": 1,
"m_DisplayName": "Diffuse",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "Diffuse",
"m_StageCapability": 3,
"m_Value": 0.0,
"m_DefaultValue": 0.0,
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "2c54247b66954edd8e2688422b8f35d1",
"m_Id": 8,
"m_DisplayName": "Specular",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Specular",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 1,
"m_Type": "UnityEditor.ShaderGraph.Internal.Vector1ShaderProperty",
"m_ObjectId": "3c49dbf5eca648f799f5b531726c7ec8",
"m_Guid": {
"m_GuidSerialized": "e2c68582-3932-4ce2-b115-d02070a25b36"
},
"m_Name": "Smoothness",
"m_DefaultRefNameVersion": 1,
"m_RefNameGeneratedByDisplayName": "Smoothness",
"m_DefaultReferenceName": "_Smoothness",
"m_OverrideReferenceName": "",
"m_GeneratePropertyBlock": true,
"m_UseCustomSlotLabel": false,
"m_CustomSlotLabel": "",
"m_DismissedVersion": 0,
"m_Precision": 0,
"overrideHLSLDeclaration": false,
"hlslDeclarationOverride": 0,
"m_Hidden": false,
"m_Value": 0.0,
"m_FloatType": 0,
"m_RangeValues": {
"x": 0.0,
"y": 1.0
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.PropertyNode",
"m_ObjectId": "3e48999a139848e6ab2e955c61810b83",
"m_Group": {
"m_Id": ""
},
"m_Name": "Property",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -772.0,
"y": 73.00001525878906,
"width": 132.00006103515626,
"height": 33.999961853027347
}
},
"m_Slots": [
{
"m_Id": "f5454ef35e00400baaa0360e57daf01b"
}
],
"synonyms": [],
"m_Precision": 0,
"m_PreviewExpanded": true,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Property": {
"m_Id": "70cbf5ac6da04bf6bd87eb71ccb7c48d"
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "3f98bc4713a5463fb7db2f5261a4ecf0",
"m_Id": 0,
"m_DisplayName": "MainLightColor",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot",
"m_ObjectId": "59d077b7272f47a8a9070b2b13e64523",
"m_Id": 2,
"m_DisplayName": "NotConnected",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "NotConnected",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.ViewVectorNode",
"m_ObjectId": "5a83d87c9a104574887fde7a50f41ce8",
"m_Group": {
"m_Id": ""
},
"m_Name": "View Vector",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -616.4999389648438,
"y": 189.5,
"width": 205.99996948242188,
"height": 130.50003051757813
}
},
"m_Slots": [
{
"m_Id": "85a1e5fda4b54e408c63d5ff22cc91ec"
},
{
"m_Id": "a6c1581aab424348a7ca315cbc7f0b43"
}
],
"synonyms": [
"eye vector"
],
"m_Precision": 0,
"m_PreviewExpanded": false,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Space": 2
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot",
"m_ObjectId": "6525a66bc0e749559a7c2aaa659a1a1c",
"m_Id": 4,
"m_DisplayName": "MainDiffuse",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "MainDiffuse",
"m_StageCapability": 3,
"m_Value": 0.0,
"m_DefaultValue": 0.0,
"m_Labels": []
}
{
"m_SGVersion": 1,
"m_Type": "UnityEditor.ShaderGraph.Internal.Vector3ShaderProperty",
"m_ObjectId": "70cbf5ac6da04bf6bd87eb71ccb7c48d",
"m_Guid": {
"m_GuidSerialized": "5a8fd716-0518-4b75-9fac-97607ed249cf"
},
"m_Name": "NormalWS",
"m_DefaultRefNameVersion": 1,
"m_RefNameGeneratedByDisplayName": "NormalWS",
"m_DefaultReferenceName": "_NormalWS",
"m_OverrideReferenceName": "",
"m_GeneratePropertyBlock": true,
"m_UseCustomSlotLabel": true,
"m_CustomSlotLabel": "WorldNormalVector",
"m_DismissedVersion": 0,
"m_Precision": 0,
"overrideHLSLDeclaration": false,
"hlslDeclarationOverride": 0,
"m_Hidden": false,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
}
}
{
"m_SGVersion": 1,
"m_Type": "UnityEditor.ShaderGraph.Internal.Vector1ShaderProperty",
"m_ObjectId": "78c214dac5a14d8896c5b8dd98df66f2",
"m_Guid": {
"m_GuidSerialized": "09ce332d-c752-414b-a652-75b1e796def3"
},
"m_Name": "MainLightDiffuse",
"m_DefaultRefNameVersion": 1,
"m_RefNameGeneratedByDisplayName": "MainLightDiffuse",
"m_DefaultReferenceName": "_MainLightDiffuse",
"m_OverrideReferenceName": "",
"m_GeneratePropertyBlock": true,
"m_UseCustomSlotLabel": false,
"m_CustomSlotLabel": "",
"m_DismissedVersion": 0,
"m_Precision": 0,
"overrideHLSLDeclaration": false,
"hlslDeclarationOverride": 0,
"m_Hidden": false,
"m_Value": 0.0,
"m_FloatType": 0,
"m_RangeValues": {
"x": 0.0,
"y": 1.0
}
}
{
"m_SGVersion": 1,
"m_Type": "UnityEditor.ShaderGraph.PositionNode",
"m_ObjectId": "7c168e0b18c646368f6d37ae73c66db0",
"m_Group": {
"m_Id": ""
},
"m_Name": "Position",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -616.4999389648438,
"y": -94.50003051757813,
"width": 205.99996948242188,
"height": 130.5000457763672
}
},
"m_Slots": [
{
"m_Id": "e44ae5bbf0ad43d89107afdbce38e4fc"
}
],
"synonyms": [
"location"
],
"m_Precision": 0,
"m_PreviewExpanded": false,
"m_DismissedVersion": 0,
"m_PreviewMode": 2,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Space": 2,
"m_PositionSource": 0
}
{
"m_SGVersion": 1,
"m_Type": "UnityEditor.ShaderGraph.Internal.Vector3ShaderProperty",
"m_ObjectId": "7f71738800414ec99ae519c6ab2926ec",
"m_Guid": {
"m_GuidSerialized": "7cb49a27-0767-4479-83ca-a8c03c548a6c"
},
"m_Name": "MainLightColor",
"m_DefaultRefNameVersion": 1,
"m_RefNameGeneratedByDisplayName": "MainLightColor",
"m_DefaultReferenceName": "_MainLightColor",
"m_OverrideReferenceName": "",
"m_GeneratePropertyBlock": true,
"m_UseCustomSlotLabel": false,
"m_CustomSlotLabel": "",
"m_DismissedVersion": 0,
"m_Precision": 0,
"overrideHLSLDeclaration": false,
"hlslDeclarationOverride": 0,
"m_Hidden": false,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.PositionMaterialSlot",
"m_ObjectId": "85a1e5fda4b54e408c63d5ff22cc91ec",
"m_Id": 3,
"m_DisplayName": "World Space Position",
"m_SlotType": 0,
"m_Hidden": true,
"m_ShaderOutputName": "WorldSpacePosition",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": [],
"m_Space": 2
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "86e940509f2848d7af2f879073bcd297",
"m_Id": 1,
"m_DisplayName": "WorldPosition",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "WorldPosition",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot",
"m_ObjectId": "9d68cf4498f04363b2c3a2379355bf2d",
"m_Id": 0,
"m_DisplayName": "MainLightDiffuse",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": 0.0,
"m_DefaultValue": 0.0,
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot",
"m_ObjectId": "9ee5fab3f65b4d39b530462053082b51",
"m_Id": 1,
"m_DisplayName": "Connected",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "Connected",
"m_StageCapability": 3,
"m_Value": {
"x": 1.0,
"y": 1.0,
"z": 1.0,
"w": 1.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot",
"m_ObjectId": "a20bd994a61349b183b292f543a94b52",
"m_Id": 7,
"m_DisplayName": "Diffuse",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Diffuse",
"m_StageCapability": 3,
"m_Value": 0.0,
"m_DefaultValue": 0.0,
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot",
"m_ObjectId": "a32c2057299d459cb380b8ce1e5ff1bd",
"m_Id": 0,
"m_DisplayName": "Smoothness",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "Smoothness",
"m_StageCapability": 3,
"m_Value": 0.0,
"m_DefaultValue": 0.0,
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "a6c1581aab424348a7ca315cbc7f0b43",
"m_Id": 0,
"m_DisplayName": "Out",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.CategoryData",
"m_ObjectId": "aaacb492a6734ff6b589e422c6adfa3e",
"m_Name": "",
"m_ChildObjectList": [
{
"m_Id": "78c214dac5a14d8896c5b8dd98df66f2"
},
{
"m_Id": "d0e0327aec764cb988d606fa01e1f17a"
},
{
"m_Id": "7f71738800414ec99ae519c6ab2926ec"
},
{
"m_Id": "70cbf5ac6da04bf6bd87eb71ccb7c48d"
},
{
"m_Id": "3c49dbf5eca648f799f5b531726c7ec8"
}
]
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "ac75252a30af458fbdb93d43e98ae814",
"m_Id": 9,
"m_DisplayName": "Color",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Color",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.PropertyNode",
"m_ObjectId": "ac790fc8215b4b3d8851855d2153960d",
"m_Group": {
"m_Id": ""
},
"m_Name": "Property",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -566.4999389648438,
"y": 387.9999694824219,
"width": 155.99996948242188,
"height": 34.000091552734378
}
},
"m_Slots": [
{
"m_Id": "3f98bc4713a5463fb7db2f5261a4ecf0"
}
],
"synonyms": [],
"m_Precision": 0,
"m_PreviewExpanded": true,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Property": {
"m_Id": "7f71738800414ec99ae519c6ab2926ec"
}
}
{
"m_SGVersion": 1,
"m_Type": "UnityEditor.ShaderGraph.CustomFunctionNode",
"m_ObjectId": "af7e463337fa464994ef4fefeb1ef2b0",
"m_Group": {
"m_Id": ""
},
"m_Name": "AddAdditionalLightsSimple (Custom Function)",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -295.0,
"y": 0.0,
"width": 269.0,
"height": 422.0000305175781
}
},
"m_Slots": [
{
"m_Id": "a32c2057299d459cb380b8ce1e5ff1bd"
},
{
"m_Id": "86e940509f2848d7af2f879073bcd297"
},
{
"m_Id": "e3c910e90831452890a82323ac18c38c"
},
{
"m_Id": "b223449b394340fa9409982f64a49d71"
},
{
"m_Id": "6525a66bc0e749559a7c2aaa659a1a1c"
},
{
"m_Id": "034e7f2441f645919d0e6b0f1edf5fd0"
},
{
"m_Id": "13f2abca39da4a50a052891ab4c6b0a6"
},
{
"m_Id": "a20bd994a61349b183b292f543a94b52"
},
{
"m_Id": "2c54247b66954edd8e2688422b8f35d1"
},
{
"m_Id": "ac75252a30af458fbdb93d43e98ae814"
}
],
"synonyms": [
"code",
"HLSL"
],
"m_Precision": 0,
"m_PreviewExpanded": false,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_SourceType": 1,
"m_FunctionName": "AddAdditionalLightsSimple",
"m_FunctionSource": "3beadf505dbc54f4cae878435013d751",
"m_FunctionBody": "Diffuse = MainDiffuse;\r\nSpecular = MainSpecular;\r\nColor = MainColor * (MainDiffuse + MainSpecular);\r\n\r\n#ifndef SHADERGRAPH_PREVIEW\r\n \r\n uint pixelLightCount = GetAdditionalLightsCount();\r\n\r\n#if USE_FORWARD_PLUS\r\n // for Foward+ LIGHT_LOOP_BEGIN macro uses inputData.normalizedScreenSpaceUV and inputData.positionWS\r\n InputData inputData = (InputData)0;\r\n float4 screenPos = ComputeScreenPos(TransformWorldToHClip(WorldPosition));\r\n inputData.normalizedScreenSpaceUV = screenPos.xy / screenPos.w;\r\n inputData.positionWS = WorldPosition;\r\n#endif\r\n\r\n LIGHT_LOOP_BEGIN(pixelLightCount)\r\n\t\t// Convert the pixel light index to the light data index\r\n\t\t#if !USE_FORWARD_PLUS\r\n\t\t\tlightIndex = GetPerObjectLightIndex(lightIndex);\r\n\t\t#endif\r\n\t\t// Call the URP additional light algorithm. This will not calculate shadows, since we don't pass a shadow mask value\r\n\t\tLight light = GetAdditionalPerObjectLight(lightIndex, WorldPosition);\r\n\t\t// Manually set the shadow attenuation by calculating realtime shadows\r\n\t\tlight.shadowAttenuation = AdditionalLightRealtimeShadow(lightIndex, WorldPosition, light.direction);\r\n float NdotL = saturate(dot(WorldNormal, light.direction));\r\n float atten = light.distanceAttenuation * light.shadowAttenuation;\r\n float thisDiffuse = atten * NdotL;\r\r\n Diffuse += thisDiffuse;\r\r\n Color += light.color * (thisDiffuse);\r\n LIGHT_LOOP_END\r\n float total = Diffuse;\r\n Color = total <= 0 ? MainColor : Color / total;\r\n#endif"
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "b223449b394340fa9409982f64a49d71",
"m_Id": 3,
"m_DisplayName": "WorldView",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "WorldView",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot",
"m_ObjectId": "b837ba0c41024e9b922c8310faed2292",
"m_Id": 0,
"m_DisplayName": "Smoothness",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": 0.0,
"m_DefaultValue": 0.0,
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "b9b50f20cbb5424ba1de7ea840dd331a",
"m_Id": 3,
"m_DisplayName": "Color",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "Color",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.PropertyNode",
"m_ObjectId": "b9f05025da4f4857a7b1b6f56259a629",
"m_Group": {
"m_Id": ""
},
"m_Name": "Property",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -550.0,
"y": -128.0,
"width": 140.0,
"height": 34.0
}
},
"m_Slots": [
{
"m_Id": "b837ba0c41024e9b922c8310faed2292"
}
],
"synonyms": [],
"m_Precision": 0,
"m_PreviewExpanded": true,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"m_Property": {
"m_Id": "3c49dbf5eca648f799f5b531726c7ec8"
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "c9c180a1b34442a48565753a99b40087",
"m_Id": 0,
"m_DisplayName": "MainLightSpecular",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 1,
"m_Type": "UnityEditor.ShaderGraph.Internal.Vector3ShaderProperty",
"m_ObjectId": "d0e0327aec764cb988d606fa01e1f17a",
"m_Guid": {
"m_GuidSerialized": "30389ff4-ef29-4a0e-ae70-2fb81f258f8f"
},
"m_Name": "MainLightSpecular",
"m_DefaultRefNameVersion": 1,
"m_RefNameGeneratedByDisplayName": "MainLightSpecular",
"m_DefaultReferenceName": "_MainLightSpecular",
"m_OverrideReferenceName": "",
"m_GeneratePropertyBlock": true,
"m_UseCustomSlotLabel": false,
"m_CustomSlotLabel": "",
"m_DismissedVersion": 0,
"m_Precision": 0,
"overrideHLSLDeclaration": false,
"hlslDeclarationOverride": 0,
"m_Hidden": false,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.BranchOnInputConnectionNode",
"m_ObjectId": "d869e3d8654b48a491de945ad8af6301",
"m_Group": {
"m_Id": ""
},
"m_Name": "Branch On Input Connection",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": -616.4999389648438,
"y": 36.00001907348633,
"width": 205.99996948242188,
"height": 141.99998474121095
}
},
"m_Slots": [
{
"m_Id": "e904b219d90c49a2bd2a70194bb30d71"
},
{
"m_Id": "9ee5fab3f65b4d39b530462053082b51"
},
{
"m_Id": "59d077b7272f47a8a9070b2b13e64523"
},
{
"m_Id": "fc30ae4fc8f74d119de4e399e82a7bc6"
}
],
"synonyms": [],
"m_Precision": 0,
"m_PreviewExpanded": false,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
}
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "e3c910e90831452890a82323ac18c38c",
"m_Id": 2,
"m_DisplayName": "WorldNormal",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "WorldNormal",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "e44ae5bbf0ad43d89107afdbce38e4fc",
"m_Id": 0,
"m_DisplayName": "Out",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "e8febe5f94b549beab8c0cd882d617df",
"m_Id": 0,
"m_DisplayName": "Out",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 1.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 1.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.PropertyConnectionStateMaterialSlot",
"m_ObjectId": "e904b219d90c49a2bd2a70194bb30d71",
"m_Id": 0,
"m_DisplayName": "Input",
"m_SlotType": 0,
"m_Hidden": false,
"m_ShaderOutputName": "Input",
"m_StageCapability": 3
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot",
"m_ObjectId": "f5454ef35e00400baaa0360e57daf01b",
"m_Id": 0,
"m_DisplayName": "NormalWS",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0
},
"m_Labels": []
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.SubGraphOutputNode",
"m_ObjectId": "f60afd3e2b9848c6a7c34ee429cc7a64",
"m_Group": {
"m_Id": ""
},
"m_Name": "Output",
"m_DrawState": {
"m_Expanded": true,
"m_Position": {
"serializedVersion": "2",
"x": 30.0,
"y": 0.0,
"width": 101.0,
"height": 125.0
}
},
"m_Slots": [
{
"m_Id": "2b53e0ba123249889a9a7f8c8a0b6d1f"
},
{
"m_Id": "01f7cc366d65489099cc74e89af039ae"
},
{
"m_Id": "b9b50f20cbb5424ba1de7ea840dd331a"
}
],
"synonyms": [],
"m_Precision": 0,
"m_PreviewExpanded": true,
"m_DismissedVersion": 0,
"m_PreviewMode": 0,
"m_CustomColors": {
"m_SerializableColors": []
},
"IsFirstSlotValid": true
}
{
"m_SGVersion": 0,
"m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot",
"m_ObjectId": "fc30ae4fc8f74d119de4e399e82a7bc6",
"m_Id": 3,
"m_DisplayName": "Out",
"m_SlotType": 1,
"m_Hidden": false,
"m_ShaderOutputName": "Out",
"m_StageCapability": 3,
"m_Value": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
},
"m_DefaultValue": {
"x": 0.0,
"y": 0.0,
"z": 0.0,
"w": 0.0
}
}