Renamed the Rgb struct to Color

This commit is contained in:
vextrixes committed 2026-06-06 16:07:34 +02:00
1 parent 856a7965b9
commit c04f184e8b
4 files changed
+29 -29

No files matched your search

+12
View File
@@ -0,0 +1,12 @@
#[derive(Default)]
pub struct Color {
pub red: u8,
pub green: u8,
pub blue: u8,
}
impl Color {
pub fn to_array(self) -> [u8; 3] {
[self.red, self.green, self.blue]
}
}