#8948 closed patch
BS1/BS2: Video simplification/rewrite & MPEG2 removal
Reported by: | bluegr | Owned by: | bluegr |
---|---|---|---|
Priority: | normal | Component: | Engine: Sword1 |
Version: | Keywords: | ||
Cc: | Game: | Broken Sword 1 |
Description
Hello there
I'm attaching 2 patches, one by me, and one by eriktorbjorn. These overlap each other somewhat, so I've included them both.
eriktorbjorn's patch removes support for MPEG2 movies
The removal of MPEG2 support simplifies the overall code a LOT, and it means that libmpeg2 is no longer necessary.
My patch removes MPEG2 support like what eriktorbjorn's patch does, with some extras. In particular, it removes support for version 1 cutscenes of BS1. From what I understood, the original plan was to have 1 language add-on instead of a separate addon for each language. This is accomplished by having OGG files with multiple substreams, which can be read by the SplittedAudioStream class. Since we don't have such a pack in our downloads page for BS1, I removed support for version 1 cutscenes, which simplifies code a lot as well, together with the whole SplittedAudioStream class and the inbuilt credits player. From what I understood, the plan was to remove the credits video file altogether and replace it with a text file, which would be read by the credits player class. Also, the credits in the original MPEG2 cutscenes were too hard to read because of the MPEG artifacts.
Moreover, I've removed the unneeded implementation of setPalette, since both the DXA and the SMK players have a default implementation for that. Also, I've rewritten the BS1 video player to use the new VideoPlayer() class. This further simplifies the code a lot.
Finally, I've added support for the original Smacker movies of both games as well. This is currently disabled, and can be enabled by defining USE_SWORD_SMACKS in the sword1 and sword2 engines. I've set BS1 to use the high-resolution Smacker movies (in the SMACKSHI folder)
The only thing I don't really like is the inclusion of readSoundHeader() in video_player.h, which is not really pretty
Ticket imported from: #2524272. Ticket imported from: patches/1053.
Attachments (3)
Change History (11)
by , 16 years ago
Attachment: | bs-patch.patch added |
---|
comment:3 by , 16 years ago
Owner: | set to |
---|
comment:4 by , 16 years ago
I think we should probably commit this to trunk now that 0.13 has been branched. Do you agree? We can always improve it further afterwards, if necessary.
comment:5 by , 16 years ago
Same patch against the latest SVN
Things are still fuzzy with the Smacker videos in BS1/BS2. 3 years ago, there was a concern that adding Smacker support would be bad, as RAD Game Tools would object to it. However, now we got a Smacker video decoder, based on specs which are publicly available, and on FFMPEG. joostp has also talked with Tony Warriner, who is one of the directors in Revolution, and he mentioned that this approach would be fine (the e-mail has been sent to -devel).
So, we could add this for now, as Smacker support is disabled by default anyway, and we could improve it further afterwards, as mentioned
So, should we go ahead and commit this? File Added: sword_smk_latest.patch
comment:6 by , 16 years ago
Owner: | changed from | to
---|---|
Status: | new → closed |
comment:7 by , 16 years ago
Applied the patch as-is, as the situation with the Smacker videos has been resolved (we've contacted Revolution about this).
Closing
comment:8 by , 6 years ago
Component: | → Engine: Sword1 |
---|---|
Game: | → Broken Sword 1 |
Improved patch by thebluegr/md5