graphics: render mouse using copying overlay, optimize copying

This commit is contained in:
2021-10-22 00:28:13 +08:00
parent 986b135403
commit a0c2b8d8fd
3 changed files with 127 additions and 26 deletions

View File

@ -8,3 +8,27 @@ static inline int intmin(int x, int y) {
static inline int intmax(int x, int y) {
return x > y ? x : y;
}
static inline int intmin3(int x, int y, int z) {
if (x < y)
if (x < z)
return x;
else
return z;
else if (y < z)
return y;
else
return z;
}
static inline int intmax3(int x, int y, int z) {
if (x > y)
if (x > z)
return x;
else
return z;
else if (y > z)
return y;
else
return z;
}