Expand description
Viewport transformation.
Viewport transformation is part of the fixed-function Vertex Post-Processing pipeline.
The returning vertex positions (GLSL: gl_Position
) in clip space are transformed to
normalized device coordinates (NDC) by perspective division. Viewport transformation
further converts the NDC into framebuffer coordinates.
During the geometry a primitive will be assigned a viewport index (GLSL: gl_ViewportIndex
)
either automatically or manually. This index controls which viewport from the bounded
viewports will be selected for applying the transformation for the current primitive.
Fields
x: f32
Offset (x).
y: f32
Offset (y).
w: f32
Width.
h: f32
Height.
n: f64
f: f64
Auto Trait Implementations
impl RefUnwindSafe for Viewport
impl Send for Viewport
impl Sync for Viewport
impl Unpin for Viewport
impl UnwindSafe for Viewport
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more