util/box: introduce wlr_fbox_transform()

A floating-point version of wlr_box_transform().
This commit is contained in:
Kirill Primak 2021-08-23 23:32:43 +03:00 committed by Simon Ser
parent f2f3df9fb1
commit 664307f968
2 changed files with 53 additions and 0 deletions

View file

@ -78,4 +78,9 @@ bool wlr_box_empty(const struct wlr_box *box);
void wlr_box_transform(struct wlr_box *dest, const struct wlr_box *box,
enum wl_output_transform transform, int width, int height);
/**
* Transforms a floating-point box inside a (0, 0, width, height) box.
*/
void wlr_fbox_transform(struct wlr_fbox *dest, const struct wlr_fbox *box,
enum wl_output_transform transform, double width, double height);
#endif