Struct luminance::depth_stencil::StencilOperations
source · [−]pub struct StencilOperations {
pub depth_passes_stencil_fails: StencilOp,
pub depth_fails_stencil_passes: StencilOp,
pub depth_stencil_pass: StencilOp,
}
Expand description
The stencil operations are executed whenever a stencil test passes.
Fields
depth_passes_stencil_fails: StencilOp
Action to take when the depth test passes but not the stencil test.
depth_fails_stencil_passes: StencilOp
Action to take when the stencil test passes but not the depth test.
depth_stencil_pass: StencilOp
Action to take when both the depth and stencil tests pass.
Implementations
sourceimpl StencilOperations
impl StencilOperations
sourcepub fn new() -> Self
pub fn new() -> Self
Create Default
StencilOperations
.
sourcepub fn on_depth_passes_stencil_fails(self, op: StencilOp) -> Self
pub fn on_depth_passes_stencil_fails(self, op: StencilOp) -> Self
Set the StencilOp
to do when the depth test passes but stencil test fails:
sourcepub fn on_depth_fails_stencil_passes(self, op: StencilOp) -> Self
pub fn on_depth_fails_stencil_passes(self, op: StencilOp) -> Self
Set the StencilOp
to do when the depth test fails but stencil test passes:
sourcepub fn on_depth_stencil_pass(self, op: StencilOp) -> Self
pub fn on_depth_stencil_pass(self, op: StencilOp) -> Self
Set the StencilOp
to do when both the depth test and stencil test pass:
Trait Implementations
sourceimpl Clone for StencilOperations
impl Clone for StencilOperations
sourcefn clone(&self) -> StencilOperations
fn clone(&self) -> StencilOperations
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for StencilOperations
impl Debug for StencilOperations
sourceimpl Default for StencilOperations
impl Default for StencilOperations
Default implementation for StencilOperations
:
- when depth test passes but stencil fail:
StencilOp::Keep
. - when depth test fails but stencil passes:
StencilOp::Keep
. - when both depth test and stencil test pass:
StencilOp::Keep
.
sourceimpl PartialEq<StencilOperations> for StencilOperations
impl PartialEq<StencilOperations> for StencilOperations
sourcefn eq(&self, other: &StencilOperations) -> bool
fn eq(&self, other: &StencilOperations) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &StencilOperations) -> bool
fn ne(&self, other: &StencilOperations) -> bool
This method tests for !=
.
impl Copy for StencilOperations
impl Eq for StencilOperations
impl StructuralEq for StencilOperations
impl StructuralPartialEq for StencilOperations
Auto Trait Implementations
impl RefUnwindSafe for StencilOperations
impl Send for StencilOperations
impl Sync for StencilOperations
impl Unpin for StencilOperations
impl UnwindSafe for StencilOperations
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
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
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more