all repos — mgba @ 388dbc08513eaabfa99bce533f10df32e8627e23

mGBA Game Boy Advance Emulator

Fix window values where start >= max being broken
Jeffrey Pfau jeffrey@endrift.com
Sun, 22 Sep 2013 15:14:14 -0700
commit

388dbc08513eaabfa99bce533f10df32e8627e23

parent

2a6e7db6932a4c78dfe8a955041593ab8570f5af

1 files changed, 0 insertions(+), 12 deletions(-)

jump to
M src/gba/renderers/video-software.csrc/gba/renderers/video-software.c

@@ -251,17 +251,11 @@ softwareRenderer->win0H.packed = value;

if (softwareRenderer->win0H.start > softwareRenderer->win0H.end || softwareRenderer->win0H.end > VIDEO_HORIZONTAL_PIXELS) { softwareRenderer->win0H.end = VIDEO_HORIZONTAL_PIXELS; } - if (softwareRenderer->win0H.start >= VIDEO_HORIZONTAL_PIXELS) { - softwareRenderer->win0H.start = 0; - } break; case REG_WIN1H: softwareRenderer->win1H.packed = value; if (softwareRenderer->win1H.start > softwareRenderer->win1H.end || softwareRenderer->win1H.end > VIDEO_HORIZONTAL_PIXELS) { softwareRenderer->win1H.end = VIDEO_HORIZONTAL_PIXELS; - } - if (softwareRenderer->win1H.start >= VIDEO_HORIZONTAL_PIXELS) { - softwareRenderer->win1H.start = 0; } break; case REG_WIN0V:

@@ -269,17 +263,11 @@ softwareRenderer->win0V.packed = value;

if (softwareRenderer->win0V.start > softwareRenderer->win0V.end || softwareRenderer->win0V.end > VIDEO_HORIZONTAL_PIXELS) { softwareRenderer->win0V.end = VIDEO_VERTICAL_PIXELS; } - if (softwareRenderer->win0V.start >= VIDEO_VERTICAL_PIXELS) { - softwareRenderer->win0V.start = 0; - } break; case REG_WIN1V: softwareRenderer->win1V.packed = value; if (softwareRenderer->win1V.start > softwareRenderer->win1V.end || softwareRenderer->win1V.end > VIDEO_HORIZONTAL_PIXELS) { softwareRenderer->win1V.end = VIDEO_VERTICAL_PIXELS; - } - if (softwareRenderer->win1V.start >= VIDEO_VERTICAL_PIXELS) { - softwareRenderer->win1V.start = 0; } break; case REG_WININ: