mirror of
https://github.com/cage-kiosk/cage.git
synced 2026-03-09 05:34:27 -04:00
Refactor surface damaging and rendering code
This is based on code from Sway, which is also MIT licensed hence compatible. This makes the surface damaging and rendering code easier to follow and makes it easier to import future changes to Sway as well.
This commit is contained in:
parent
bfd7d605b8
commit
2db815aa23
10 changed files with 408 additions and 243 deletions
11
util.h
Normal file
11
util.h
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
#ifndef CG_UTIL_H
|
||||
#define CG_UTIL_H
|
||||
|
||||
#include <wlr/types/wlr_box.h>
|
||||
|
||||
/** Apply scale to a width or height. */
|
||||
int scale_length(int length, int offset, float scale);
|
||||
|
||||
void scale_box(struct wlr_box *box, float scale);
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue