saxaboom-runtime 0.2.0+irconverter-2.0

Runtime definitions for Metal Shader Converter
Documentation
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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
/* automatically generated by rust-bindgen 0.71.1 */

#[repr(C)]
#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct __BindgenBitfieldUnit<Storage> {
    storage: Storage,
}
impl<Storage> __BindgenBitfieldUnit<Storage> {
    #[inline]
    pub const fn new(storage: Storage) -> Self {
        Self { storage }
    }
}
impl<Storage> __BindgenBitfieldUnit<Storage>
where
    Storage: AsRef<[u8]> + AsMut<[u8]>,
{
    #[inline]
    fn extract_bit(byte: u8, index: usize) -> bool {
        let bit_index = if cfg!(target_endian = "big") {
            7 - (index % 8)
        } else {
            index % 8
        };
        let mask = 1 << bit_index;
        byte & mask == mask
    }
    #[inline]
    pub fn get_bit(&self, index: usize) -> bool {
        debug_assert!(index / 8 < self.storage.as_ref().len());
        let byte_index = index / 8;
        let byte = self.storage.as_ref()[byte_index];
        Self::extract_bit(byte, index)
    }
    #[inline]
    pub unsafe fn raw_get_bit(this: *const Self, index: usize) -> bool {
        debug_assert!(index / 8 < core::mem::size_of::<Storage>());
        let byte_index = index / 8;
        let byte = *(core::ptr::addr_of!((*this).storage) as *const u8).offset(byte_index as isize);
        Self::extract_bit(byte, index)
    }
    #[inline]
    fn change_bit(byte: u8, index: usize, val: bool) -> u8 {
        let bit_index = if cfg!(target_endian = "big") {
            7 - (index % 8)
        } else {
            index % 8
        };
        let mask = 1 << bit_index;
        if val {
            byte | mask
        } else {
            byte & !mask
        }
    }
    #[inline]
    pub fn set_bit(&mut self, index: usize, val: bool) {
        debug_assert!(index / 8 < self.storage.as_ref().len());
        let byte_index = index / 8;
        let byte = &mut self.storage.as_mut()[byte_index];
        *byte = Self::change_bit(*byte, index, val);
    }
    #[inline]
    pub unsafe fn raw_set_bit(this: *mut Self, index: usize, val: bool) {
        debug_assert!(index / 8 < core::mem::size_of::<Storage>());
        let byte_index = index / 8;
        let byte =
            (core::ptr::addr_of_mut!((*this).storage) as *mut u8).offset(byte_index as isize);
        *byte = Self::change_bit(*byte, index, val);
    }
    #[inline]
    pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 {
        debug_assert!(bit_width <= 64);
        debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
        debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
        let mut val = 0;
        for i in 0..(bit_width as usize) {
            if self.get_bit(i + bit_offset) {
                let index = if cfg!(target_endian = "big") {
                    bit_width as usize - 1 - i
                } else {
                    i
                };
                val |= 1 << index;
            }
        }
        val
    }
    #[inline]
    pub unsafe fn raw_get(this: *const Self, bit_offset: usize, bit_width: u8) -> u64 {
        debug_assert!(bit_width <= 64);
        debug_assert!(bit_offset / 8 < core::mem::size_of::<Storage>());
        debug_assert!((bit_offset + (bit_width as usize)) / 8 <= core::mem::size_of::<Storage>());
        let mut val = 0;
        for i in 0..(bit_width as usize) {
            if Self::raw_get_bit(this, i + bit_offset) {
                let index = if cfg!(target_endian = "big") {
                    bit_width as usize - 1 - i
                } else {
                    i
                };
                val |= 1 << index;
            }
        }
        val
    }
    #[inline]
    pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) {
        debug_assert!(bit_width <= 64);
        debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
        debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
        for i in 0..(bit_width as usize) {
            let mask = 1 << i;
            let val_bit_is_set = val & mask == mask;
            let index = if cfg!(target_endian = "big") {
                bit_width as usize - 1 - i
            } else {
                i
            };
            self.set_bit(index + bit_offset, val_bit_is_set);
        }
    }
    #[inline]
    pub unsafe fn raw_set(this: *mut Self, bit_offset: usize, bit_width: u8, val: u64) {
        debug_assert!(bit_width <= 64);
        debug_assert!(bit_offset / 8 < core::mem::size_of::<Storage>());
        debug_assert!((bit_offset + (bit_width as usize)) / 8 <= core::mem::size_of::<Storage>());
        for i in 0..(bit_width as usize) {
            let mask = 1 << i;
            let val_bit_is_set = val & mask == mask;
            let index = if cfg!(target_endian = "big") {
                bit_width as usize - 1 - i
            } else {
                i
            };
            Self::raw_set_bit(this, index + bit_offset, val_bit_is_set);
        }
    }
}
pub type uint = ::std::os::raw::c_uint;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct MTLDispatchThreadgroupsIndirectArguments {
    pub threadgroupsPerGrid: [u32; 3usize],
}
pub type resourceid_t = MTLResourceID;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRDescriptorTableEntry {
    pub gpuVA: u64,
    pub textureViewID: u64,
    pub metadata: u64,
}
pub const kIRRuntimeTessellatorTablesBindPoint: u64 = 7;
pub const kIRRuntimeTessellatorTablesCountsAndOffsetLength: u32 = 32768;
pub const kIRRuntimeTessellatorTablesLookupTableLength: u32 = 701114;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRShaderIdentifier {
    pub intersectionShaderHandle: u64,
    pub shaderHandle: u64,
    pub localRootSignatureSamplersBuffer: u64,
    pub pad0: u64,
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRVirtualAddressRange {
    pub StartAddress: u64,
    pub SizeInBytes: u64,
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRVirtualAddressRangeAndStride {
    pub StartAddress: u64,
    pub SizeInBytes: u64,
    pub StrideInBytes: u64,
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRDispatchRaysDescriptor {
    pub RayGenerationShaderRecord: IRVirtualAddressRange,
    pub MissShaderTable: IRVirtualAddressRangeAndStride,
    pub HitGroupTable: IRVirtualAddressRangeAndStride,
    pub CallableShaderTable: IRVirtualAddressRangeAndStride,
    pub Width: uint,
    pub Height: uint,
    pub Depth: uint,
}
#[repr(C)]
pub struct IRDispatchRaysArgument {
    pub DispatchRaysDesc: IRDispatchRaysDescriptor,
    pub GRS: u64,
    pub ResDescHeap: u64,
    pub SmpDescHeap: u64,
    pub VisibleFunctionTable: resourceid_t,
    pub IntersectionFunctionTable: resourceid_t,
    pub IntersectionFunctionTables: u64,
}
impl Default for IRDispatchRaysArgument {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type dispatchthreadgroupsindirectargs_t = MTLDispatchThreadgroupsIndirectArguments;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRRaytracingAccelerationStructureGPUHeader {
    pub accelerationStructureID: u64,
    pub addressOfInstanceContributions: u64,
    pub pad0: [u64; 4usize],
    pub pad1: dispatchthreadgroupsindirectargs_t,
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRRaytracingInstanceDescriptor {
    pub Transform: [[f32; 4usize]; 3usize],
    pub _bitfield_align_1: [u32; 0],
    pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
    pub AccelerationStructure: u64,
}
impl IRRaytracingInstanceDescriptor {
    #[inline]
    pub fn InstanceID(&self) -> u32 {
        unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 24u8) as u32) }
    }
    #[inline]
    pub fn set_InstanceID(&mut self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            self._bitfield_1.set(0usize, 24u8, val as u64)
        }
    }
    #[inline]
    pub unsafe fn InstanceID_raw(this: *const Self) -> u32 {
        unsafe {
            ::std::mem::transmute(<__BindgenBitfieldUnit<[u8; 8usize]>>::raw_get(
                ::std::ptr::addr_of!((*this)._bitfield_1),
                0usize,
                24u8,
            ) as u32)
        }
    }
    #[inline]
    pub unsafe fn set_InstanceID_raw(this: *mut Self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            <__BindgenBitfieldUnit<[u8; 8usize]>>::raw_set(
                ::std::ptr::addr_of_mut!((*this)._bitfield_1),
                0usize,
                24u8,
                val as u64,
            )
        }
    }
    #[inline]
    pub fn InstanceMask(&self) -> u32 {
        unsafe { ::std::mem::transmute(self._bitfield_1.get(24usize, 8u8) as u32) }
    }
    #[inline]
    pub fn set_InstanceMask(&mut self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            self._bitfield_1.set(24usize, 8u8, val as u64)
        }
    }
    #[inline]
    pub unsafe fn InstanceMask_raw(this: *const Self) -> u32 {
        unsafe {
            ::std::mem::transmute(<__BindgenBitfieldUnit<[u8; 8usize]>>::raw_get(
                ::std::ptr::addr_of!((*this)._bitfield_1),
                24usize,
                8u8,
            ) as u32)
        }
    }
    #[inline]
    pub unsafe fn set_InstanceMask_raw(this: *mut Self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            <__BindgenBitfieldUnit<[u8; 8usize]>>::raw_set(
                ::std::ptr::addr_of_mut!((*this)._bitfield_1),
                24usize,
                8u8,
                val as u64,
            )
        }
    }
    #[inline]
    pub fn InstanceContributionToHitGroupIndex(&self) -> u32 {
        unsafe { ::std::mem::transmute(self._bitfield_1.get(32usize, 24u8) as u32) }
    }
    #[inline]
    pub fn set_InstanceContributionToHitGroupIndex(&mut self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            self._bitfield_1.set(32usize, 24u8, val as u64)
        }
    }
    #[inline]
    pub unsafe fn InstanceContributionToHitGroupIndex_raw(this: *const Self) -> u32 {
        unsafe {
            ::std::mem::transmute(<__BindgenBitfieldUnit<[u8; 8usize]>>::raw_get(
                ::std::ptr::addr_of!((*this)._bitfield_1),
                32usize,
                24u8,
            ) as u32)
        }
    }
    #[inline]
    pub unsafe fn set_InstanceContributionToHitGroupIndex_raw(this: *mut Self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            <__BindgenBitfieldUnit<[u8; 8usize]>>::raw_set(
                ::std::ptr::addr_of_mut!((*this)._bitfield_1),
                32usize,
                24u8,
                val as u64,
            )
        }
    }
    #[inline]
    pub fn Flags(&self) -> u32 {
        unsafe { ::std::mem::transmute(self._bitfield_1.get(56usize, 8u8) as u32) }
    }
    #[inline]
    pub fn set_Flags(&mut self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            self._bitfield_1.set(56usize, 8u8, val as u64)
        }
    }
    #[inline]
    pub unsafe fn Flags_raw(this: *const Self) -> u32 {
        unsafe {
            ::std::mem::transmute(<__BindgenBitfieldUnit<[u8; 8usize]>>::raw_get(
                ::std::ptr::addr_of!((*this)._bitfield_1),
                56usize,
                8u8,
            ) as u32)
        }
    }
    #[inline]
    pub unsafe fn set_Flags_raw(this: *mut Self, val: u32) {
        unsafe {
            let val: u32 = ::std::mem::transmute(val);
            <__BindgenBitfieldUnit<[u8; 8usize]>>::raw_set(
                ::std::ptr::addr_of_mut!((*this)._bitfield_1),
                56usize,
                8u8,
                val as u64,
            )
        }
    }
    #[inline]
    pub fn new_bitfield_1(
        InstanceID: u32,
        InstanceMask: u32,
        InstanceContributionToHitGroupIndex: u32,
        Flags: u32,
    ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
        let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
        __bindgen_bitfield_unit.set(0usize, 24u8, {
            let InstanceID: u32 = unsafe { ::std::mem::transmute(InstanceID) };
            InstanceID as u64
        });
        __bindgen_bitfield_unit.set(24usize, 8u8, {
            let InstanceMask: u32 = unsafe { ::std::mem::transmute(InstanceMask) };
            InstanceMask as u64
        });
        __bindgen_bitfield_unit.set(32usize, 24u8, {
            let InstanceContributionToHitGroupIndex: u32 =
                unsafe { ::std::mem::transmute(InstanceContributionToHitGroupIndex) };
            InstanceContributionToHitGroupIndex as u64
        });
        __bindgen_bitfield_unit.set(56usize, 8u8, {
            let Flags: u32 = unsafe { ::std::mem::transmute(Flags) };
            Flags as u64
        });
        __bindgen_bitfield_unit
    }
}
pub const kIRRayDispatchIndirectionKernelName: &[u8; 18] = b"RaygenIndirection\0";
pub const kIRRayDispatchArgumentsBindPoint: u64 = 3;
#[repr(u32)]
#[non_exhaustive]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum IRRuntimeResourceType {
    SRV = 0,
    UAV = 1,
    CBV = 2,
    SMP = 3,
    Count = 4,
}
impl IRRuntimePrimitiveType {
    pub const _1ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _2ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _3ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _4ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _5ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _6ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _7ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _8ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _9ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _10ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _11ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _12ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _13ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _14ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _15ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _16ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _17ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _18ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _19ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _20ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _21ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _22ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _23ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _24ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _25ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _26ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _27ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _28ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _29ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _30ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _31ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
impl IRRuntimePrimitiveType {
    pub const _32ControlPointPatchlist: IRRuntimePrimitiveType = IRRuntimePrimitiveType::Triangle;
}
#[repr(u32)]
#[non_exhaustive]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum IRRuntimePrimitiveType {
    Point = 0,
    Line = 1,
    LineStrip = 2,
    Triangle = 3,
    TriangleStrip = 4,
    LineWithAdj = 5,
    TriangleWithAdj = 6,
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRRuntimeGeometryPipelineConfig {
    pub gsVertexSizeInBytes: u32,
    pub gsMaxInputPrimitivesPerMeshThreadgroup: u32,
}
#[repr(u32)]
#[non_exhaustive]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum IRRuntimeTessellatorOutputPrimitive {
    Undefined = 0,
    Point = 1,
    Line = 2,
    TriangleCW = 3,
    TriangleCCW = 4,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct IRRuntimeTessellationPipelineConfig {
    pub outputPrimitiveType: IRRuntimeTessellatorOutputPrimitive,
    pub vsOutputSizeInBytes: u32,
    pub gsMaxInputPrimitivesPerMeshThreadgroup: u32,
    pub hsMaxPatchesPerObjectThreadgroup: u32,
    pub hsInputControlPointCount: u32,
    pub hsMaxObjectThreadsPerThreadgroup: u32,
    pub hsMaxTessellationFactor: f32,
    pub gsInstanceCount: u32,
}
impl Default for IRRuntimeTessellationPipelineConfig {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRRuntimeVertexBuffer {
    pub addr: u64,
    pub length: u32,
    pub stride: u32,
}
pub type IRRuntimeVertexBuffers = [IRRuntimeVertexBuffer; 31usize];
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRRuntimeDrawArgument {
    pub vertexCountPerInstance: uint,
    pub instanceCount: uint,
    pub startVertexLocation: uint,
    pub startInstanceLocation: uint,
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRRuntimeDrawIndexedArgument {
    pub indexCountPerInstance: uint,
    pub instanceCount: uint,
    pub startIndexLocation: uint,
    pub baseVertexLocation: ::std::os::raw::c_int,
    pub startInstanceLocation: uint,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub struct IRRuntimeDrawParams {
    pub u_1: IRRuntimeDrawParams_u,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union IRRuntimeDrawParams_u {
    pub draw: IRRuntimeDrawArgument,
    pub drawIndexed: IRRuntimeDrawIndexedArgument,
}
impl Default for IRRuntimeDrawParams_u {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
impl Default for IRRuntimeDrawParams {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct IRRuntimeDrawInfo {
    pub indexType: u16,
    pub primitiveTopology: u8,
    pub threadsPerPatch: u8,
    pub maxInputPrimitivesPerMeshThreadgroup: u16,
    pub objectThreadgroupVertexStride: u16,
    pub meshThreadgroupPrimitiveStride: u16,
    pub gsInstanceCount: u16,
    pub patchesPerObjectThreadgroup: u16,
    pub inputControlPointsPerPatch: u16,
    pub indexBuffer: u64,
}
pub const kIRArgumentBufferBindPoint: u64 = 2;
pub const kIRArgumentBufferHullDomainBindPoint: u64 = 3;
pub const kIRDescriptorHeapBindPoint: u64 = 0;
pub const kIRSamplerHeapBindPoint: u64 = 1;
pub const kIRArgumentBufferDrawArgumentsBindPoint: u64 = 4;
pub const kIRArgumentBufferUniformsBindPoint: u64 = 5;
pub const kIRVertexBufferBindPoint: u64 = 6;
pub const kIRStageInAttributeStartIndex: u64 = 11;
pub const kIRIndirectTriangleIntersectionFunctionName: &[u8; 51] =
    b"irconverter.wrapper.intersection.function.triangle\0";
pub const kIRIndirectProceduralIntersectionFunctionName: &[u8; 53] =
    b"irconverter.wrapper.intersection.function.procedural\0";
pub const kIRTrianglePassthroughGeometryShader: &[u8; 47] =
    b"irconverter_domain_shader_triangle_passthrough\0";
pub const kIRLinePassthroughGeometryShader: &[u8; 43] =
    b"irconverter_domain_shader_line_passthrough\0";
pub const kIRPointPassthroughGeometryShader: &[u8; 44] =
    b"irconverter_domain_shader_point_passthrough\0";
pub const kIRNonIndexedDraw: u16 = 0;
pub const kIRFunctionGroupRayGeneration: &[u8; 7] = b"rayGen\0";
pub const kIRFunctionGroupClosestHit: &[u8; 11] = b"closestHit\0";
pub const kIRFunctionGroupMiss: &[u8; 5] = b"miss\0";
pub const kIRBufSizeOffset: u64 = 0;
pub const kIRBufSizeMask: u64 = 4294967295;
pub const kIRTexViewOffset: u64 = 32;
pub const kIRTexViewMask: u64 = 255;
pub const kIRTypedBufferOffset: u64 = 63;