aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--graphics/VectorRenderer.cpp2
-rw-r--r--graphics/VectorRenderer.h25
2 files changed, 12 insertions, 15 deletions
diff --git a/graphics/VectorRenderer.cpp b/graphics/VectorRenderer.cpp
index 9dc2fa6ce6..e2b187a58c 100644
--- a/graphics/VectorRenderer.cpp
+++ b/graphics/VectorRenderer.cpp
@@ -210,7 +210,6 @@ drawLine(int x1, int y1, int x2, int y2) {
if (dy == 0) { // horizontal lines
// these can be filled really fast with a single memset.
- // TODO: Platform specific ASM in set_to, would make this thing fly
colorFill(ptr, ptr + dx + 1, (PixelType)_fgColor);
} else if (dx == 0) { // vertical lines
@@ -605,7 +604,6 @@ drawRoundedSquareShadow(int x1, int y1, int r, int w, int h, int blur) {
int f, ddF_x, ddF_y;
int x, y, px, py;
int pitch = Base::surfacePitch();
- int sw = 0, sp = 0, hp = h * pitch;
int alpha = 102;
x1 += blur;
diff --git a/graphics/VectorRenderer.h b/graphics/VectorRenderer.h
index 4609d51739..a4ef4b81b1 100644
--- a/graphics/VectorRenderer.h
+++ b/graphics/VectorRenderer.h
@@ -499,19 +499,18 @@ protected:
virtual inline void colorFill(PixelType *first, PixelType *last, PixelType color) {
register PixelType *ptr = first;
register int count = (last - first);
- {
- register int n = (count + 7) / 8;
- switch (count % 8) {
- case 0: do { *ptr++ = color;
- case 7: *ptr++ = color;
- case 6: *ptr++ = color;
- case 5: *ptr++ = color;
- case 4: *ptr++ = color;
- case 3: *ptr++ = color;
- case 2: *ptr++ = color;
- case 1: *ptr++ = color;
- } while (--n > 0);
- }
+ register int n = (count + 7) >> 3;
+ switch (count % 8) {
+ case 0: do {
+ *ptr++ = color;
+ case 7: *ptr++ = color;
+ case 6: *ptr++ = color;
+ case 5: *ptr++ = color;
+ case 4: *ptr++ = color;
+ case 3: *ptr++ = color;
+ case 2: *ptr++ = color;
+ case 1: *ptr++ = color;
+ } while (--n > 0);
}
}