Struct shades::FragmentShaderEnv [−][src]
Fragment shader environment.
This type contains everything you have access to when writing a fragment shader.
Fields
frag_coord: Expr<V4<f32>>
Fragment coordinate in the framebuffer.
front_facing: Expr<bool>
Whether the fragment is front-facing.
clip_distance: Expr<[f32]>
Clip distances to user planes.
This is an array giving the clip distances to each of the user clip planes.
cull_distance: Expr<[f32]>
Cull distances to user planes.
This is an array giving the cull distances to each of the user clip planes.
point_coord: Expr<V2<f32>>
Contains the 2D coordinates of a fragment within a point primitive.
primitive_id: Expr<i32>
ID of the primitive being currently rendered.
sample_id: Expr<i32>
ID of the sample being currently rendered.
sample_position: Expr<V2<f32>>
Sample 2D coordinates.
sample_mask_in: Expr<i32>
Contains the computed sample coverage mask for the current fragment.
layer: Expr<i32>
Layer the fragment will be written to.
viewport_index: Expr<i32>
Viewport index the fragment will be written to.
helper_invocation: Expr<bool>
Indicates whether we are in a helper invocation of a fragment shader.
frag_depth: Var<f32>
Depth of the fragment.
sample_mask: Var<[i32]>
Sample mask of the fragment.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for FragmentShaderEnv
[src]
impl Send for FragmentShaderEnv
[src]
impl Sync for FragmentShaderEnv
[src]
impl Unpin for FragmentShaderEnv
[src]
impl UnwindSafe for FragmentShaderEnv
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,