diff options
author | 2023-05-19 03:32:21 +0200 | |
---|---|---|
committer | 2023-05-19 03:32:21 +0200 | |
commit | 4c1a082f0468a59099bbf8aa8991420a41234948 (patch) | |
tree | 42308071bc180f364c71cdc0bb0011235c01fe14 /wgpu | |
parent | 6551a0b2ab6c831dd1d3646ecf55180339275e22 (diff) | |
download | iced-4c1a082f0468a59099bbf8aa8991420a41234948.tar.gz iced-4c1a082f0468a59099bbf8aa8991420a41234948.tar.bz2 iced-4c1a082f0468a59099bbf8aa8991420a41234948.zip |
Remove `Builder` abstractions for gradients
Diffstat (limited to '')
-rw-r--r-- | wgpu/src/geometry.rs | 2 | ||||
-rw-r--r-- | wgpu/src/layer.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/wgpu/src/geometry.rs b/wgpu/src/geometry.rs index e26d9278..b8a75c33 100644 --- a/wgpu/src/geometry.rs +++ b/wgpu/src/geometry.rs @@ -631,7 +631,7 @@ fn pack_gradient(gradient: &Gradient) -> [f32; 44] { let mut pack: [f32; 44] = [0.0; 44]; let mut offsets: [f32; 8] = [2.0; 8]; - for (index, stop) in linear.color_stops.iter().enumerate() { + for (index, stop) in linear.stops.iter().enumerate() { let [r, g, b, a] = stop .map_or(crate::core::Color::default(), |s| s.color) .into_linear(); diff --git a/wgpu/src/layer.rs b/wgpu/src/layer.rs index b3ee4739..08c0004a 100644 --- a/wgpu/src/layer.rs +++ b/wgpu/src/layer.rs @@ -317,7 +317,7 @@ fn pack_gradient(gradient: &core::Gradient, bounds: Rectangle) -> [f32; 44] { core::Gradient::Linear(linear) => { let mut pack: [f32; 44] = [0.0; 44]; - for (index, stop) in linear.color_stops.iter().enumerate() { + for (index, stop) in linear.stops.iter().enumerate() { let [r, g, b, a] = stop.map_or(Color::default(), |s| s.color).into_linear(); |