22 #ifndef VOYEUR_FILES_H 23 #define VOYEUR_FILES_H 25 #include "common/scummsys.h" 26 #include "common/file.h" 27 #include "common/rect.h" 28 #include "common/str.h" 29 #include "voyeur/screen.h" 38 class PictureResource;
39 class ViewPortResource;
40 class ViewPortListResource;
43 class VInitCycleResource;
45 class ControlResource;
49 #define DECOMPRESS_SIZE 0x7000 71 byte _decompressBuf[DECOMPRESS_SIZE];
73 byte _historyBuffer[0x200];
86 byte *decompress(byte *buf,
int size,
int mode);
96 virtual void initResource(
int resType) = 0;
100 byte *getBoltMember(uint32
id);
109 void freeBoltGroup(uint16
id);
110 void freeBoltMember(uint32
id);
111 byte *memberAddr(uint32
id);
112 byte *memberAddrOffset(uint32
id);
113 void resolveIt(uint32
id, byte **p);
114 void resolveFunction(uint32
id, ScreenMethodPtr *fn);
117 BoltEntry &getBoltEntryFromLong(uint32
id);
130 void initViewPortList();
135 void initResource(
int resType)
override;
147 void initResource(
int resType)
override;
165 void load(uint16 groupId);
201 bool hasResource()
const;
212 bool openBoltLib(
const char *filename,
BoltFile *&boltFile);
213 byte *fload(
const char *filename,
int *size);
221 RectEntry(
int x1,
int y1,
int x2,
int y2,
int arrIndex,
int count);
228 RectResource(
const byte *src,
int size,
bool isExtendedRects);
236 PICFLAG_2 = 2, PICFLAG_PIC_OFFSET = 8, PICFLAG_CLEAR_SCREEN = 0x10,
237 PICFLAG_20 = 0x20, PICFLAG_HFLIP = 0x40, PICFLAG_VFLIP = 0x80, PICFLAG_100 = 0x100,
238 PICFLAG_CLEAR_SCREEN00 = 0x1000
242 DISPFLAG_1 = 1, DISPFLAG_2 = 2, DISPFLAG_4 = 4, DISPFLAG_8 = 8,
243 DISPFLAG_10 = 0x10, DISPFLAG_20 = 0x20, DISPFLAG_40 = 0x40, DISPFLAG_80 = 0x80,
244 DISPFLAG_100 = 0x100, DISPFLAG_200 = 0x200, DISPFLAG_400 = 0x400,
245 DISPFLAG_800 = 0x800, DISPFLAG_1000 = 0x1000, DISPFLAG_2000 = 0x2000,
246 DISPFLAG_4000 = 0x4000, DISPFLAG_VIEWPORT = 0x8000, DISPFLAG_CURSOR = 0x10000,
261 void sFillBox(
int width,
int height);
284 void flipHorizontal(
const byte *data);
289 void flipVertical(
const byte *data);
311 const Common::Rect &bounds,
int maskData, byte *imgData,
int planeSize);
324 ViewPortAddPtr addFn, ViewPortRestorePtr restoreFn);
327 ViewPortSetupPtr _setupFn;
329 ViewPortAddPtr _addFn;
331 ViewPortRestorePtr _restoreFn;
333 ScreenMethodPtr _fn1;
343 int _rectListCount[3];
351 void setupViewPort();
354 void fillPic(byte onOff);
355 void drawIfaceTime();
361 uint16 _rEntry, _gEntry, _bEntry;
362 uint16 _rChange, _gChange, _bChange;
380 int _minChar, _maxChar;
393 enum FontJustify { ALIGN_LEFT = 0, ALIGN_CENTER = 1, ALIGN_RIGHT = 2 };
403 FontJustify _justify;
415 FontInfoResource(byte picFlags, byte picSelect, byte picPick, byte picOnOff, byte fontFlags,
416 FontJustify justify,
int fontSaveBack,
const Common::Point &pos,
int justifyWidth,
417 int justifyHeight,
const Common::Point &shadow,
int foreColor,
int backColor,
479 int &_victimEvidenceIndex;
480 int &_victimMurderIndex;
493 static int _useCount[8];
494 static void initUseCount();
503 byte *getDataOffset();
504 void getButtonsText();
505 void getButtonsFlags();
506 void performOpenCard();
507 const byte *getRecordOffset(
const byte *p);
508 const byte *getNextRecord(
const byte *p);
509 const byte *getSTAMPCard(
int cardId);
510 int getStateFromID(uint32
id);
511 uint32 getSID(
int sid);
512 void cardAction(
const byte *p);
513 void doSTAMPCardAction();
514 bool goToStateID(
int stackId,
int id);
515 const byte *cardPerform(
const byte *card);
516 bool cardPerform2(
const byte *p,
int cardCmdId);
518 void setButtonFlag(
int idx, byte bits);
519 void clearButtonFlag(
int idx, byte bits);
529 void doAptAnim(
int mode);
535 bool checkMansionScroll();
547 byte *_threadInfoPtr;
548 byte _buttonFlags[64];
551 byte *_playCommandsPtr;
556 bool loadAStack(
int stackId);
561 void unloadAStack(
int stackId);
575 void initThreadStruct(
int idx,
int id);
580 bool goToState(
int stackId,
int stateId);
582 bool chooseSTAMPButton(
int buttonId);
587 void parsePlayCommands();
byte * _imgData
Definition: files.h:302
Definition: serializer.h:79
DisposeAfterUse::Flag _freeImgData
Definition: files.h:307
Definition: animation.h:38