MTLIndirectComputeCommand

Trait MTLIndirectComputeCommand 

Source
pub unsafe trait MTLIndirectComputeCommand: NSObjectProtocol {
    // Provided methods
    fn setComputePipelineState(
        &self,
        pipeline_state: &ProtocolObject<dyn MTLComputePipelineState>,
    )
       where Self: Sized + Message { ... }
    unsafe fn setKernelBuffer_offset_atIndex(
        &self,
        buffer: &ProtocolObject<dyn MTLBuffer>,
        offset: NSUInteger,
        index: NSUInteger,
    )
       where Self: Sized + Message { ... }
    unsafe fn setKernelBuffer_offset_attributeStride_atIndex(
        &self,
        buffer: &ProtocolObject<dyn MTLBuffer>,
        offset: NSUInteger,
        stride: NSUInteger,
        index: NSUInteger,
    )
       where Self: Sized + Message { ... }
    fn concurrentDispatchThreadgroups_threadsPerThreadgroup(
        &self,
        threadgroups_per_grid: MTLSize,
        threads_per_threadgroup: MTLSize,
    )
       where Self: Sized + Message { ... }
    fn concurrentDispatchThreads_threadsPerThreadgroup(
        &self,
        threads_per_grid: MTLSize,
        threads_per_threadgroup: MTLSize,
    )
       where Self: Sized + Message { ... }
    fn setBarrier(&self)
       where Self: Sized + Message { ... }
    fn clearBarrier(&self)
       where Self: Sized + Message { ... }
    fn setImageblockWidth_height(&self, width: NSUInteger, height: NSUInteger)
       where Self: Sized + Message { ... }
    fn reset(&self)
       where Self: Sized + Message { ... }
    unsafe fn setThreadgroupMemoryLength_atIndex(
        &self,
        length: NSUInteger,
        index: NSUInteger,
    )
       where Self: Sized + Message { ... }
    fn setStageInRegion(&self, region: MTLRegion)
       where Self: Sized + Message { ... }
}
Available on crate feature MTLIndirectCommandEncoder only.
Expand description

Provided Methods§

Source

fn setComputePipelineState( &self, pipeline_state: &ProtocolObject<dyn MTLComputePipelineState>, )
where Self: Sized + Message,

Available on crate features MTLAllocation and MTLComputePipeline only.
Source

unsafe fn setKernelBuffer_offset_atIndex( &self, buffer: &ProtocolObject<dyn MTLBuffer>, offset: NSUInteger, index: NSUInteger, )
where Self: Sized + Message,

Available on crate features MTLAllocation and MTLBuffer and MTLResource only.
§Safety
  • buffer may need to be synchronized.
  • buffer may be unretained, you must ensure it is kept alive while in use.
  • buffer contents should be of the correct type.
  • offset might not be bounds-checked.
  • index might not be bounds-checked.
Source

unsafe fn setKernelBuffer_offset_attributeStride_atIndex( &self, buffer: &ProtocolObject<dyn MTLBuffer>, offset: NSUInteger, stride: NSUInteger, index: NSUInteger, )
where Self: Sized + Message,

Available on crate features MTLAllocation and MTLBuffer and MTLResource only.

sets kernel buffer at specified index with provided offset and stride. only call this when the buffer-index is part of the stageInputDescriptor and has set its stride to MTLBufferLayoutStrideDynamic

§Safety
  • buffer may need to be synchronized.
  • buffer may be unretained, you must ensure it is kept alive while in use.
  • buffer contents should be of the correct type.
  • offset might not be bounds-checked.
  • stride might not be bounds-checked.
  • index might not be bounds-checked.
Source

fn concurrentDispatchThreadgroups_threadsPerThreadgroup( &self, threadgroups_per_grid: MTLSize, threads_per_threadgroup: MTLSize, )
where Self: Sized + Message,

Available on crate feature MTLTypes only.
Source

fn concurrentDispatchThreads_threadsPerThreadgroup( &self, threads_per_grid: MTLSize, threads_per_threadgroup: MTLSize, )
where Self: Sized + Message,

Available on crate feature MTLTypes only.
Source

fn setBarrier(&self)
where Self: Sized + Message,

Source

fn clearBarrier(&self)
where Self: Sized + Message,

Source

fn setImageblockWidth_height(&self, width: NSUInteger, height: NSUInteger)
where Self: Sized + Message,

Source

fn reset(&self)
where Self: Sized + Message,

Source

unsafe fn setThreadgroupMemoryLength_atIndex( &self, length: NSUInteger, index: NSUInteger, )
where Self: Sized + Message,

§Safety

index might not be bounds-checked.

Source

fn setStageInRegion(&self, region: MTLRegion)
where Self: Sized + Message,

Available on crate feature MTLTypes only.

Trait Implementations§

Source§

impl ProtocolType for dyn MTLIndirectComputeCommand

Source§

const NAME: &'static str = "MTLIndirectComputeCommand"

The name of the Objective-C protocol that this type represents. Read more
Source§

fn protocol() -> Option<&'static AnyProtocol>

Get a reference to the Objective-C protocol object that this type represents. Read more
Source§

impl<T> ImplementedBy<T> for dyn MTLIndirectComputeCommand

Implementations on Foreign Types§

Source§

impl<T> MTLIndirectComputeCommand for ProtocolObject<T>

Implementors§