use crate::prelude::*;
#[derive(Clone, Copy, Debug, TypeUlid)]
#[ulid = "01GNR2978NRN7PH5XWBXP3KMD7"]
#[repr(C)]
pub struct Camera {
pub height: f32,
pub active: bool,
pub viewport: Option<Viewport>,
}
#[derive(Clone, Copy, Debug)]
#[repr(C)]
pub struct Viewport {
pub position: UVec2,
pub size: UVec2,
pub depth_min: f32,
pub depth_max: f32,
}
impl Default for Camera {
fn default() -> Self {
Self {
height: 400.0,
active: true,
viewport: None,
}
}
}
#[derive(Deref, DerefMut, Clone, Copy, TypeUlid, Default)]
#[ulid = "01GP4XRQYRPQNX4J22E513975M"]
pub struct ClearColor(pub Color);