pub enum ResourceKind {
ConstantBuffer {
layout: BufferLayout,
},
Texture {
dim: TextureDim,
arrayed: bool,
multisampled: bool,
sample: SampleType,
},
Sampler {
comparison: bool,
},
Buffer(BufferKind),
Storage {
target: StorageTarget,
access: Access,
},
AccelerationStructure,
}Expand description
What a resource is.
Variants§
ConstantBuffer
Constants by explicit byte offset. A program whose source states no names (a stripped one) has none here; the consumer names fields by offset. The constants and size of one constant buffer.
Fields
§
layout: BufferLayoutThe buffer’s size and the constants in it.
Texture
A texture read by sampling or by load.
Sampler
A sampler state object.
Buffer(BufferKind)
A buffer the program reads.
Storage
An image or buffer the program may write. A resource the program may write: an image or a buffer, and what it may do to it.
Fields
§
target: StorageTargetWhether it is an image or a buffer, and which kind.
AccelerationStructure
A ray tracing acceleration structure the program traces rays into.
Trait Implementations§
Source§impl Clone for ResourceKind
impl Clone for ResourceKind
Source§impl Debug for ResourceKind
impl Debug for ResourceKind
impl Eq for ResourceKind
Source§impl Hash for ResourceKind
impl Hash for ResourceKind
Source§impl Ord for ResourceKind
impl Ord for ResourceKind
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for ResourceKind
impl PartialEq for ResourceKind
Source§impl PartialOrd for ResourceKind
impl PartialOrd for ResourceKind
Source§impl Serialize for ResourceKind
impl Serialize for ResourceKind
impl StructuralPartialEq for ResourceKind
Auto Trait Implementations§
impl Freeze for ResourceKind
impl RefUnwindSafe for ResourceKind
impl Send for ResourceKind
impl Sync for ResourceKind
impl Unpin for ResourceKind
impl UnsafeUnpin for ResourceKind
impl UnwindSafe for ResourceKind
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