pub struct ComputePipelineDescriptor(/* private fields */);Implementations§
Source§impl ComputePipelineDescriptor
impl ComputePipelineDescriptor
Sourcepub fn alloc() -> Option<Self>
pub fn alloc() -> Option<Self>
Allocate a new compute pipeline descriptor.
C++ equivalent: static ComputePipelineDescriptor* alloc()
Sourcepub fn init(self) -> Option<Self>
pub fn init(self) -> Option<Self>
Initialize the descriptor.
C++ equivalent: ComputePipelineDescriptor* init()
Sourcepub fn set_label(&self, label: &str)
pub fn set_label(&self, label: &str)
Set the label.
C++ equivalent: void setLabel(const NS::String* label)
Sourcepub fn compute_function(&self) -> Option<Function>
pub fn compute_function(&self) -> Option<Function>
Get the compute function.
C++ equivalent: Function* computeFunction() const
Sourcepub fn set_compute_function(&self, function: Option<&Function>)
pub fn set_compute_function(&self, function: Option<&Function>)
Set the compute function.
C++ equivalent: void setComputeFunction(const MTL::Function* computeFunction)
Sourcepub fn max_total_threads_per_threadgroup(&self) -> UInteger
pub fn max_total_threads_per_threadgroup(&self) -> UInteger
Get the maximum total threads per threadgroup.
C++ equivalent: NS::UInteger maxTotalThreadsPerThreadgroup() const
Sourcepub fn set_max_total_threads_per_threadgroup(&self, count: UInteger)
pub fn set_max_total_threads_per_threadgroup(&self, count: UInteger)
Set the maximum total threads per threadgroup.
C++ equivalent: void setMaxTotalThreadsPerThreadgroup(NS::UInteger maxTotalThreadsPerThreadgroup)
Sourcepub fn required_threads_per_threadgroup(&self) -> Size
pub fn required_threads_per_threadgroup(&self) -> Size
Get the required threads per threadgroup.
C++ equivalent: Size requiredThreadsPerThreadgroup() const
Sourcepub fn set_required_threads_per_threadgroup(&self, size: Size)
pub fn set_required_threads_per_threadgroup(&self, size: Size)
Set the required threads per threadgroup.
C++ equivalent: void setRequiredThreadsPerThreadgroup(MTL::Size requiredThreadsPerThreadgroup)
Sourcepub fn thread_group_size_is_multiple_of_thread_execution_width(&self) -> bool
pub fn thread_group_size_is_multiple_of_thread_execution_width(&self) -> bool
Check if thread group size is multiple of thread execution width.
C++ equivalent: bool threadGroupSizeIsMultipleOfThreadExecutionWidth() const
Sourcepub fn set_thread_group_size_is_multiple_of_thread_execution_width(
&self,
value: bool,
)
pub fn set_thread_group_size_is_multiple_of_thread_execution_width( &self, value: bool, )
Set thread group size is multiple of thread execution width.
C++ equivalent: void setThreadGroupSizeIsMultipleOfThreadExecutionWidth(bool threadGroupSizeIsMultipleOfThreadExecutionWidth)
Sourcepub fn max_call_stack_depth(&self) -> UInteger
pub fn max_call_stack_depth(&self) -> UInteger
Get the maximum call stack depth.
C++ equivalent: NS::UInteger maxCallStackDepth() const
Sourcepub fn set_max_call_stack_depth(&self, depth: UInteger)
pub fn set_max_call_stack_depth(&self, depth: UInteger)
Set the maximum call stack depth.
C++ equivalent: void setMaxCallStackDepth(NS::UInteger maxCallStackDepth)
Sourcepub fn support_indirect_command_buffers(&self) -> bool
pub fn support_indirect_command_buffers(&self) -> bool
Check if the pipeline supports indirect command buffers.
C++ equivalent: bool supportIndirectCommandBuffers() const
Sourcepub fn set_support_indirect_command_buffers(&self, support: bool)
pub fn set_support_indirect_command_buffers(&self, support: bool)
Set indirect command buffer support.
C++ equivalent: void setSupportIndirectCommandBuffers(bool supportIndirectCommandBuffers)
Sourcepub fn support_adding_binary_functions(&self) -> bool
pub fn support_adding_binary_functions(&self) -> bool
Check if support adding binary functions is enabled.
C++ equivalent: bool supportAddingBinaryFunctions() const
Sourcepub fn set_support_adding_binary_functions(&self, support: bool)
pub fn set_support_adding_binary_functions(&self, support: bool)
Set support adding binary functions.
C++ equivalent: void setSupportAddingBinaryFunctions(bool supportAddingBinaryFunctions)
Sourcepub fn shader_validation(&self) -> ShaderValidation
pub fn shader_validation(&self) -> ShaderValidation
Get the shader validation mode.
C++ equivalent: ShaderValidation shaderValidation() const
Sourcepub fn set_shader_validation(&self, validation: ShaderValidation)
pub fn set_shader_validation(&self, validation: ShaderValidation)
Set the shader validation mode.
C++ equivalent: void setShaderValidation(MTL::ShaderValidation shaderValidation)
Sourcepub fn buffers(&self) -> Option<PipelineBufferDescriptorArray>
pub fn buffers(&self) -> Option<PipelineBufferDescriptorArray>
Get the buffer descriptors array.
C++ equivalent: PipelineBufferDescriptorArray* buffers() const
Sourcepub fn stage_input_descriptor_raw(&self) -> *mut c_void
pub fn stage_input_descriptor_raw(&self) -> *mut c_void
Get the stage input descriptor.
C++ equivalent: StageInputOutputDescriptor* stageInputDescriptor() const
Sourcepub unsafe fn set_stage_input_descriptor_raw(&self, descriptor: *const c_void)
pub unsafe fn set_stage_input_descriptor_raw(&self, descriptor: *const c_void)
Set the stage input descriptor.
C++ equivalent: void setStageInputDescriptor(const StageInputOutputDescriptor*)
§Safety
The pointer must be a valid StageInputOutputDescriptor object.
Sourcepub fn linked_functions(&self) -> Option<LinkedFunctions>
pub fn linked_functions(&self) -> Option<LinkedFunctions>
Get the linked functions.
C++ equivalent: LinkedFunctions* linkedFunctions() const
Sourcepub fn set_linked_functions(&self, functions: Option<&LinkedFunctions>)
pub fn set_linked_functions(&self, functions: Option<&LinkedFunctions>)
Set the linked functions.
C++ equivalent: void setLinkedFunctions(const LinkedFunctions*)
Sourcepub fn binary_archives_raw(&self) -> *mut c_void
pub fn binary_archives_raw(&self) -> *mut c_void
Get the binary archives (raw NSArray pointer).
C++ equivalent: NS::Array* binaryArchives() const
Sourcepub unsafe fn set_binary_archives_raw(&self, archives: *const c_void)
pub unsafe fn set_binary_archives_raw(&self, archives: *const c_void)
Set the binary archives.
C++ equivalent: void setBinaryArchives(const NS::Array*)
§Safety
The pointer must be a valid NSArray of BinaryArchive objects.
Sourcepub fn preloaded_libraries_raw(&self) -> *mut c_void
pub fn preloaded_libraries_raw(&self) -> *mut c_void
Get the preloaded libraries (raw NSArray pointer).
C++ equivalent: NS::Array* preloadedLibraries() const
Sourcepub unsafe fn set_preloaded_libraries_raw(&self, libraries: *const c_void)
pub unsafe fn set_preloaded_libraries_raw(&self, libraries: *const c_void)
Set the preloaded libraries.
C++ equivalent: void setPreloadedLibraries(const NS::Array*)
§Safety
The pointer must be a valid NSArray of DynamicLibrary objects.
Sourcepub fn insert_libraries_raw(&self) -> *mut c_void
pub fn insert_libraries_raw(&self) -> *mut c_void
Get the insert libraries (raw NSArray pointer).
C++ equivalent: NS::Array* insertLibraries() const
Sourcepub unsafe fn set_insert_libraries_raw(&self, libraries: *const c_void)
pub unsafe fn set_insert_libraries_raw(&self, libraries: *const c_void)
Set the insert libraries.
C++ equivalent: void setInsertLibraries(const NS::Array*)
§Safety
The pointer must be a valid NSArray of DynamicLibrary objects.