summaryrefslogtreecommitdiffstats
path: root/renderer
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-05-02 15:21:22 +0200
committerLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-05-02 17:28:28 +0200
commita57313b23ecb9843856ca0ea08635b6121fcb2cb (patch)
tree42a88a4e42031ae99ae87aeb92fea85ab590b01e /renderer
parent09a6bcfffc24f5abdc8709403bab7ae1e01563f1 (diff)
downloadiced-a57313b23ecb9843856ca0ea08635b6121fcb2cb.tar.gz
iced-a57313b23ecb9843856ca0ea08635b6121fcb2cb.tar.bz2
iced-a57313b23ecb9843856ca0ea08635b6121fcb2cb.zip
Simplify image rotation API and its internals
Diffstat (limited to 'renderer')
-rw-r--r--renderer/src/fallback.rs12
1 files changed, 5 insertions, 7 deletions
diff --git a/renderer/src/fallback.rs b/renderer/src/fallback.rs
index 37e6ac43..a077031b 100644
--- a/renderer/src/fallback.rs
+++ b/renderer/src/fallback.rs
@@ -3,7 +3,7 @@ use crate::core::image;
use crate::core::renderer;
use crate::core::svg;
use crate::core::{
- self, Background, Color, Point, Rectangle, Size, Transformation,
+ self, Background, Color, Point, Radians, Rectangle, Size, Transformation,
};
use crate::graphics;
use crate::graphics::compositor;
@@ -154,13 +154,12 @@ where
handle: Self::Handle,
filter_method: image::FilterMethod,
bounds: Rectangle,
- rotation: f32,
- scale: Size,
+ rotation: Radians,
) {
delegate!(
self,
renderer,
- renderer.draw_image(handle, filter_method, bounds, rotation, scale)
+ renderer.draw_image(handle, filter_method, bounds, rotation)
);
}
}
@@ -179,13 +178,12 @@ where
handle: svg::Handle,
color: Option<Color>,
bounds: Rectangle,
- rotation: f32,
- scale: Size,
+ rotation: Radians,
) {
delegate!(
self,
renderer,
- renderer.draw_svg(handle, color, bounds, rotation, scale)
+ renderer.draw_svg(handle, color, bounds, rotation)
);
}
}