I've been making some progress lately on documenting the WC3 3DO VGA chunk. I still don't have it completely documented, but here's an update just to keep you up to speed:
>
> So far, i've been able to confirm it is indeed very close to the PC version: 22 opcodes for image operations, huffman compressed, along with a variable-byte length block, motion compensation block and encoded pixel block. The content of these smaller blocks within the VGA chunk seems to be pretty much the same between the PC and 3DO versions, with only minor differences, such as pixels in CEL format instead of 8-bit VGA palette (which the PC version further compresses with the same dictionary-based algorithm used by other WC games, such as Super Wing Commander) .
>
> As an aside, observing the evolution in cut-scene encoding between WC2-SWC-WC3 is really exciting! The principles behind WC3 movie decoding turn out not to be that much different from the WC2 take off / landing animations (although WC2 is much simpler... and usually decodes the movie over one or more still backgrounds, encoded separately and triggered at different points).
>
> Anyway, the main difference between the 3DO and PC versions seems to be the image operations used by the main algorithm. While both use 22 opcodes for encoding the image, these have different meanings on the PC and 3DO versions. Gone is an opcode which handles a 3-byte run-length (which makes sense, given the movie resolution, 2-byte lengths are always enough), while other opcodes simply do something else... so the challenge right now is to document the changes and adapt the decoder accordingly.
>
> I think i'm getting close! In between data-analysis and binary disassembly, i hope to be able to dig up this information and integrate it on my script. I'll keep you informed as I go...
________________________________________
Good news here, i finally have all the details figured out for the 3DO compression algorithm, and managed to complete my script for decoding the video. I posted a sample here:
>
>
http://hcl.solsector.net/sc_13.mov.avi
>
> I'm still running a few tests to make sure no bugs remain although, given the output, if there's still any bugs remaining they're likely to be pretty minor.
>
> Overall, what we have on the 3DO is a variation of the PC algorithm, with a few changes in order to take into account the CEL hardware and 3DO frame buffer memory layout. That's basically it. You get increased color depth when compared to the PC version (and without those "sticky pixels"), and don't get the somewhat blurry artifacts of the PSX movies resulting from the JPEG-like compression.
>
> Movie resolution is actually slightly lower, since it's 300 pixels wide instead of the 320 pixels both on the PC and PSX. Interestingly, however, the VGA chunks still encode the frame changes expecting a 320-pixel wide frame buffer (probably in order to fit the 3DO frame buffer), which means that if the CEL chunks (keyframes) are smaller than that, they are rendered on the center of the buffer.
>
> You'll note the video I posted doesn't have any audio. I think it is compressed with some kind of ADPCM algorithm, i just have to figure out if the decompression is done by the CPU or the 3DO DSP, and then dig in and figure out what's going on. I expect audio quality to be fairly close to the PSX videos though.