pub struct ResourceViewDesc {
pub format: CUresourceViewFormat,
pub width: usize,
pub height: usize,
pub depth: usize,
pub first_mip_level: u32,
pub last_mip_level: u32,
pub first_layer: u32,
pub last_layer: u32,
}Expand description
Optional resource-view descriptor for texture objects.
Allows re-interpretation of the array format, or restriction to a sub-range of mipmap levels and array layers.
Fields§
§format: CUresourceViewFormatReinterpretation format (use None for the array’s native format).
width: usizeView width in elements.
height: usizeView height in elements.
depth: usizeView depth in elements.
first_mip_level: u32First mipmap level in the view.
last_mip_level: u32Last mipmap level in the view.
first_layer: u32First array layer.
last_layer: u32Last array layer.
Implementations§
Source§impl ResourceViewDesc
impl ResourceViewDesc
Sourcepub fn as_raw(&self) -> CUDA_RESOURCE_VIEW_DESC
pub fn as_raw(&self) -> CUDA_RESOURCE_VIEW_DESC
Convert to the raw CUDA_RESOURCE_VIEW_DESC.
Trait Implementations§
Source§impl Clone for ResourceViewDesc
impl Clone for ResourceViewDesc
Source§fn clone(&self) -> ResourceViewDesc
fn clone(&self) -> ResourceViewDesc
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ResourceViewDesc
Auto Trait Implementations§
impl Freeze for ResourceViewDesc
impl RefUnwindSafe for ResourceViewDesc
impl Send for ResourceViewDesc
impl Sync for ResourceViewDesc
impl Unpin for ResourceViewDesc
impl UnsafeUnpin for ResourceViewDesc
impl UnwindSafe for ResourceViewDesc
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