Add Image rotation support

Co-authored-by: DKolter <68352124+DKolter@users.noreply.github.com>
This commit is contained in:
Héctor Ramón Jiménez 2024-05-02 13:15:17 +02:00
parent aae8e4f5cf
commit 09a6bcfffc
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
19 changed files with 374 additions and 84 deletions

View file

@ -154,11 +154,13 @@ where
handle: Self::Handle,
filter_method: image::FilterMethod,
bounds: Rectangle,
rotation: f32,
scale: Size,
) {
delegate!(
self,
renderer,
renderer.draw_image(handle, filter_method, bounds)
renderer.draw_image(handle, filter_method, bounds, rotation, scale)
);
}
}
@ -177,8 +179,14 @@ where
handle: svg::Handle,
color: Option<Color>,
bounds: Rectangle,
rotation: f32,
scale: Size,
) {
delegate!(self, renderer, renderer.draw_svg(handle, color, bounds));
delegate!(
self,
renderer,
renderer.draw_svg(handle, color, bounds, rotation, scale)
);
}
}