gemini_engine/view3d/display_mode/mod.rs
1pub mod lighting;
2use lighting::Light;
3
4/// `DisplayMode` determines how the [`Viewport`](super::Viewport) renders our 3D objects. This is the Gemini equivalent of Blender's Viewport Shading options
5#[derive(Debug, Clone, PartialEq)]
6pub enum DisplayMode {
7 /// Renders the edges of the meshes, without filling in the shapes. You can choose whether you want to render with backface culling using the [`backface_culling`](DisplayMode::Wireframe::backface_culling) enum parameter
8 Wireframe {
9 /// Whether or not to enable backface culling (parts of the mesh with faces that are not facing towards the viewport will be removed)
10 backface_culling: bool,
11 },
12 /// Renders the full, unshaded faces of all the meshes.
13 Solid,
14 /// Renders with faces' `text_char`s replaced with other characters to emulate light, based on a passed list of [`Light`]s
15 Illuminated {
16 /// The collection of lights used to illuminate the scene
17 lights: Vec<Light>,
18 },
19}