22 #ifndef DIRECTOR_DIRECTOR_H 23 #define DIRECTOR_DIRECTOR_H 25 #include "common/hash-ptr.h" 27 #include "graphics/macgui/macwindowmanager.h" 29 #include "director/types.h" 30 #include "director/util.h" 31 #include "director/detection.h" 35 class SeekableReadStream;
36 class SeekableReadStreamEndian;
40 class MacWindowManager;
42 struct WinCursorGroup;
124 PaletteV4() : id(), palette(
nullptr), length(0) {}
148 const int SCALE_THRESHOLD = 0x100;
157 DirectorGameGID getGameGID()
const;
158 const char *getGameId()
const;
159 uint16 getDescriptionVersion()
const;
160 uint16 getVersion()
const {
return _version; }
161 void setVersion(uint16 version);
164 uint32 getGameFlags()
const;
166 const char *getExtra();
172 Archive *getMainArchive()
const;
173 Lingo *getLingo()
const {
return _lingo; }
174 Window *getStage()
const {
return _stage; }
175 Window *getCurrentWindow()
const {
return _currentWindow; }
176 void setCurrentWindow(
Window *window);
177 Window *getCursorWindow()
const {
return _cursorWindow; }
178 void setCursorWindow(
Window *window) { _cursorWindow = window; }
179 Movie *getCurrentMovie()
const;
180 void setCurrentMovie(
Movie *movie);
188 void addPalette(
CastMemberID &
id,
const byte *palette,
int length);
190 void setPalette(
const byte *palette, uint16 count);
191 void shiftPalette(
int startIndex,
int endIndex,
bool reverse);
192 void clearPalettes();
195 void loadDefaultPalettes();
199 const PaletteV4 &getLoaded4Palette() {
return _loaded4Palette; }
201 const Common::FSNode *getGameDataDir()
const {
return &_gameDataDir; }
202 const byte *getPalette()
const {
return _currentPalette; }
203 uint16 getPaletteColorCount()
const {
return _currentPaletteLength; }
208 uint32 transformColor(uint32 color);
210 void setCursor(DirectorCursor type);
213 Graphics::MacDrawPixPtr getInkDrawPixel();
214 uint32 getColorBlack();
215 uint32 getColorWhite();
218 void setMachineType(
int machineType);
219 Common::CodePage getPlatformEncoding();
232 bool desktopEnabled();
236 bool processEvents(
bool captureClick =
false,
bool skipWindowManager =
false);
237 void processEventQUIT();
238 uint32 getMacTicks();
243 void loadSlowdownCooloff(uint32 delay = 2000);
245 void delayMillis(uint32 delay);
252 uint32 _debugDraw = 0;
253 int _defaultVolume = 255;
259 bool _playbackPaused;
260 bool _skipFrameAdvance;
292 uint32 _loadSlowdownFactor;
293 uint32 _loadSlowdownCooldownTime;
296 byte _currentPalette[768];
297 uint16 _currentPaletteLength;
322 uint16 _framesRan = 0;
323 bool _noFatalLingoError =
false;
325 bool _firstMovie =
true;
340 SpriteType sprite = kInactiveSprite;
341 bool oneBitImage =
false;
342 InkType ink = kInkTypeCopy;
349 bool applyColor =
false;
352 void setApplyColor();
353 uint32 preprocessColor(uint32 src);
357 DirectorPlotData(
DirectorEngine *d_, SpriteType s, InkType i,
int a, uint32 b, uint32 f) : d(d_), sprite(s), ink(i), alpha(a), backColor(b), foreColor(f) {
358 colorWhite = d->_wm->_colorWhite;
359 colorBlack = d->_wm->_colorBlack;
363 ink(old.ink), alpha(old.alpha),
364 backColor(old.backColor), foreColor(old.foreColor),
365 srf(old.srf), dst(old.dst),
366 destRect(old.destRect), srcPoint(old.srcPoint),
367 colorWhite(old.colorWhite), colorBlack(old.colorBlack),
368 applyColor(old.applyColor) {
Definition: managed_surface.h:51
Definition: director.h:99
EngineFeature
Definition: engine.h:253
Definition: debugger.h:66
Definition: director.h:107
Definition: macwindowmanager.h:149
Definition: director.h:118
Definition: director.h:141
Definition: algorithm.h:29
Definition: formatinfo.h:28
Definition: director.h:127
Definition: macwindowmanager.h:117
Definition: director.h:113
Definition: director.h:150
Definition: detection.h:35
Definition: director.h:330
Language
Definition: language.h:45