Only in raw-0.1.0.hires/: aw Only in raw-0.1.0.hires/: bank.d Only in raw-0.1.0.hires/: bank.o Only in raw-0.1.0.hires/: engine.d Only in raw-0.1.0.hires/: engine.o Only in raw-0.1.0.hires/: file.d Only in raw-0.1.0.hires/: file.o Only in raw-0.1.0.hires/: logic.d Only in raw-0.1.0.hires/: logic.o Only in raw-0.1.0.hires/: main.d Only in raw-0.1.0.hires/: main.o Only in raw-0.1.0.hires/: raw Only in raw-0.1.0.hires/: resource.d Only in raw-0.1.0.hires/: resource.o diff -u -r raw-0.1.0/sdlstub.cpp raw-0.1.0.hires/sdlstub.cpp --- raw-0.1.0/sdlstub.cpp 2004-04-21 20:29:56.000000000 +0200 +++ raw-0.1.0.hires/sdlstub.cpp 2004-04-30 14:51:29.000000000 +0200 @@ -19,14 +19,14 @@ #include #include "systemstub.h" #include "util.h" - +#include "video.h" struct SDLStub : SystemStub { typedef void (SDLStub::*ScaleProc)(uint16 *dst, uint16 dstPitch, const uint16 *src, uint16 srcPitch, uint16 w, uint16 h); enum { - SCREEN_W = 320, - SCREEN_H = 200 + SCREEN_W = 320*SCALE, + SCREEN_H = 200*SCALE }; struct Scaler { @@ -83,7 +83,7 @@ error("Unable to allocate offscreen buffer"); } _fullscreen = false; - _scaler = 1; + _scaler = 0; prepareGfxMode(); } Only in raw-0.1.0.hires/: sdlstub.cpp~ Only in raw-0.1.0.hires/: sdlstub.d Only in raw-0.1.0.hires/: sdlstub.o Only in raw-0.1.0.hires/: serializer.d Only in raw-0.1.0.hires/: serializer.o Only in raw-0.1.0.hires/: staticres.d Only in raw-0.1.0.hires/: staticres.o Only in raw-0.1.0.hires/: util.d Only in raw-0.1.0.hires/: util.o diff -u -r raw-0.1.0/video.cpp raw-0.1.0.hires/video.cpp --- raw-0.1.0/video.cpp 2004-04-21 20:27:44.000000000 +0200 +++ raw-0.1.0.hires/video.cpp 2004-04-30 14:54:52.000000000 +0200 @@ -21,16 +21,15 @@ #include "serializer.h" #include "systemstub.h" - void Polygon::init(const uint8 *p, uint16 zoom) { - bbw = (*p++) * zoom / 64; - bbh = (*p++) * zoom / 64; + bbw = (*p++) * zoom / 64 * SCALE; + bbh = (*p++) * zoom / 64 * SCALE; numPoints = *p++; assert((numPoints & 1) == 0 && numPoints < MAX_POINTS); for (int i = 0; i < numPoints; ++i) { Point *pt = &points[i]; - pt->x = (*p++) * zoom / 64; - pt->y = (*p++) * zoom / 64; + pt->x = (*p++) * zoom / 64 * SCALE; + pt->y = (*p++) * zoom / 64 * SCALE; } } @@ -57,13 +56,15 @@ _pData.pc = dataBuf + offset; } -void Video::drawShape(uint8 color, uint16 zoom, const Point &pt) { +void Video::drawShape(uint8 color, uint16 zoom, Point pt) { uint8 i = _pData.fetchByte(); if (i >= 0xC0) { if (color & 0x80) { color = i & 0x3F; } _pg.init(_pData.pc, zoom); + pt.x *= SCALE; + pt.y *= SCALE; fillPolygon(color, zoom, pt); } else { i &= 0x3F; @@ -88,7 +89,7 @@ int16 y1 = pt.y - _pg.bbh / 2; int16 y2 = pt.y + _pg.bbh / 2; - if (x1 > 319 || x2 < 0 || y1 > 199 || y2 < 0) + if (x1 > 319*SCALE || x2 < 0 || y1 > 199*SCALE || y2 < 0) return; _hliney = y1; @@ -138,16 +139,16 @@ if (_hliney >= 0) { x1 = cpt1 >> 16; x2 = cpt2 >> 16; - if (x1 <= 319 && x2 >= 0) { + if (x1 <= (319*SCALE) && x2 >= 0) { if (x1 < 0) x1 = 0; - if (x2 > 319) x2 = 319; + if (x2 > (319*SCALE)) x2 = (319*SCALE); (this->*pdl)(x1, x2, color); } } cpt1 += step1; cpt2 += step2; ++_hliney; - if (_hliney > 199) return; + if (_hliney > (199*SCALE)) return; } } } @@ -203,7 +204,7 @@ void Video::drawChar(uint8 c, uint16 x, uint16 y, uint8 color, uint8 *buf) { if (x <= 39 && y <= 192) { const uint8 *ft = _font + (c - 0x20) * 8; - uint8 *p = buf + x * 4 + y * 160; + uint8 *p = buf + x * 4 + y * (160*SCALE); for (int j = 0; j < 8; ++j) { uint8 ch = *(ft + j); for (int i = 0; i < 4; ++i) { @@ -222,15 +223,15 @@ ch <<= 1; *(p + i) = (b & cmask) | colb; } - p += 160; + p += (160*SCALE); } } } void Video::drawPoint(uint8 color, int16 x, int16 y) { debug(DBG_VIDEO, "drawPoint(%d, %d, %d)", color, x, y); - if (x >= 0 && x <= 319 && y >= 0 && y <= 199) { - uint16 off = y * 160 + x / 2; + if (x >= 0 && x <= (319*SCALE) && y >= 0 && y <= (199*SCALE)) { + uint16 off = y * (160*SCALE) + x / 2; uint8 cmasko, cmaskn; if (x & 1) { @@ -258,7 +259,7 @@ debug(DBG_VIDEO, "drawLineT(%d, %d, %d)", x1, x2, color); int16 xmax = MAX(x1, x2); int16 xmin = MIN(x1, x2); - uint8 *p = _curPagePtr1 + _hliney * 160 + xmin / 2; + uint8 *p = _curPagePtr1 + _hliney * (160*SCALE) + xmin / 2; uint16 w = xmax / 2 - xmin / 2 + 1; uint8 cmaske = 0; @@ -290,7 +291,7 @@ debug(DBG_VIDEO, "drawLineN(%d, %d, %d)", x1, x2, color); int16 xmax = MAX(x1, x2); int16 xmin = MIN(x1, x2); - uint8 *p = _curPagePtr1 + _hliney * 160 + xmin / 2; + uint8 *p = _curPagePtr1 + _hliney * (160*SCALE) + xmin / 2; uint16 w = xmax / 2 - xmin / 2 + 1; uint8 cmaske = 0; @@ -322,7 +323,7 @@ debug(DBG_VIDEO, "drawLineP(%d, %d, %d)", x1, x2, color); int16 xmax = MAX(x1, x2); int16 xmin = MIN(x1, x2); - uint16 off = _hliney * 160 + xmin / 2; + uint16 off = _hliney * (160*SCALE) + xmin / 2; uint8 *p = _curPagePtr1 + off; uint8 *q = _pagePtrs[0] + off; @@ -397,16 +398,16 @@ } else { uint8 *p = getPagePtr(src & 3); uint8 *q = getPagePtr(dst); - if (p != q && vscroll >= -199 && vscroll <= 199) { + if (p != q && vscroll >= -(199*SCALE) && vscroll <= (199*SCALE)) { uint16 h = 200; if (vscroll < 0) { h += vscroll; - p += -vscroll * 160; + p += -vscroll * (160*SCALE); } else { h -= vscroll; - q += vscroll * 160; + q += vscroll * (160*SCALE); } - memcpy(q, p, h * 160); + memcpy(q, p, h * (160*SCALE)); } } } @@ -474,7 +475,7 @@ changePal(_newPal); _newPal = 0xFF; } - _stub->copyRect(0, 0, 320, 200, _curPagePtr2, 160); + _stub->copyRect(0, 0, 320*SCALE, 200*SCALE, _curPagePtr2, (160*SCALE)); } void Video::saveOrLoad(Serializer &ser) { Only in raw-0.1.0.hires/: video.cpp~ Only in raw-0.1.0.hires/: video.d diff -u -r raw-0.1.0/video.h raw-0.1.0.hires/video.h --- raw-0.1.0/video.h 2004-04-19 19:58:38.000000000 +0200 +++ raw-0.1.0.hires/video.h 2004-04-30 14:55:14.000000000 +0200 @@ -21,6 +21,8 @@ #include "intern.h" +#define SCALE 3 + struct StrEntry { uint16 id; const char *str; @@ -46,7 +48,7 @@ typedef void (Video::*drawLine)(int16 x1, int16 x2, uint8 col); enum { - VID_PAGE_SIZE = 320 * 200 / 2 + VID_PAGE_SIZE = (320 * SCALE) * (200 * SCALE) / 2 }; static const uint8 _font[]; @@ -69,7 +71,7 @@ void init(); void setDataBuffer(uint8 *dataBuf, uint16 offset); - void drawShape(uint8 color, uint16 zoom, const Point &pt); + void drawShape(uint8 color, uint16 zoom, Point pt); void fillPolygon(uint16 color, uint16 zoom, const Point &pt); void drawShapeParts(uint16 zoom, const Point &pt); int32 calcStep(const Point &p1, const Point &p2, uint16 &dy); Only in raw-0.1.0.hires/: video.h~ Only in raw-0.1.0.hires/: video.o