encase

Trait ShaderSize

Source
pub trait ShaderSize: ShaderType {
    const SHADER_SIZE: NonZeroU64 = _;
}
Expand description

Trait implemented for all WGSL fixed-footprint types

Provided Associated Constants§

Source

const SHADER_SIZE: NonZeroU64 = _

Represents WGSL Size (equivalent to ShaderType::min_size)

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl ShaderSize for Option<NonZeroI32>

Source§

impl ShaderSize for Option<NonZeroU32>

Source§

impl ShaderSize for f32

Source§

impl ShaderSize for i32

Source§

impl ShaderSize for u32

Source§

impl ShaderSize for Mat3
where f32: ShaderSize,

Source§

impl ShaderSize for Mat2
where f32: ShaderSize,

Source§

impl ShaderSize for Mat4
where f32: ShaderSize,

Source§

impl ShaderSize for Vec4
where f32: ShaderSize,

Source§

impl ShaderSize for Vec2
where f32: ShaderSize,

Source§

impl ShaderSize for Vec3
where f32: ShaderSize,

Source§

impl ShaderSize for IVec2
where i32: ShaderSize,

Source§

impl ShaderSize for IVec3
where i32: ShaderSize,

Source§

impl ShaderSize for IVec4
where i32: ShaderSize,

Source§

impl ShaderSize for UVec2
where u32: ShaderSize,

Source§

impl ShaderSize for UVec3
where u32: ShaderSize,

Source§

impl ShaderSize for UVec4
where u32: ShaderSize,

Source§

impl ShaderSize for Wrapping<i32>

Source§

impl ShaderSize for Wrapping<u32>

Source§

impl ShaderSize for AtomicI32

Source§

impl ShaderSize for AtomicU32

Source§

impl<T> ShaderSize for Cow<'_, T>
where T: ShaderSize + ?Sized + ToOwned<Owned = T>,

Source§

const SHADER_SIZE: NonZeroU64 = T::SHADER_SIZE

Source§

impl<T> ShaderSize for &T
where T: ShaderSize + ?Sized,

Source§

const SHADER_SIZE: NonZeroU64 = T::SHADER_SIZE

Source§

impl<T> ShaderSize for &mut T
where T: ShaderSize + ?Sized,

Source§

const SHADER_SIZE: NonZeroU64 = T::SHADER_SIZE

Source§

impl<T> ShaderSize for Box<T>
where T: ShaderSize + ?Sized,

Source§

const SHADER_SIZE: NonZeroU64 = T::SHADER_SIZE

Source§

impl<T> ShaderSize for Rc<T>
where T: ShaderSize + ?Sized,

Source§

const SHADER_SIZE: NonZeroU64 = T::SHADER_SIZE

Source§

impl<T> ShaderSize for Arc<T>
where T: ShaderSize + ?Sized,

Source§

const SHADER_SIZE: NonZeroU64 = T::SHADER_SIZE

Source§

impl<T> ShaderSize for Cell<T>
where T: ShaderSize + ?Sized + Copy,

Source§

const SHADER_SIZE: NonZeroU64 = T::SHADER_SIZE

Source§

impl<T: ShaderSize, const N: usize> ShaderSize for [T; N]

Implementors§