|
7 | 7 | "kind": "constantBuffer", |
8 | 8 | "elementType": { |
9 | 9 | "kind": "struct", |
10 | | - "name": "MaterialBlock", |
| 10 | + "name": "PbrMaterial", |
11 | 11 | "fields": [ |
12 | 12 | { |
13 | | - "name": "material", |
| 13 | + "name": "baseColor", |
14 | 14 | "type": { |
15 | | - "kind": "struct", |
16 | | - "name": "PbrMaterial", |
17 | | - "fields": [ |
18 | | - { |
19 | | - "name": "baseColor", |
20 | | - "type": { |
21 | | - "kind": "vector", |
22 | | - "elementCount": 4, |
23 | | - "elementType": { |
24 | | - "kind": "scalar", |
25 | | - "scalarType": "float32" |
26 | | - } |
27 | | - }, |
28 | | - "binding": {"kind": "uniform", "offset": 0, "size": 16, "elementStride": 4} |
29 | | - }, |
30 | | - { |
31 | | - "name": "metalness", |
32 | | - "type": { |
33 | | - "kind": "scalar", |
34 | | - "scalarType": "float32" |
35 | | - }, |
36 | | - "binding": {"kind": "uniform", "offset": 16, "size": 4, "elementStride": 0} |
37 | | - }, |
38 | | - { |
39 | | - "name": "roughness", |
40 | | - "type": { |
41 | | - "kind": "scalar", |
42 | | - "scalarType": "float32" |
43 | | - }, |
44 | | - "binding": {"kind": "uniform", "offset": 20, "size": 4, "elementStride": 0} |
45 | | - }, |
46 | | - { |
47 | | - "name": "ao", |
48 | | - "type": { |
49 | | - "kind": "scalar", |
50 | | - "scalarType": "float32" |
51 | | - }, |
52 | | - "binding": {"kind": "uniform", "offset": 24, "size": 4, "elementStride": 0} |
53 | | - } |
54 | | - ] |
| 15 | + "kind": "vector", |
| 16 | + "elementCount": 4, |
| 17 | + "elementType": { |
| 18 | + "kind": "scalar", |
| 19 | + "scalarType": "float32" |
| 20 | + } |
55 | 21 | }, |
56 | | - "binding": {"kind": "uniform", "offset": 0, "size": 32, "elementStride": 0} |
| 22 | + "binding": {"kind": "uniform", "offset": 0, "size": 16, "elementStride": 4} |
| 23 | + }, |
| 24 | + { |
| 25 | + "name": "metalness", |
| 26 | + "type": { |
| 27 | + "kind": "scalar", |
| 28 | + "scalarType": "float32" |
| 29 | + }, |
| 30 | + "binding": {"kind": "uniform", "offset": 16, "size": 4, "elementStride": 0} |
| 31 | + }, |
| 32 | + { |
| 33 | + "name": "roughness", |
| 34 | + "type": { |
| 35 | + "kind": "scalar", |
| 36 | + "scalarType": "float32" |
| 37 | + }, |
| 38 | + "binding": {"kind": "uniform", "offset": 20, "size": 4, "elementStride": 0} |
| 39 | + }, |
| 40 | + { |
| 41 | + "name": "ao", |
| 42 | + "type": { |
| 43 | + "kind": "scalar", |
| 44 | + "scalarType": "float32" |
| 45 | + }, |
| 46 | + "binding": {"kind": "uniform", "offset": 24, "size": 4, "elementStride": 0} |
57 | 47 | } |
58 | 48 | ] |
59 | 49 | }, |
|
63 | 53 | "elementVarLayout": { |
64 | 54 | "type": { |
65 | 55 | "kind": "struct", |
66 | | - "name": "MaterialBlock", |
| 56 | + "name": "PbrMaterial", |
67 | 57 | "fields": [ |
68 | 58 | { |
69 | | - "name": "material", |
| 59 | + "name": "baseColor", |
70 | 60 | "type": { |
71 | | - "kind": "struct", |
72 | | - "name": "PbrMaterial", |
73 | | - "fields": [ |
74 | | - { |
75 | | - "name": "baseColor", |
76 | | - "type": { |
77 | | - "kind": "vector", |
78 | | - "elementCount": 4, |
79 | | - "elementType": { |
80 | | - "kind": "scalar", |
81 | | - "scalarType": "float32" |
82 | | - } |
83 | | - }, |
84 | | - "binding": {"kind": "uniform", "offset": 0, "size": 16, "elementStride": 4} |
85 | | - }, |
86 | | - { |
87 | | - "name": "metalness", |
88 | | - "type": { |
89 | | - "kind": "scalar", |
90 | | - "scalarType": "float32" |
91 | | - }, |
92 | | - "binding": {"kind": "uniform", "offset": 16, "size": 4, "elementStride": 0} |
93 | | - }, |
94 | | - { |
95 | | - "name": "roughness", |
96 | | - "type": { |
97 | | - "kind": "scalar", |
98 | | - "scalarType": "float32" |
99 | | - }, |
100 | | - "binding": {"kind": "uniform", "offset": 20, "size": 4, "elementStride": 0} |
101 | | - }, |
102 | | - { |
103 | | - "name": "ao", |
104 | | - "type": { |
105 | | - "kind": "scalar", |
106 | | - "scalarType": "float32" |
107 | | - }, |
108 | | - "binding": {"kind": "uniform", "offset": 24, "size": 4, "elementStride": 0} |
109 | | - } |
110 | | - ] |
| 61 | + "kind": "vector", |
| 62 | + "elementCount": 4, |
| 63 | + "elementType": { |
| 64 | + "kind": "scalar", |
| 65 | + "scalarType": "float32" |
| 66 | + } |
| 67 | + }, |
| 68 | + "binding": {"kind": "uniform", "offset": 0, "size": 16, "elementStride": 4} |
| 69 | + }, |
| 70 | + { |
| 71 | + "name": "metalness", |
| 72 | + "type": { |
| 73 | + "kind": "scalar", |
| 74 | + "scalarType": "float32" |
111 | 75 | }, |
112 | | - "binding": {"kind": "uniform", "offset": 0, "size": 32, "elementStride": 0} |
| 76 | + "binding": {"kind": "uniform", "offset": 16, "size": 4, "elementStride": 0} |
| 77 | + }, |
| 78 | + { |
| 79 | + "name": "roughness", |
| 80 | + "type": { |
| 81 | + "kind": "scalar", |
| 82 | + "scalarType": "float32" |
| 83 | + }, |
| 84 | + "binding": {"kind": "uniform", "offset": 20, "size": 4, "elementStride": 0} |
| 85 | + }, |
| 86 | + { |
| 87 | + "name": "ao", |
| 88 | + "type": { |
| 89 | + "kind": "scalar", |
| 90 | + "scalarType": "float32" |
| 91 | + }, |
| 92 | + "binding": {"kind": "uniform", "offset": 24, "size": 4, "elementStride": 0} |
113 | 93 | } |
114 | 94 | ] |
115 | 95 | }, |
|
180 | 160 | "scalarType": "int32" |
181 | 161 | }, |
182 | 162 | "binding": {"kind": "uniform", "offset": 192, "size": 4, "elementStride": 0} |
| 163 | + }, |
| 164 | + { |
| 165 | + "name": "useSsao", |
| 166 | + "type": { |
| 167 | + "kind": "scalar", |
| 168 | + "scalarType": "uint32" |
| 169 | + }, |
| 170 | + "binding": {"kind": "uniform", "offset": 196, "size": 4, "elementStride": 0} |
183 | 171 | } |
184 | 172 | ] |
185 | 173 | }, |
|
245 | 233 | "scalarType": "int32" |
246 | 234 | }, |
247 | 235 | "binding": {"kind": "uniform", "offset": 192, "size": 4, "elementStride": 0} |
248 | | - } |
249 | | - ] |
250 | | - }, |
251 | | - "binding": {"kind": "uniform", "offset": 0, "size": 208, "elementStride": 0} |
252 | | - } |
253 | | - } |
254 | | - }, |
255 | | - { |
256 | | - "name": "params", |
257 | | - "binding": {"kind": "descriptorTableSlot", "space": 3, "index": 2}, |
258 | | - "type": { |
259 | | - "kind": "constantBuffer", |
260 | | - "elementType": { |
261 | | - "kind": "struct", |
262 | | - "name": "EffectParams", |
263 | | - "fields": [ |
264 | | - { |
265 | | - "name": "useSsao", |
266 | | - "type": { |
267 | | - "kind": "scalar", |
268 | | - "scalarType": "uint32" |
269 | 236 | }, |
270 | | - "binding": {"kind": "uniform", "offset": 0, "size": 4, "elementStride": 0} |
271 | | - } |
272 | | - ] |
273 | | - }, |
274 | | - "containerVarLayout": { |
275 | | - "binding": {"kind": "descriptorTableSlot", "index": 0} |
276 | | - }, |
277 | | - "elementVarLayout": { |
278 | | - "type": { |
279 | | - "kind": "struct", |
280 | | - "name": "EffectParams", |
281 | | - "fields": [ |
282 | 237 | { |
283 | 238 | "name": "useSsao", |
284 | 239 | "type": { |
285 | 240 | "kind": "scalar", |
286 | 241 | "scalarType": "uint32" |
287 | 242 | }, |
288 | | - "binding": {"kind": "uniform", "offset": 0, "size": 4, "elementStride": 0} |
| 243 | + "binding": {"kind": "uniform", "offset": 196, "size": 4, "elementStride": 0} |
289 | 244 | } |
290 | 245 | ] |
291 | 246 | }, |
292 | | - "binding": {"kind": "uniform", "offset": 0, "size": 16, "elementStride": 0} |
| 247 | + "binding": {"kind": "uniform", "offset": 0, "size": 208, "elementStride": 0} |
293 | 248 | } |
294 | 249 | } |
295 | 250 | }, |
296 | 251 | { |
297 | 252 | "name": "shadowAtlas", |
298 | | - "binding": {"kind": "descriptorTableSlot", "space": 3, "index": 3}, |
| 253 | + "binding": {"kind": "descriptorTableSlot", "space": 3, "index": 2}, |
299 | 254 | "type": { |
300 | 255 | "kind": "constantBuffer", |
301 | 256 | "elementType": { |
|
511 | 466 | "name": "light", |
512 | 467 | "binding": {"kind": "descriptorTableSlot", "space": 3, "index": 1, "used": 1} |
513 | 468 | }, |
514 | | - { |
515 | | - "name": "params", |
516 | | - "binding": {"kind": "descriptorTableSlot", "space": 3, "index": 2, "used": 1} |
517 | | - }, |
518 | 469 | { |
519 | 470 | "name": "shadowAtlas", |
520 | | - "binding": {"kind": "descriptorTableSlot", "space": 3, "index": 3, "used": 1} |
| 471 | + "binding": {"kind": "descriptorTableSlot", "space": 3, "index": 2, "used": 1} |
521 | 472 | }, |
522 | 473 | { |
523 | 474 | "name": "shadowMap", |
|
0 commit comments