#[non_exhaustive]#[repr(i32)]pub enum CompareOp {
Never = 0,
Less = 1,
Equal = 2,
LessOrEqual = 3,
Greater = 4,
NotEqual = 5,
GreaterOrEqual = 6,
Always = 7,
}
Expand description
Specifies how two values should be compared to decide whether a test passes or fails.
Used for both depth testing and stencil testing.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Never = 0
The test never passes.
Less = 1
The test passes if value < reference_value
.
Equal = 2
The test passes if value == reference_value
.
LessOrEqual = 3
The test passes if value <= reference_value
.
Greater = 4
The test passes if value > reference_value
.
NotEqual = 5
The test passes if value != reference_value
.
GreaterOrEqual = 6
The test passes if value >= reference_value
.
Always = 7
The test always passes.
Trait Implementations§
source§impl PartialEq for CompareOp
impl PartialEq for CompareOp
impl Copy for CompareOp
impl Eq for CompareOp
impl StructuralEq for CompareOp
impl StructuralPartialEq for CompareOp
Auto Trait Implementations§
impl RefUnwindSafe for CompareOp
impl Send for CompareOp
impl Sync for CompareOp
impl Unpin for CompareOp
impl UnwindSafe for CompareOp
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more