arts_1014/lib.rs
1//! # Art
2//!
3//! A library for modeling artistic concepts.
4
5pub use self::kinds::{PrimaryColor, SecondaryColor};
6pub use self::utils::mix;
7pub mod kinds {
8 /// The primary colors according to the RYB color model.
9 pub enum PrimaryColor {
10 Red,
11 Yellow,
12 Blue,
13 }
14 /// The secondary colors according to the RYB color model.
15 pub enum SecondaryColor {
16 Orange,
17 Green,
18 Purple,
19 }
20 }
21pub mod utils {
22 use crate::kinds::*;
23 /// Combines two primary colors in equal amounts to create
24 /// a secondary color.
25 pub fn mix(c1: PrimaryColor, c2: PrimaryColor) {
26 // --snip--
27 }
28}