librashader_common

Trait GetSize

source
pub trait GetSize<C: Num> {
    type Error;

    // Required method
    fn size(&self) -> Result<Size<C>, Self::Error>;
}
Expand description

Trait for surface or texture objects that can fetch size.

Required Associated Types§

Required Methods§

source

fn size(&self) -> Result<Size<C>, Self::Error>

Fetch the size of the object

Implementors§

source§

impl<T: GetSize<u32>> GetSize<f32> for T

source§

type Error = <T as GetSize<u32>>::Error