File size: 4,274 Bytes
3aa586d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#usda 1.0
(
    customLayerData = {
        string author = "ambientCG (ambientCG.com)"
        string copyright = "CC0 1.0 Public Domain Dedication (https://creativecommons.org/publicdomain/zero/1.0/)"
        string generator = "ambientCG USD Script (v2)"
        string title = "Leaf003 by ambientCG"
        string url = "https://ambientcg.com/a/Leaf003"
    }
    defaultPrim = "ambientCG_Leaf003_1K_JPG"
)

def Material "ambientCG_Leaf003_1K_JPG"
{
    token outputs:surface.connect = </ambientCG_Leaf003_1K_JPG/PBRShader.outputs:surface>

    def Shader "TextureCoordinateReader"
    {
        uniform token info:id = "UsdPrimvarReader_float2"
        token inputs:varname = "st"
        float2 outputs:result
    }

    def Shader "PBRShader"
    {
        uniform token info:id = "UsdPreviewSurface"
        color3f inputs:diffuseColor.connect = </ambientCG_Leaf003_1K_JPG/diffuseColor.outputs:rgb>
        float inputs:displacement.connect = </ambientCG_Leaf003_1K_JPG/displacement.outputs:r>
        normal3f inputs:normal.connect = </ambientCG_Leaf003_1K_JPG/normal.outputs:rgb>
        float inputs:occlusion.connect = </ambientCG_Leaf003_1K_JPG/occlusion.outputs:r>
        float inputs:roughness.connect = </ambientCG_Leaf003_1K_JPG/roughness.outputs:r>
        float inputs:opacity.connect = </ambientCG_Leaf003_1K_JPG/opacity.outputs:r>
        int inputs:useSpecularWorkflow = 0
        token outputs:surface
    }

    def Shader "diffuseColor"
    {
        uniform token info:id = "UsdUVTexture"
        float4 inputs:fallback = (0.8, 0.8, 0.8, 1)
        asset inputs:file = @Leaf003_1K_Color.jpg@
        float2 inputs:st.connect = </ambientCG_Leaf003_1K_JPG/TextureCoordinateReader.outputs:result>
        token inputs:sourceColorSpace = "sRGB"
        token inputs:wrapS = "repeat"
        token inputs:wrapT = "repeat"
        float3 outputs:rgb
    }

    def Shader "occlusion"
    {
        uniform token info:id = "UsdUVTexture"
        float4 inputs:fallback = (1, 1, 1, 1)
        asset inputs:file = @Leaf003_1K_AmbientOcclusion.jpg@
        float2 inputs:st.connect = </ambientCG_Leaf003_1K_JPG/TextureCoordinateReader.outputs:result>
        token inputs:sourceColorSpace = "raw"
        token inputs:wrapS = "repeat"
        token inputs:wrapT = "repeat"
        float outputs:r
    }

    def Shader "displacement"
    {
        uniform token info:id = "UsdUVTexture"
        float4 inputs:fallback = (0.5, 0.5, 0.5, 1)
        asset inputs:file = @Leaf003_1K_Displacement.jpg@
        float2 inputs:st.connect = </ambientCG_Leaf003_1K_JPG/TextureCoordinateReader.outputs:result>
        token inputs:sourceColorSpace = "raw"
        token inputs:wrapS = "repeat"
        token inputs:wrapT = "repeat"
        float outputs:r
    }

    def Shader "roughness"
    {
        uniform token info:id = "UsdUVTexture"
        float4 inputs:fallback = (1, 1, 1, 1)
        asset inputs:file = @Leaf003_1K_Roughness.jpg@
        float2 inputs:st.connect = </ambientCG_Leaf003_1K_JPG/TextureCoordinateReader.outputs:result>
        token inputs:sourceColorSpace = "raw"
        token inputs:wrapS = "repeat"
        token inputs:wrapT = "repeat"
        float outputs:r
    }

    def Shader "normal"
    {
        uniform token info:id = "UsdUVTexture"
        float4 inputs:fallback = (0, 0, 1, 1)
        asset inputs:file = @Leaf003_1K_NormalGL.jpg@
        float2 inputs:st.connect = </ambientCG_Leaf003_1K_JPG/TextureCoordinateReader.outputs:result>
        float4 inputs:bias = (-1, -1, -1, 0)
        float4 inputs:scale = (2, 2, 2, 1)
        token inputs:sourceColorSpace = "raw"
        token inputs:wrapS = "repeat"
        token inputs:wrapT = "repeat"
        float3 outputs:rgb
    }

    def Shader "opacity"
    {
        uniform token info:id = "UsdUVTexture"
        float4 inputs:fallback = (1, 1, 1, 1)
        asset inputs:file = @Leaf003_1K_Opacity.jpg@
        float2 inputs:st.connect = </ambientCG_Leaf003_1K_JPG/TextureCoordinateReader.outputs:result>
        token inputs:sourceColorSpace = "raw"
        token inputs:wrapS = "repeat"
        token inputs:wrapT = "repeat"
        float outputs:r
    }
}