diff options
author | 2024-05-03 13:25:58 +0200 | |
---|---|---|
committer | 2024-05-03 13:25:58 +0200 | |
commit | fa9e1d96ea1924b51749b775ea0e67e69bc8a305 (patch) | |
tree | 20cb13d6e3074569a15a16c8b0d261b1875a2045 /wgpu/src/layer.rs | |
parent | 38cf87cb45484c7e52ddf775fb3abd7edbecc652 (diff) | |
download | iced-fa9e1d96ea1924b51749b775ea0e67e69bc8a305.tar.gz iced-fa9e1d96ea1924b51749b775ea0e67e69bc8a305.tar.bz2 iced-fa9e1d96ea1924b51749b775ea0e67e69bc8a305.zip |
Introduce dynamic `opacity` support for `Image` and `Svg`
Diffstat (limited to 'wgpu/src/layer.rs')
-rw-r--r-- | wgpu/src/layer.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/wgpu/src/layer.rs b/wgpu/src/layer.rs index e0242c59..9551311d 100644 --- a/wgpu/src/layer.rs +++ b/wgpu/src/layer.rs @@ -119,12 +119,14 @@ impl Layer { bounds: Rectangle, transformation: Transformation, rotation: Radians, + opacity: f32, ) { let image = Image::Raster { handle, filter_method, bounds: bounds * transformation, rotation, + opacity, }; self.images.push(image); @@ -137,12 +139,14 @@ impl Layer { bounds: Rectangle, transformation: Transformation, rotation: Radians, + opacity: f32, ) { let svg = Image::Vector { handle, color, bounds: bounds * transformation, rotation, + opacity, }; self.images.push(svg); |