mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-03 14:40:02 +00:00
Fixed some problems in jrectexclude() when y1==ey1 or y2==ye2.
This commit is contained in:
parent
a4b55a980c
commit
dac67bb21c
@ -71,7 +71,8 @@ void jrectexclude(BITMAP *bmp, int x1, int y1, int x2, int y2,
|
|||||||
my2 = MIN(y2, ey2);
|
my2 = MIN(y2, ey2);
|
||||||
|
|
||||||
// top
|
// top
|
||||||
rectfill(bmp, x1, y1, x2, ey1-1, color);
|
if (y1 < ey1)
|
||||||
|
rectfill(bmp, x1, y1, x2, ey1-1, color);
|
||||||
|
|
||||||
// left
|
// left
|
||||||
if (x1 < ex1)
|
if (x1 < ex1)
|
||||||
@ -82,7 +83,8 @@ void jrectexclude(BITMAP *bmp, int x1, int y1, int x2, int y2,
|
|||||||
rectfill(bmp, ex2+1, my1, x2, my2, color);
|
rectfill(bmp, ex2+1, my1, x2, my2, color);
|
||||||
|
|
||||||
// bottom
|
// bottom
|
||||||
rectfill(bmp, x1, ey2+1, x2, y2, color);
|
if (y2 > ey2)
|
||||||
|
rectfill(bmp, x1, ey2+1, x2, y2, color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user