pub enum ArrayFormat {
U8,
U16,
U32,
I8,
I16,
I32,
F16,
F32,
}Expand description
Element format shorthand for common single-channel arrays. Build a
multi-channel descriptor by passing a CUarray_format constant and a
channel count directly to Array::new.
Variants§
Implementations§
Source§impl ArrayFormat
impl ArrayFormat
Sourcepub fn bytes_per_channel(self) -> usize
pub fn bytes_per_channel(self) -> usize
Width of a single texel (one channel) in bytes.
Trait Implementations§
Source§impl Clone for ArrayFormat
impl Clone for ArrayFormat
Source§fn clone(&self) -> ArrayFormat
fn clone(&self) -> ArrayFormat
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ArrayFormat
impl Debug for ArrayFormat
Source§impl PartialEq for ArrayFormat
impl PartialEq for ArrayFormat
Source§fn eq(&self, other: &ArrayFormat) -> bool
fn eq(&self, other: &ArrayFormat) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for ArrayFormat
impl Eq for ArrayFormat
impl StructuralPartialEq for ArrayFormat
Auto Trait Implementations§
impl Freeze for ArrayFormat
impl RefUnwindSafe for ArrayFormat
impl Send for ArrayFormat
impl Sync for ArrayFormat
impl Unpin for ArrayFormat
impl UnsafeUnpin for ArrayFormat
impl UnwindSafe for ArrayFormat
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more