aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/gfx.h
diff options
context:
space:
mode:
authorTravis Howell2009-10-21 12:59:10 +0000
committerTravis Howell2009-10-21 12:59:10 +0000
commit746258f882b74cea1c5d5a34ef6c67e0669cdf09 (patch)
treed266519a68dd149709708c4b641d0fb0fa95015e /engines/scumm/gfx.h
parent1e8883dcccfd490ba8844bb46cc90d5437c6f3f1 (diff)
downloadscummvm-rg350-746258f882b74cea1c5d5a34ef6c67e0669cdf09.tar.gz
scummvm-rg350-746258f882b74cea1c5d5a34ef6c67e0669cdf09.tar.bz2
scummvm-rg350-746258f882b74cea1c5d5a34ef6c67e0669cdf09.zip
Add patch from Tobias, for graphic support (backgrounds/objects) in PCE version of Loom, with minor changes.
svn-id: r45304
Diffstat (limited to 'engines/scumm/gfx.h')
-rw-r--r--engines/scumm/gfx.h41
1 files changed, 41 insertions, 0 deletions
diff --git a/engines/scumm/gfx.h b/engines/scumm/gfx.h
index 0910d9bc59..34ba63164c 100644
--- a/engines/scumm/gfx.h
+++ b/engines/scumm/gfx.h
@@ -301,6 +301,47 @@ public:
virtual void roomChanged(byte *roomptr);
};
+class GdiPCEngine : public Gdi {
+protected:
+ struct {
+ uint16 nametable[4096], nametableObj[512];
+ byte colortable[4096], colortableObj[512];
+ byte attributes[64], attributesObj[64];
+ uint16 masktable[4096], masktableObj[512];
+ int objX;
+ bool hasmask;
+ int numTiles;
+ byte* tiles;
+ } _PCE;
+
+protected:
+ void decodePCEngineGfx(const byte *room);
+ void decodeStrip(const byte *ptr, uint16 *tiles, byte *colors, uint16 *masks, int dataWidth, int numRows, bool isObject);
+ void decodePCEngineTileData(const byte *ptr);
+ void decodePCEngineObject(const byte *ptr, int xpos, int ypos, int width, int height);
+
+ void drawStripPCEngine(byte *dst, byte *mask, int dstPitch, int stripnr, int top, int height);
+ void drawStripPCEngineMask(byte *dst, int stripnr, int top, int height) const;
+
+ virtual bool drawStrip(byte *dstPtr, VirtScreen *vs,
+ int x, int y, const int width, const int height,
+ int stripnr, const byte *smap_ptr);
+
+ virtual void decodeMask(int x, int y, const int width, const int height,
+ int stripnr, int numzbuf, const byte *zplane_list[9],
+ bool transpStrip, byte flag, const byte *tmsk_ptr);
+
+ virtual void prepareDrawBitmap(const byte *ptr, VirtScreen *vs,
+ const int x, const int y, const int width, const int height,
+ int stripnr, int numstrip);
+
+public:
+ GdiPCEngine(ScummEngine *vm);
+ ~GdiPCEngine();
+
+ virtual void roomChanged(byte *roomptr);
+};
+
class GdiV1 : public Gdi {
protected:
/** Render settings which are specific to the C64 graphic decoders. */