pub struct AccelerationStructureMotionBoundingBoxGeometryDescriptor(/* private fields */);Expand description
Descriptor for motion bounding box geometry in acceleration structures.
C++ equivalent: MTL::AccelerationStructureMotionBoundingBoxGeometryDescriptor
Implementations§
Source§impl AccelerationStructureMotionBoundingBoxGeometryDescriptor
impl AccelerationStructureMotionBoundingBoxGeometryDescriptor
Sourcepub fn new() -> Option<Self>
pub fn new() -> Option<Self>
Create a new motion bounding box geometry descriptor.
C++ equivalent: static AccelerationStructureMotionBoundingBoxGeometryDescriptor* alloc()->init()
Sourcepub unsafe fn from_raw(ptr: *mut c_void) -> Option<Self>
pub unsafe fn from_raw(ptr: *mut c_void) -> Option<Self>
Create from a raw pointer.
§Safety
The pointer must be a valid Metal motion bounding box geometry descriptor.
Sourcepub fn allow_duplicate_intersection_function_invocation(&self) -> bool
pub fn allow_duplicate_intersection_function_invocation(&self) -> bool
Get whether duplicate intersection function invocation is allowed.
Sourcepub fn set_allow_duplicate_intersection_function_invocation(&self, allow: bool)
pub fn set_allow_duplicate_intersection_function_invocation(&self, allow: bool)
Set whether duplicate intersection function invocation is allowed.
Sourcepub fn intersection_function_table_offset(&self) -> UInteger
pub fn intersection_function_table_offset(&self) -> UInteger
Get the intersection function table offset.
Sourcepub fn set_intersection_function_table_offset(&self, offset: UInteger)
pub fn set_intersection_function_table_offset(&self, offset: UInteger)
Set the intersection function table offset.
Sourcepub fn set_opaque(&self, opaque: bool)
pub fn set_opaque(&self, opaque: bool)
Set whether geometry is opaque.
Sourcepub fn primitive_data_buffer(&self) -> Option<Buffer>
pub fn primitive_data_buffer(&self) -> Option<Buffer>
Get the primitive data buffer.
Sourcepub fn set_primitive_data_buffer(&self, buffer: Option<&Buffer>)
pub fn set_primitive_data_buffer(&self, buffer: Option<&Buffer>)
Set the primitive data buffer.
Sourcepub fn primitive_data_buffer_offset(&self) -> UInteger
pub fn primitive_data_buffer_offset(&self) -> UInteger
Get the primitive data buffer offset.
Sourcepub fn set_primitive_data_buffer_offset(&self, offset: UInteger)
pub fn set_primitive_data_buffer_offset(&self, offset: UInteger)
Set the primitive data buffer offset.
Sourcepub fn primitive_data_element_size(&self) -> UInteger
pub fn primitive_data_element_size(&self) -> UInteger
Get the primitive data element size.
Sourcepub fn set_primitive_data_element_size(&self, size: UInteger)
pub fn set_primitive_data_element_size(&self, size: UInteger)
Set the primitive data element size.
Sourcepub fn primitive_data_stride(&self) -> UInteger
pub fn primitive_data_stride(&self) -> UInteger
Get the primitive data stride.
Sourcepub fn set_primitive_data_stride(&self, stride: UInteger)
pub fn set_primitive_data_stride(&self, stride: UInteger)
Set the primitive data stride.
Sourcepub fn bounding_box_count(&self) -> UInteger
pub fn bounding_box_count(&self) -> UInteger
Get the bounding box count.
C++ equivalent: NS::UInteger boundingBoxCount() const
Sourcepub fn set_bounding_box_count(&self, count: UInteger)
pub fn set_bounding_box_count(&self, count: UInteger)
Set the bounding box count.
C++ equivalent: void setBoundingBoxCount(NS::UInteger)
Sourcepub fn bounding_box_stride(&self) -> UInteger
pub fn bounding_box_stride(&self) -> UInteger
Get the bounding box stride.
C++ equivalent: NS::UInteger boundingBoxStride() const
Sourcepub fn set_bounding_box_stride(&self, stride: UInteger)
pub fn set_bounding_box_stride(&self, stride: UInteger)
Set the bounding box stride.
C++ equivalent: void setBoundingBoxStride(NS::UInteger)
Sourcepub fn bounding_box_buffers_ptr(&self) -> *const c_void
pub fn bounding_box_buffers_ptr(&self) -> *const c_void
Get the bounding box buffers as a raw NS::Array pointer.
C++ equivalent: NS::Array* boundingBoxBuffers() const
§Safety
The returned pointer is an NS::Array containing MotionKeyframeData objects. The caller must manage the memory appropriately.
Sourcepub unsafe fn set_bounding_box_buffers_ptr(
&self,
bounding_box_buffers: *const c_void,
)
pub unsafe fn set_bounding_box_buffers_ptr( &self, bounding_box_buffers: *const c_void, )
Set the bounding box buffers from a raw NS::Array pointer.
C++ equivalent: void setBoundingBoxBuffers(const NS::Array*)
§Safety
The bounding_box_buffers pointer must be a valid NS::Array or null.