Trait ocl::traits::WorkDims

source ·
pub trait WorkDims {
    // Required methods
    fn dim_count(&self) -> u32;
    fn to_work_size(&self) -> Option<[usize; 3]>;
    fn to_work_offset(&self) -> Option<[usize; 3]>;
}
Expand description

Types which have properties describing the amount of work to be done in multiple dimensions.

Required Methods§

source

fn dim_count(&self) -> u32

Returns the number of dimensions defined.

source

fn to_work_size(&self) -> Option<[usize; 3]>

Returns an array representing the amount of work to be done by a kernel.

Unspecified dimensions (for example, the 3rd dimension in a 1-dimensional work size) are set equal to 1.

source

fn to_work_offset(&self) -> Option<[usize; 3]>

Returns an array representing the offset of a work item or memory location.

Unspecified dimensions (for example, the 3rd dimension in a 1-dimensional work size) are set equal to 0.

Implementors§