diff options
author | 2024-05-02 15:21:22 +0200 | |
---|---|---|
committer | 2024-05-02 17:28:28 +0200 | |
commit | a57313b23ecb9843856ca0ea08635b6121fcb2cb (patch) | |
tree | 42a88a4e42031ae99ae87aeb92fea85ab590b01e /wgpu/src/layer.rs | |
parent | 09a6bcfffc24f5abdc8709403bab7ae1e01563f1 (diff) | |
download | iced-a57313b23ecb9843856ca0ea08635b6121fcb2cb.tar.gz iced-a57313b23ecb9843856ca0ea08635b6121fcb2cb.tar.bz2 iced-a57313b23ecb9843856ca0ea08635b6121fcb2cb.zip |
Simplify image rotation API and its internals
Diffstat (limited to 'wgpu/src/layer.rs')
-rw-r--r-- | wgpu/src/layer.rs | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/wgpu/src/layer.rs b/wgpu/src/layer.rs index 648ec476..e0242c59 100644 --- a/wgpu/src/layer.rs +++ b/wgpu/src/layer.rs @@ -1,5 +1,5 @@ use crate::core::{ - renderer, Background, Color, Point, Rectangle, Size, Transformation, + renderer, Background, Color, Point, Radians, Rectangle, Transformation, }; use crate::graphics; use crate::graphics::color; @@ -118,15 +118,13 @@ impl Layer { filter_method: crate::core::image::FilterMethod, bounds: Rectangle, transformation: Transformation, - rotation: f32, - scale: Size, + rotation: Radians, ) { let image = Image::Raster { handle, filter_method, bounds: bounds * transformation, rotation, - scale, }; self.images.push(image); @@ -138,15 +136,13 @@ impl Layer { color: Option<Color>, bounds: Rectangle, transformation: Transformation, - rotation: f32, - scale: Size, + rotation: Radians, ) { let svg = Image::Vector { handle, color, bounds: bounds * transformation, rotation, - scale, }; self.images.push(svg); |