• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1spv.ext.ClosestHitShader.rchit
2// Module Version 10400
3// Generated by (magic number): 8000b
4// Id's are bound by 108
5
6                              Capability RayTracingKHR
7                              Capability RayTracingPositionFetchKHR
8                              Capability RayCullMaskKHR
9                              Extension  "SPV_KHR_ray_cull_mask"
10                              Extension  "SPV_KHR_ray_tracing"
11                              Extension  "SPV_KHR_ray_tracing_position_fetch"
12               1:             ExtInstImport  "GLSL.std.450"
13                              MemoryModel Logical GLSL450
14                              EntryPoint ClosestHitKHR 4  "main" 11 14 20 23 26 33 36 39 42 47 50 57 63 66 69 81 87 93 105 107
15                              Source GLSL 460
16                              SourceExtension  "GL_EXT_ray_cull_mask"
17                              SourceExtension  "GL_EXT_ray_tracing"
18                              SourceExtension  "GL_EXT_ray_tracing_position_fetch"
19                              Name 4  "main"
20                              Name 9  "v0"
21                              Name 11  "gl_LaunchIDEXT"
22                              Name 13  "v1"
23                              Name 14  "gl_LaunchSizeEXT"
24                              Name 18  "v2"
25                              Name 20  "gl_PrimitiveID"
26                              Name 22  "v3"
27                              Name 23  "gl_InstanceID"
28                              Name 25  "v4"
29                              Name 26  "gl_InstanceCustomIndexEXT"
30                              Name 31  "v5"
31                              Name 33  "gl_WorldRayOriginEXT"
32                              Name 35  "v6"
33                              Name 36  "gl_WorldRayDirectionEXT"
34                              Name 38  "v7"
35                              Name 39  "gl_ObjectRayOriginEXT"
36                              Name 41  "v8"
37                              Name 42  "gl_ObjectRayDirectionEXT"
38                              Name 45  "v9"
39                              Name 47  "gl_RayTminEXT"
40                              Name 49  "v10"
41                              Name 50  "gl_RayTmaxEXT"
42                              Name 52  "v11"
43                              Name 55  "v12"
44                              Name 57  "gl_HitKindEXT"
45                              Name 61  "v13"
46                              Name 63  "gl_ObjectToWorldEXT"
47                              Name 65  "v14"
48                              Name 66  "gl_WorldToObjectEXT"
49                              Name 68  "v15"
50                              Name 69  "gl_GeometryIndexEXT"
51                              Name 74  "v16"
52                              Name 77  "v17"
53                              Name 80  "v18"
54                              Name 81  "gl_CullMaskEXT"
55                              Name 83  "v19"
56                              Name 87  "gl_HitTriangleVertexPositionsEXT"
57                              Name 93  "accEXT"
58                              Name 105  "incomingPayload"
59                              Name 107  "localPayload"
60                              Decorate 11(gl_LaunchIDEXT) BuiltIn LaunchIdKHR
61                              Decorate 14(gl_LaunchSizeEXT) BuiltIn LaunchSizeKHR
62                              Decorate 20(gl_PrimitiveID) BuiltIn PrimitiveId
63                              Decorate 23(gl_InstanceID) BuiltIn InstanceId
64                              Decorate 26(gl_InstanceCustomIndexEXT) BuiltIn InstanceCustomIndexKHR
65                              Decorate 33(gl_WorldRayOriginEXT) BuiltIn WorldRayOriginKHR
66                              Decorate 36(gl_WorldRayDirectionEXT) BuiltIn WorldRayDirectionKHR
67                              Decorate 39(gl_ObjectRayOriginEXT) BuiltIn ObjectRayOriginKHR
68                              Decorate 42(gl_ObjectRayDirectionEXT) BuiltIn ObjectRayDirectionKHR
69                              Decorate 47(gl_RayTminEXT) BuiltIn RayTminKHR
70                              Decorate 50(gl_RayTmaxEXT) BuiltIn RayTmaxKHR
71                              Decorate 57(gl_HitKindEXT) BuiltIn HitKindKHR
72                              Decorate 63(gl_ObjectToWorldEXT) BuiltIn ObjectToWorldKHR
73                              Decorate 66(gl_WorldToObjectEXT) BuiltIn WorldToObjectKHR
74                              Decorate 69(gl_GeometryIndexEXT) BuiltIn RayGeometryIndexKHR
75                              Decorate 81(gl_CullMaskEXT) BuiltIn CullMaskKHR
76                              Decorate 87(gl_HitTriangleVertexPositionsEXT) BuiltIn HitTriangleVertexPositionsKHR
77                              Decorate 93(accEXT) Binding 0
78                              Decorate 93(accEXT) DescriptorSet 0
79               2:             TypeVoid
80               3:             TypeFunction 2
81               6:             TypeInt 32 0
82               7:             TypeVector 6(int) 3
83               8:             TypePointer Function 7(ivec3)
84              10:             TypePointer Input 7(ivec3)
8511(gl_LaunchIDEXT):     10(ptr) Variable Input
8614(gl_LaunchSizeEXT):     10(ptr) Variable Input
87              16:             TypeInt 32 1
88              17:             TypePointer Function 16(int)
89              19:             TypePointer Input 16(int)
9020(gl_PrimitiveID):     19(ptr) Variable Input
9123(gl_InstanceID):     19(ptr) Variable Input
9226(gl_InstanceCustomIndexEXT):     19(ptr) Variable Input
93              28:             TypeFloat 32
94              29:             TypeVector 28(float) 3
95              30:             TypePointer Function 29(fvec3)
96              32:             TypePointer Input 29(fvec3)
9733(gl_WorldRayOriginEXT):     32(ptr) Variable Input
9836(gl_WorldRayDirectionEXT):     32(ptr) Variable Input
9939(gl_ObjectRayOriginEXT):     32(ptr) Variable Input
10042(gl_ObjectRayDirectionEXT):     32(ptr) Variable Input
101              44:             TypePointer Function 28(float)
102              46:             TypePointer Input 28(float)
10347(gl_RayTminEXT):     46(ptr) Variable Input
10450(gl_RayTmaxEXT):     46(ptr) Variable Input
105              54:             TypePointer Function 6(int)
106              56:             TypePointer Input 6(int)
10757(gl_HitKindEXT):     56(ptr) Variable Input
108              59:             TypeMatrix 29(fvec3) 4
109              60:             TypePointer Function 59
110              62:             TypePointer Input 59
11163(gl_ObjectToWorldEXT):     62(ptr) Variable Input
11266(gl_WorldToObjectEXT):     62(ptr) Variable Input
11369(gl_GeometryIndexEXT):     19(ptr) Variable Input
114              71:             TypeVector 28(float) 4
115              72:             TypeMatrix 71(fvec4) 3
116              73:             TypePointer Function 72
11781(gl_CullMaskEXT):     56(ptr) Variable Input
118              84:      6(int) Constant 3
119              85:             TypeArray 29(fvec3) 84
120              86:             TypePointer Input 85
12187(gl_HitTriangleVertexPositionsEXT):     86(ptr) Variable Input
122              88:     16(int) Constant 0
123              91:             TypeAccelerationStructureKHR
124              92:             TypePointer UniformConstant 91
125      93(accEXT):     92(ptr) Variable UniformConstant
126              95:      6(int) Constant 0
127              96:      6(int) Constant 1
128              97:      6(int) Constant 2
129              98:   28(float) Constant 1056964608
130              99:   29(fvec3) ConstantComposite 98 98 98
131             100:   28(float) Constant 1065353216
132             101:   29(fvec3) ConstantComposite 100 100 100
133             102:   28(float) Constant 1061158912
134             103:     16(int) Constant 1
135             104:             TypePointer IncomingRayPayloadKHR 71(fvec4)
136105(incomingPayload):    104(ptr) Variable IncomingRayPayloadKHR
137             106:             TypePointer RayPayloadKHR 71(fvec4)
138107(localPayload):    106(ptr) Variable RayPayloadKHR
139         4(main):           2 Function None 3
140               5:             Label
141           9(v0):      8(ptr) Variable Function
142          13(v1):      8(ptr) Variable Function
143          18(v2):     17(ptr) Variable Function
144          22(v3):     17(ptr) Variable Function
145          25(v4):     17(ptr) Variable Function
146          31(v5):     30(ptr) Variable Function
147          35(v6):     30(ptr) Variable Function
148          38(v7):     30(ptr) Variable Function
149          41(v8):     30(ptr) Variable Function
150          45(v9):     44(ptr) Variable Function
151         49(v10):     44(ptr) Variable Function
152         52(v11):     44(ptr) Variable Function
153         55(v12):     54(ptr) Variable Function
154         61(v13):     60(ptr) Variable Function
155         65(v14):     60(ptr) Variable Function
156         68(v15):     17(ptr) Variable Function
157         74(v16):     73(ptr) Variable Function
158         77(v17):     73(ptr) Variable Function
159         80(v18):     54(ptr) Variable Function
160         83(v19):     30(ptr) Variable Function
161              12:    7(ivec3) Load 11(gl_LaunchIDEXT)
162                              Store 9(v0) 12
163              15:    7(ivec3) Load 14(gl_LaunchSizeEXT)
164                              Store 13(v1) 15
165              21:     16(int) Load 20(gl_PrimitiveID)
166                              Store 18(v2) 21
167              24:     16(int) Load 23(gl_InstanceID)
168                              Store 22(v3) 24
169              27:     16(int) Load 26(gl_InstanceCustomIndexEXT)
170                              Store 25(v4) 27
171              34:   29(fvec3) Load 33(gl_WorldRayOriginEXT)
172                              Store 31(v5) 34
173              37:   29(fvec3) Load 36(gl_WorldRayDirectionEXT)
174                              Store 35(v6) 37
175              40:   29(fvec3) Load 39(gl_ObjectRayOriginEXT)
176                              Store 38(v7) 40
177              43:   29(fvec3) Load 42(gl_ObjectRayDirectionEXT)
178                              Store 41(v8) 43
179              48:   28(float) Load 47(gl_RayTminEXT)
180                              Store 45(v9) 48
181              51:   28(float) Load 50(gl_RayTmaxEXT)
182                              Store 49(v10) 51
183              53:   28(float) Load 50(gl_RayTmaxEXT)
184                              Store 52(v11) 53
185              58:      6(int) Load 57(gl_HitKindEXT)
186                              Store 55(v12) 58
187              64:          59 Load 63(gl_ObjectToWorldEXT)
188                              Store 61(v13) 64
189              67:          59 Load 66(gl_WorldToObjectEXT)
190                              Store 65(v14) 67
191              70:     16(int) Load 69(gl_GeometryIndexEXT)
192                              Store 68(v15) 70
193              75:          59 Load 63(gl_ObjectToWorldEXT)
194              76:          72 Transpose 75
195                              Store 74(v16) 76
196              78:          59 Load 66(gl_WorldToObjectEXT)
197              79:          72 Transpose 78
198                              Store 77(v17) 79
199              82:      6(int) Load 81(gl_CullMaskEXT)
200                              Store 80(v18) 82
201              89:     32(ptr) AccessChain 87(gl_HitTriangleVertexPositionsEXT) 88
202              90:   29(fvec3) Load 89
203                              Store 83(v19) 90
204              94:          91 Load 93(accEXT)
205                              TraceRayKHR 94 95 96 97 84 95 99 98 101 102 105(incomingPayload)
206                              Return
207                              FunctionEnd
208