diff options
author | Filippos Karapetis | 2014-12-16 00:48:16 +0200 |
---|---|---|
committer | Filippos Karapetis | 2014-12-16 01:58:55 +0200 |
commit | 7f61a094781256f7c2734aa08637494c1dfac6bf (patch) | |
tree | 2dd89d28d338daeb8bdf06e41bcc9e5768cf9885 /engines/zvision/scripting/controls/lever_control.cpp | |
parent | 67bd78a95f6efab6d0da4b3bef1b0cebc79c537c (diff) | |
download | scummvm-rg350-7f61a094781256f7c2734aa08637494c1dfac6bf.tar.gz scummvm-rg350-7f61a094781256f7c2734aa08637494c1dfac6bf.tar.bz2 scummvm-rg350-7f61a094781256f7c2734aa08637494c1dfac6bf.zip |
ZVISION: Make the RLF decoder a subclass of the common video decoder
This way, the redundant MetaAnimation class can now be removed
Diffstat (limited to 'engines/zvision/scripting/controls/lever_control.cpp')
-rw-r--r-- | engines/zvision/scripting/controls/lever_control.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/engines/zvision/scripting/controls/lever_control.cpp b/engines/zvision/scripting/controls/lever_control.cpp index 1e4087963e..9566e4e038 100644 --- a/engines/zvision/scripting/controls/lever_control.cpp +++ b/engines/zvision/scripting/controls/lever_control.cpp @@ -28,15 +28,14 @@ #include "zvision/scripting/script_manager.h" #include "zvision/graphics/render_manager.h" #include "zvision/cursors/cursor_manager.h" -#include "zvision/animation/meta_animation.h" #include "zvision/utility/utility.h" #include "common/stream.h" #include "common/file.h" #include "common/tokenizer.h" #include "common/system.h" - #include "graphics/surface.h" +#include "video/video_decoder.h" namespace ZVision { @@ -106,7 +105,7 @@ void LeverControl::parseLevFile(const Common::String &fileName) { if (param.matchString("animation_id", true)) { // Not used } else if (param.matchString("filename", true)) { - _animation = new MetaAnimation(values, _engine); + _animation = _engine->loadAnimation(values); } else if (param.matchString("skipcolor", true)) { // Not used } else if (param.matchString("anim_coords", true)) { @@ -374,7 +373,8 @@ void LeverControl::renderFrame(uint frameNumber) { const Graphics::Surface *frameData; - frameData = _animation->getFrameData(frameNumber); + _animation->seekToFrame(frameNumber); + frameData = _animation->decodeNextFrame(); if (frameData) _engine->getRenderManager()->blitSurfaceToBkgScaled(*frameData, _animationCoords); } |