aboutsummaryrefslogtreecommitdiff
path: root/engines/sword1
diff options
context:
space:
mode:
authorMatthew Hoops2012-07-23 21:04:51 -0400
committerMatthew Hoops2012-07-23 21:04:51 -0400
commita652f6669e2e9225aee17431784b433397b41ae3 (patch)
tree9b3c000e20ab019f5927132025868ca898877b2f /engines/sword1
parent3a780a63db79c2a1b2527e6510182a74f6fcfe12 (diff)
downloadscummvm-rg350-a652f6669e2e9225aee17431784b433397b41ae3.tar.gz
scummvm-rg350-a652f6669e2e9225aee17431784b433397b41ae3.tar.bz2
scummvm-rg350-a652f6669e2e9225aee17431784b433397b41ae3.zip
VIDEO: Rewrite SmackerDecoder to use the new API
Diffstat (limited to 'engines/sword1')
-rw-r--r--engines/sword1/animation.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/engines/sword1/animation.cpp b/engines/sword1/animation.cpp
index 49c5ef7312..8f863d1e09 100644
--- a/engines/sword1/animation.cpp
+++ b/engines/sword1/animation.cpp
@@ -179,6 +179,13 @@ bool MoviePlayer::load(uint32 id) {
break;
case kVideoDecoderSMK:
filename = Common::String::format("%s.smk", sequenceList[id]);
+
+ if (_decoder->loadFile(filename)) {
+ ((Video::AdvancedVideoDecoder *)_decoder)->start(); // TODO: Remove after new API is complete
+ return true;
+ } else {
+ return false;
+ }
break;
case kVideoDecoderPSX:
filename = Common::String::format("%s.str", (_vm->_systemVars.isDemo) ? sequenceList[id] : sequenceListPSX[id]);
@@ -547,7 +554,7 @@ MoviePlayer *makeMoviePlayer(uint32 id, SwordEngine *vm, Text *textMan, ResMan *
filename = Common::String::format("%s.smk", sequenceList[id]);
if (Common::File::exists(filename)) {
- Video::SmackerDecoder *smkDecoder = new Video::SmackerDecoder(snd);
+ Video::SmackerDecoder *smkDecoder = new Video::SmackerDecoder();
return new MoviePlayer(vm, textMan, resMan, snd, system, bgSoundHandle, smkDecoder, kVideoDecoderSMK);
}