- for (i = 0; i < simplerect->outline_pixels; ++i) {
-
- if (simplerect->outline_what & 0x1) {
- if (begin == simplerect->bbox_ulx) {
- PAINT_VERT(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, begin + i, sy, ey);
- }
- }
-
- if (simplerect->outline_what & 0x2) {
- if (end == (simplerect->bbox_lrx - 1)) {
- PAINT_VERT(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, end - i, sy, ey + 1);
- }
- }
-
- if (simplerect->outline_what & 0x4) {
- PAINT_HORIZ(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, begin, end, sy+i);
- }
-
- if (simplerect->outline_what & 0x8) {
- PAINT_HORIZ(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, begin, end + 1, ey-i);
- }
- }
+ if (simplerect->outline_a) {
+ for (i = 0; i < (int) simplerect->outline_pixels; ++i) {
+
+ if (simplerect->outline_what & 0x1) {
+ if (begin == simplerect->bbox_ulx) {
+ PAINT_VERTA(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, simplerect->outline_a, begin + i, sy, ey);
+ }
+ }
+
+ if (simplerect->outline_what & 0x2) {
+ if (end == (simplerect->bbox_lrx - 1)) {
+ PAINT_VERTA(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, simplerect->outline_a, end - i, sy, ey + 1);
+ }
+ }
+
+ if (simplerect->outline_what & 0x4) {
+ PAINT_HORIZA(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, simplerect->outline_a, begin, end, sy+i);
+ }
+
+ if (simplerect->outline_what & 0x8) {
+ PAINT_HORIZA(buf, simplerect->outline_r, simplerect->outline_g, simplerect->outline_b, simplerect->outline_a, begin, end + 1, ey-i);
+ }
+ }
+ }