update pastel fade
This commit is contained in:
parent
c5ddb6fc4f
commit
f8148462d2
1 changed files with 3 additions and 2 deletions
|
@ -18,14 +18,15 @@ impl ColorGrid for PastelFade {
|
||||||
fn get(&self, p: &Vector2<f32>) -> Rgb<f32> {
|
fn get(&self, p: &Vector2<f32>) -> Rgb<f32> {
|
||||||
let inputs = self.inputs.read().unwrap().clone();
|
let inputs = self.inputs.read().unwrap().clone();
|
||||||
|
|
||||||
let i = ( inputs.t.as_millis() as f32 / (inputs.wheel as f32*inputs.cycle_len.as_millis() as f32) ) % 1.0;
|
let i = ( 5.0 + 0.7 * inputs.t.as_millis() as f32 / (16.0*inputs.cycle_len.as_millis() as f32) ) % 1.0;
|
||||||
|
|
||||||
Rgb::from_color(
|
Rgb::from_color(
|
||||||
&Hsv::<f32, Turns<f32>>::new(
|
&Hsv::<f32, Turns<f32>>::new(
|
||||||
Turns( i ),
|
Turns( i ),
|
||||||
0.5,
|
0.5,
|
||||||
1.0
|
0.8
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue