Open main menu

Difference between revisions of "Cine/Specifications"

608 bytes added ,  17:22, 16 June 2008
Added a couple of links to Cine's unpacking code to help understanding of the way Delphine's unpacker handled the source stream chunks internally (And why the first chunk seems peculiar).
(Added info about how to parse the source stream into bits.)
(Added a couple of links to Cine's unpacking code to help understanding of the way Delphine's unpacker handled the source stream chunks internally (And why the first chunk seems peculiar).)
Line 145: Line 145:


Because of the way the Delphine's decompressor routine handled the bit stream the first
Because of the way the Delphine's decompressor routine handled the bit stream the first
chunk acts in a sort a peculiar way. All other chunks in the source stream always contain
chunk acts in a sort a peculiar way (Take a look at the functions rcr
([http://scummvm.svn.sourceforge.net/viewvc/scummvm/scummvm/trunk/engines/cine/unpack.h?revision=32689&view=markup#l_62 Declaration],
[http://scummvm.svn.sourceforge.net/viewvc/scummvm/scummvm/trunk/engines/cine/unpack.cpp?revision=32689&view=markup#l_43 Definition])
and nextBit
([http://scummvm.svn.sourceforge.net/viewvc/scummvm/scummvm/trunk/engines/cine/unpack.h?revision=32689&view=markup#l_69 Declaration],
[http://scummvm.svn.sourceforge.net/viewvc/scummvm/scummvm/trunk/engines/cine/unpack.cpp?revision=32689&view=markup#l_52 Definition])
in Cine's revision 32689). All other chunks in the source stream always contain
full 32 bits but the first chunk contains only 0 to 31 bits. If the first chunk is zero,
full 32 bits but the first chunk contains only 0 to 31 bits. If the first chunk is zero,
then we simply discard it and read another chunk. If the first chunk is not zero, then it
then we simply discard it and read another chunk. If the first chunk is not zero, then it
417

edits