[−][src]Trait glsl_layout::AsStd140
Structure to transform data from rust's structure to the raw data ready to upload to UBO.
Users should prefer to use derive(AsStd140)
instead of implementing this manually.
Associated Types
type Align: Copy + Default
ZST that enforces alignment required for this type.
type Std140: Std140 + ?Sized
Type that contain same data with memory layout matching glsl's layout(std140)
.
Required methods
Loading content...Implementations on Foreign Types
impl<T> AsStd140 for [Element<T>] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>]
fn std140(&self) -> [Element<T::Std140>] where
[Element<T::Std140>]: Sized,
[src]
[Element<T::Std140>]: Sized,
Get aligned data from structure.
impl<T> AsStd140 for [T; 0] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 0]
fn std140(&self) -> [Element<T::Std140>; 0]
[src]
impl<T> AsStd140 for [Element<T>; 0] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 0]
fn std140(&self) -> [Element<T::Std140>; 0]
[src]
impl<T> AsStd140 for [T; 1] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 1]
fn std140(&self) -> [Element<T::Std140>; 1]
[src]
impl<T> AsStd140 for [Element<T>; 1] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 1]
fn std140(&self) -> [Element<T::Std140>; 1]
[src]
impl<T> AsStd140 for [T; 2] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 2]
fn std140(&self) -> [Element<T::Std140>; 2]
[src]
impl<T> AsStd140 for [Element<T>; 2] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 2]
fn std140(&self) -> [Element<T::Std140>; 2]
[src]
impl<T> AsStd140 for [T; 3] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 3]
fn std140(&self) -> [Element<T::Std140>; 3]
[src]
impl<T> AsStd140 for [Element<T>; 3] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 3]
fn std140(&self) -> [Element<T::Std140>; 3]
[src]
impl<T> AsStd140 for [T; 4] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 4]
fn std140(&self) -> [Element<T::Std140>; 4]
[src]
impl<T> AsStd140 for [Element<T>; 4] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 4]
fn std140(&self) -> [Element<T::Std140>; 4]
[src]
impl<T> AsStd140 for [T; 5] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 5]
fn std140(&self) -> [Element<T::Std140>; 5]
[src]
impl<T> AsStd140 for [Element<T>; 5] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 5]
fn std140(&self) -> [Element<T::Std140>; 5]
[src]
impl<T> AsStd140 for [T; 6] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 6]
fn std140(&self) -> [Element<T::Std140>; 6]
[src]
impl<T> AsStd140 for [Element<T>; 6] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 6]
fn std140(&self) -> [Element<T::Std140>; 6]
[src]
impl<T> AsStd140 for [T; 7] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 7]
fn std140(&self) -> [Element<T::Std140>; 7]
[src]
impl<T> AsStd140 for [Element<T>; 7] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 7]
fn std140(&self) -> [Element<T::Std140>; 7]
[src]
impl<T> AsStd140 for [T; 8] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 8]
fn std140(&self) -> [Element<T::Std140>; 8]
[src]
impl<T> AsStd140 for [Element<T>; 8] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 8]
fn std140(&self) -> [Element<T::Std140>; 8]
[src]
impl<T> AsStd140 for [T; 9] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 9]
fn std140(&self) -> [Element<T::Std140>; 9]
[src]
impl<T> AsStd140 for [Element<T>; 9] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 9]
fn std140(&self) -> [Element<T::Std140>; 9]
[src]
impl<T> AsStd140 for [T; 10] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 10]
fn std140(&self) -> [Element<T::Std140>; 10]
[src]
impl<T> AsStd140 for [Element<T>; 10] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 10]
fn std140(&self) -> [Element<T::Std140>; 10]
[src]
impl<T> AsStd140 for [T; 11] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 11]
fn std140(&self) -> [Element<T::Std140>; 11]
[src]
impl<T> AsStd140 for [Element<T>; 11] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 11]
fn std140(&self) -> [Element<T::Std140>; 11]
[src]
impl<T> AsStd140 for [T; 12] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 12]
fn std140(&self) -> [Element<T::Std140>; 12]
[src]
impl<T> AsStd140 for [Element<T>; 12] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 12]
fn std140(&self) -> [Element<T::Std140>; 12]
[src]
impl<T> AsStd140 for [T; 13] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 13]
fn std140(&self) -> [Element<T::Std140>; 13]
[src]
impl<T> AsStd140 for [Element<T>; 13] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 13]
fn std140(&self) -> [Element<T::Std140>; 13]
[src]
impl<T> AsStd140 for [T; 14] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 14]
fn std140(&self) -> [Element<T::Std140>; 14]
[src]
impl<T> AsStd140 for [Element<T>; 14] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 14]
fn std140(&self) -> [Element<T::Std140>; 14]
[src]
impl<T> AsStd140 for [T; 15] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 15]
fn std140(&self) -> [Element<T::Std140>; 15]
[src]
impl<T> AsStd140 for [Element<T>; 15] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 15]
fn std140(&self) -> [Element<T::Std140>; 15]
[src]
impl<T> AsStd140 for [T; 16] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 16]
fn std140(&self) -> [Element<T::Std140>; 16]
[src]
impl<T> AsStd140 for [Element<T>; 16] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 16]
fn std140(&self) -> [Element<T::Std140>; 16]
[src]
impl<T> AsStd140 for [T; 17] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 17]
fn std140(&self) -> [Element<T::Std140>; 17]
[src]
impl<T> AsStd140 for [Element<T>; 17] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 17]
fn std140(&self) -> [Element<T::Std140>; 17]
[src]
impl<T> AsStd140 for [T; 18] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 18]
fn std140(&self) -> [Element<T::Std140>; 18]
[src]
impl<T> AsStd140 for [Element<T>; 18] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 18]
fn std140(&self) -> [Element<T::Std140>; 18]
[src]
impl<T> AsStd140 for [T; 19] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 19]
fn std140(&self) -> [Element<T::Std140>; 19]
[src]
impl<T> AsStd140 for [Element<T>; 19] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 19]
fn std140(&self) -> [Element<T::Std140>; 19]
[src]
impl<T> AsStd140 for [T; 20] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 20]
fn std140(&self) -> [Element<T::Std140>; 20]
[src]
impl<T> AsStd140 for [Element<T>; 20] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 20]
fn std140(&self) -> [Element<T::Std140>; 20]
[src]
impl<T> AsStd140 for [T; 21] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 21]
fn std140(&self) -> [Element<T::Std140>; 21]
[src]
impl<T> AsStd140 for [Element<T>; 21] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 21]
fn std140(&self) -> [Element<T::Std140>; 21]
[src]
impl<T> AsStd140 for [T; 22] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 22]
fn std140(&self) -> [Element<T::Std140>; 22]
[src]
impl<T> AsStd140 for [Element<T>; 22] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 22]
fn std140(&self) -> [Element<T::Std140>; 22]
[src]
impl<T> AsStd140 for [T; 23] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 23]
fn std140(&self) -> [Element<T::Std140>; 23]
[src]
impl<T> AsStd140 for [Element<T>; 23] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 23]
fn std140(&self) -> [Element<T::Std140>; 23]
[src]
impl<T> AsStd140 for [T; 24] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 24]
fn std140(&self) -> [Element<T::Std140>; 24]
[src]
impl<T> AsStd140 for [Element<T>; 24] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 24]
fn std140(&self) -> [Element<T::Std140>; 24]
[src]
impl<T> AsStd140 for [T; 25] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 25]
fn std140(&self) -> [Element<T::Std140>; 25]
[src]
impl<T> AsStd140 for [Element<T>; 25] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 25]
fn std140(&self) -> [Element<T::Std140>; 25]
[src]
impl<T> AsStd140 for [T; 26] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 26]
fn std140(&self) -> [Element<T::Std140>; 26]
[src]
impl<T> AsStd140 for [Element<T>; 26] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 26]
fn std140(&self) -> [Element<T::Std140>; 26]
[src]
impl<T> AsStd140 for [T; 27] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 27]
fn std140(&self) -> [Element<T::Std140>; 27]
[src]
impl<T> AsStd140 for [Element<T>; 27] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 27]
fn std140(&self) -> [Element<T::Std140>; 27]
[src]
impl<T> AsStd140 for [T; 28] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 28]
fn std140(&self) -> [Element<T::Std140>; 28]
[src]
impl<T> AsStd140 for [Element<T>; 28] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 28]
fn std140(&self) -> [Element<T::Std140>; 28]
[src]
impl<T> AsStd140 for [T; 29] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 29]
fn std140(&self) -> [Element<T::Std140>; 29]
[src]
impl<T> AsStd140 for [Element<T>; 29] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 29]
fn std140(&self) -> [Element<T::Std140>; 29]
[src]
impl<T> AsStd140 for [T; 30] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 30]
fn std140(&self) -> [Element<T::Std140>; 30]
[src]
impl<T> AsStd140 for [Element<T>; 30] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 30]
fn std140(&self) -> [Element<T::Std140>; 30]
[src]
impl<T> AsStd140 for [T; 31] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 31]
fn std140(&self) -> [Element<T::Std140>; 31]
[src]
impl<T> AsStd140 for [Element<T>; 31] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 31]
fn std140(&self) -> [Element<T::Std140>; 31]
[src]
impl<T> AsStd140 for [T; 32] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,
type Align = Align16
type Std140 = [Element<T::Std140>; 32]
fn std140(&self) -> [Element<T::Std140>; 32]
[src]
impl<T> AsStd140 for [Element<T>; 32] where
T: AsStd140,
T::Std140: Sized,
[src]
T: AsStd140,
T::Std140: Sized,