Re: Eidos RPL video codec
Mike Melanson <[email protected]> Tue, 04 Jan 2005 15:26:12 -0700
| Newsgroups | gmane.comp.video.xine.codec.devel |
|---|---|
| Message-ID | <[email protected]> |
Christian Ohm wrote: > mplayer plays it with 'rawaudio format=0x200' (that's Creative ADPCM), but > output is a bit distorted (sounds like it's played too loud, and thus > somewhat overdriven) with the ffmpeg decoder (it can't load the binary > Windows codec, so I couldn't try that as well). Hmm, I thought Creative ADPCM was just a variation of IMA ADPCM? > It seems that each frame has a 16 (?) byte header, with 16 bit integers. The > first is always 0x0130 (probably the video format), the second 0x0001 or > 0x8001, that looks like flags. In my 15 fps test file, every 15th frame had > 0x8001, all other frames 0x0001. The third is the size of the video chunk, > the same as in the index at the end of the file. The remaining 10 bytes are > all zero, that's why I think they also belong to the header. Are you familiar with the ARMovie file format spec? http://multimedia.cx/AE7doc.txt I think the .rpl files are consistent with that format (in case you are trying to figure out the container layout). > All that's really left is the video codec itself, and that's the really > interesting part... I could expand the program I wrote to dump the audio > data to also dump the video frames, but wouldn't know where to start in > trying to transform it into a pretty image... Codec 130 sounds familiar. Not sure if you caught this tidbit from one of my journal entries: http://multimedia.cx/mmentry-2003-08-12.html ***** ...the root directory of the disc contains 11 RPL files. There are also DLL files such as Winplay.dll, Winsdec.dll, and Winstr.dll that export functions that appear to be related to demuxing, decoding, and playing back multimedia files. The primary executable kain2.exe imports from Winplay.dll, which imports from Winstr.dll, which imports from Winsdec.dll, and also 2 other DLLs, Dec130.dll and edec.dll. According to the RPL file headers, the video format is #130. Hmmm...unfortunately, Dec130.dll's functions are named very unintuitively as ExpFn0000() .. ExpFn0009(). Also, judging by the "4 bits per sample" field in the file headers, it is safe to assume that the files use some sort of ADPCM audio compression. ***** I see that Warzone uses these same decoding DLLs. So, if you can trace through the sequence playback code in the game's source files, that might de-obfuscate some of those ExpFn000#() functions. That would be a great start. -- -Mike Melanson ------------------------------------------------------- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt