Files
wgpu-renderer/Source/Render/Pipeline/FrontFace.rs
2021-11-23 20:09:05 -03:00

23 lines
631 B
Rust

use serde::{Deserialize, Serialize};
/// Winding order which classifies the "front" face.
#[repr(C)]
#[derive(Copy, Clone, Debug, Hash, Eq, PartialEq, Serialize, Deserialize)]
pub enum FrontFace {
/// Triangles with vertices in counter clockwise order are considered the front face.
///
/// This is the default with right handed coordinate spaces.
Ccw = 0,
/// Triangles with vertices in clockwise order are considered the front face.
///
/// This is the default with left handed coordinate spaces.
Cw = 1,
}
impl Default for FrontFace {
fn default() -> Self {
FrontFace::Ccw
}
}