From 65e24308babb2ed4f33fb6f1d7b531df676bd70d Mon Sep 17 00:00:00 2001 From: HampusM Date: Fri, 17 Jul 2026 03:06:04 +0200 Subject: refactor(engine): change Color struct into a enum --- engine/src/lighting.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'engine/src/lighting.rs') diff --git a/engine/src/lighting.rs b/engine/src/lighting.rs index f085b17..abe3d56 100644 --- a/engine/src/lighting.rs +++ b/engine/src/lighting.rs @@ -1,5 +1,5 @@ use crate::builder; -use crate::color::Color; +use crate::color::{Color, Rgb}; use crate::data_types::vector::Vec3; use crate::ecs::{Component, Sole}; use crate::reflection::Reflection; @@ -33,8 +33,8 @@ impl Default for PointLight { Self { local_position: Vec3::default(), - diffuse: Color { red: 0.5, green: 0.5, blue: 0.5 }, - specular: Color { red: 1.0, green: 1.0, blue: 1.0 }, + diffuse: Color::Rgb(Rgb { r: 0.5, g: 0.5, b: 0.5 }), + specular: Color::Rgb(Rgb::::white()), attenuation_params: AttenuationParams::default(), } } -- cgit v1.2.3-18-g5258