diff options
author | Filippos Karapetis | 2009-01-11 03:34:50 +0000 |
---|---|---|
committer | Filippos Karapetis | 2009-01-11 03:34:50 +0000 |
commit | 0b4dd7c4593587355c1965eb0d266040c83f0382 (patch) | |
tree | c9f6b62c14ba25ccbdf5e8773d5c4e0dc367b7ea /engines | |
parent | 08c71e39490590125645215ce65fdcb71f11fae6 (diff) | |
download | scummvm-rg350-0b4dd7c4593587355c1965eb0d266040c83f0382.tar.gz scummvm-rg350-0b4dd7c4593587355c1965eb0d266040c83f0382.tar.bz2 scummvm-rg350-0b4dd7c4593587355c1965eb0d266040c83f0382.zip |
Committed a modified version of wjp's patch for the video player:
- Split the video player from the video decoders. It's now possible to have one video player for multiple decoders
- Added the palette weight calculation from the BS1 engine into VideoPlayer::setPalette. It's now possible to find the values of the white and black colors via getWhite() and getBlack() (useful for subtitle overlays)
- Adapted FTA2's movie playing code to the new changes to video player
- Fixed a slight bug in the DXA decoder (_videoinfo.startTime was not initialized)
svn-id: r35816
Diffstat (limited to 'engines')
-rw-r--r-- | engines/saga/introproc_fta2.cpp | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/engines/saga/introproc_fta2.cpp b/engines/saga/introproc_fta2.cpp index 8d2e73b7a6..f8c61a8568 100644 --- a/engines/saga/introproc_fta2.cpp +++ b/engines/saga/introproc_fta2.cpp @@ -52,10 +52,16 @@ int Scene::FTA2StartProc() { stopEvent.kbd = Common::KEYCODE_ESCAPE; stopEvents.push_back(stopEvent); - Graphics::SMKPlayer *smkPlayer = new Graphics::SMKPlayer(_vm->_mixer); - smkPlayer->playVideo("trimark.smk", &stopEvents); // Show Ignite logo - smkPlayer->playVideo("intro.smk", &stopEvents); // Play introduction - delete smkPlayer; + Graphics::SMKPlayer *smkDecoder = new Graphics::SMKPlayer(_vm->_mixer); + Graphics::VideoPlayer *player = new Graphics::VideoPlayer(smkDecoder); + if (smkDecoder->loadFile("trimark.smk")) + player->playVideo(&stopEvents); // Show Ignite logo + smkDecoder->closeFile(); + if (smkDecoder->loadFile("intro.smk")) + player->playVideo(&stopEvents); // Play introduction + smkDecoder->closeFile(); + delete player; + delete smkDecoder; // HACK: Forcibly quit here _vm->quitGame(); @@ -96,13 +102,18 @@ int Scene::FTA2EndProc(FTA2Endings whichEnding) { stopEvents.push_back(stopEvent); // Play ending - Graphics::SMKPlayer *smkPlayer = new Graphics::SMKPlayer(_vm->_mixer); - smkPlayer->playVideo(videoName, &stopEvents); - delete smkPlayer; + Graphics::SMKPlayer *smkDecoder = new Graphics::SMKPlayer(_vm->_mixer); + Graphics::VideoPlayer *player = new Graphics::VideoPlayer(smkDecoder); + if (smkDecoder->loadFile(videoName)) { + player->playVideo(&stopEvents); + smkDecoder->closeFile(); + } + delete player; + delete smkDecoder; return SUCCESS; } } // End of namespace Saga -#endif
\ No newline at end of file +#endif |