Simplify image rotation API and its internals
This commit is contained in:
parent
09a6bcfffc
commit
a57313b23e
23 changed files with 219 additions and 225 deletions
|
|
@ -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)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue