diff options
Diffstat (limited to 'engines/bladerunner/slice_animations.h')
-rw-r--r-- | engines/bladerunner/slice_animations.h | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/engines/bladerunner/slice_animations.h b/engines/bladerunner/slice_animations.h index b5b60ef096..a34b6ec13e 100644 --- a/engines/bladerunner/slice_animations.h +++ b/engines/bladerunner/slice_animations.h @@ -36,12 +36,6 @@ namespace BladeRunner { class BladeRunnerEngine; -struct SlicePalette { - uint16 color555[256]; - Color256 color[256]; - -// uint16 &operator[](size_t i) { return color555[i]; } -}; class SliceAnimations { friend class SliceRenderer; @@ -55,6 +49,13 @@ class SliceAnimations { uint32 offset; }; + struct Palette { + uint16 color555[256]; + Color256 color[256]; + + // uint16 &operator[](size_t i) { return color555[i]; } + }; + struct Page { void *_data; uint32 _lastAccess; @@ -80,7 +81,7 @@ class SliceAnimations { uint32 _pageCount; uint32 _paletteCount; - Common::Array<SlicePalette> _palettes; + Common::Array<Palette> _palettes; Common::Array<Animation> _animations; Common::Array<Page> _pages; @@ -100,14 +101,14 @@ public: bool openCoreAnim(); bool openHDFrames(); - SlicePalette &getPalette(int i) { return _palettes[i]; }; - void *getFramePtr(uint32 animation, uint32 frame); + Palette &getPalette(int i) { return _palettes[i]; }; + void *getFramePtr(uint32 animation, uint32 frame); - int getFrameCount(int animation){ return _animations[animation].frameCount; } - float getFPS(int animation){ return _animations[animation].fps; } + int getFrameCount(int animation) const { return _animations[animation].frameCount; } + float getFPS(int animation) const { return _animations[animation].fps; } - Vector3 getPositionChange(int animation); - float getFacingChange(int animation); + Vector3 getPositionChange(int animation) const; + float getFacingChange(int animation) const; }; } // End of namespace BladeRunner |