22 #ifndef DIRECTOR_DIRECTOR_H 23 #define DIRECTOR_DIRECTOR_H 25 #include "common/hash-ptr.h" 26 #include "common/gui_options.h" 28 #include "graphics/macgui/macwindowmanager.h" 30 #include "director/types.h" 31 #include "director/util.h" 32 #include "director/detection.h" 34 #define GAMEOPTION_GAMMA_CORRECTION GUIO_GAMEOPTIONS1 35 #define GAMEOPTION_TRUE_COLOR GUIO_GAMEOPTIONS2 39 class SeekableReadStream;
40 class SeekableReadStreamEndian;
45 class MacWindowManager;
47 struct WinCursorGroup;
131 PaletteV4() : id(), palette(
nullptr), length(0) {}
155 const int SCALE_THRESHOLD = 0x100;
164 DirectorGameGID getGameGID()
const;
165 const char *getGameId()
const;
166 uint16 getDescriptionVersion()
const;
167 uint16 getVersion()
const {
return _version; }
168 void setVersion(uint16 version);
171 uint32 getGameFlags()
const;
173 const char *getExtra();
179 Lingo *getLingo()
const {
return _lingo; }
180 Window *getStage()
const {
return _stage; }
181 Window *getCurrentWindow()
const {
return _currentWindow; }
183 void forgetWindow(
Window *window);
184 void setCurrentWindow(
Window *window);
185 Window *getCursorWindow()
const {
return _cursorWindow; }
186 void setCursorWindow(
Window *window) { _cursorWindow = window; }
187 Movie *getCurrentMovie()
const;
188 void setCurrentMovie(
Movie *movie);
189 Archive *getMainArchive()
const {
return _mainArchive; }
190 void setMainArchive(
Archive *archive) { _mainArchive = archive; }
198 void addPalette(
CastMemberID &
id,
const byte *palette,
int length);
200 void setPalette(
const byte *palette, uint16 count);
201 void shiftPalette(
int startIndex,
int endIndex,
bool reverse);
203 void clearPalettes();
206 void loadDefaultPalettes();
210 const PaletteV4 &getLoaded4Palette() {
return _loaded4Palette; }
212 const Common::FSNode *getGameDataDir()
const {
return &_gameDataDir; }
213 const byte *getPalette()
const {
return _currentPalette; }
214 uint16 getPaletteColorCount()
const {
return _currentPaletteLength; }
219 uint32 transformColor(uint32 color);
221 void setCursor(DirectorCursor type);
225 uint32 getColorBlack();
226 uint32 getColorWhite();
229 void setMachineType(
int machineType);
230 Common::CodePage getPlatformEncoding();
243 bool desktopEnabled();
247 bool processEvents(
bool captureClick =
false,
bool skipWindowManager =
false);
248 void processEventQUIT();
254 void loadSlowdownCooloff(uint32 delay = 2000);
256 void delayMillis(uint32 delay);
263 uint32 _debugDraw = 0;
264 int _defaultVolume = 255;
270 bool _playbackPaused;
277 bool _emulateMultiButtonMouse;
305 uint32 _loadSlowdownFactor;
306 uint32 _loadSlowdownCooldownTime;
308 bool _vfwPaletteHack;
311 byte _currentPalette[768];
312 uint16 _currentPaletteLength;
313 bool _gammaCorrection;
342 uint16 _framesRan = 0;
343 bool _noFatalLingoError =
false;
345 bool _firstMovie =
true;
360 SpriteType sprite = kInactiveSprite;
361 bool oneBitImage =
false;
362 InkType ink = kInkTypeCopy;
369 bool applyColor =
false;
372 void setApplyColor();
373 uint32 preprocessColor(uint32 src);
377 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) {
378 colorWhite = d->_wm->_colorWhite;
379 colorBlack = d->_wm->_colorBlack;
383 ink(old.ink), alpha(old.alpha),
384 backColor(old.backColor), foreColor(old.foreColor),
385 srf(old.srf), dst(old.dst),
386 destRect(old.destRect), srcPoint(old.srcPoint),
387 colorWhite(old.colorWhite), colorBlack(old.colorBlack),
388 applyColor(old.applyColor) {
Definition: managed_surface.h:51
Definition: director.h:106
EngineFeature
Definition: engine.h:258
Definition: debugger.h:66
Definition: director.h:114
Definition: macwindowmanager.h:147
Definition: primitives.h:29
Definition: director.h:125
Definition: director.h:148
Definition: algorithm.h:29
Definition: formatinfo.h:28
Definition: director.h:134
Definition: macwindowmanager.h:117
Definition: director.h:120
Definition: director.h:157
Definition: detection.h:35
Definition: director.h:350
Language
Definition: language.h:45