diff options
author | Matthew Hoops | 2010-08-08 03:33:44 +0000 |
---|---|---|
committer | Matthew Hoops | 2010-08-08 03:33:44 +0000 |
commit | 27c79d51d43b95c72b80c8aa5ccc70a2d29a34b0 (patch) | |
tree | 5eac1b5bd50a8e478759881c87ad4601344c5c29 /graphics | |
parent | 5f8947c21dab2cc66e23cf5a2d96511e0fd0b5c8 (diff) | |
download | scummvm-rg350-27c79d51d43b95c72b80c8aa5ccc70a2d29a34b0.tar.gz scummvm-rg350-27c79d51d43b95c72b80c8aa5ccc70a2d29a34b0.tar.bz2 scummvm-rg350-27c79d51d43b95c72b80c8aa5ccc70a2d29a34b0.zip |
VIDEO: Cinepak cleanup
svn-id: r51928
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/video/codecs/cinepak.cpp | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/graphics/video/codecs/cinepak.cpp b/graphics/video/codecs/cinepak.cpp index 9892f9d966..a14eaf9acf 100644 --- a/graphics/video/codecs/cinepak.cpp +++ b/graphics/video/codecs/cinepak.cpp @@ -73,14 +73,12 @@ Surface *CinepakDecoder::decodeImage(Common::SeekableReadStream *stream) { debug (4, "Cinepak Frame: Width = %d, Height = %d, Strip Count = %d", _curFrame.width, _curFrame.height, _curFrame.stripCount); -#if 0 // Borrowed from FFMPEG. This should cut out the extra data Cinepak for Sega has (which is useless). // The theory behind this is that this is here to confuse standard Cinepak decoders. But, we won't let that happen! ;) if (_curFrame.length != (uint32)stream->size()) { if (stream->readUint16BE() == 0xFE00) stream->readUint32BE(); } -#endif if (!_curFrame.surface) { _curFrame.surface = new Surface(); @@ -105,8 +103,6 @@ Surface *CinepakDecoder::decodeImage(Common::SeekableReadStream *stream) { _curFrame.strips[i].rect.bottom = _y + stream->readUint16BE(); _curFrame.strips[i].rect.right = _curFrame.width; stream->readUint16BE(); // Ignore, substitute with our own - //printf ("Left = %d, Top = %d, Right = %d, Bottom = %d\n", _curFrame.strips[i].rect.left, _curFrame.strips[i].rect.top, _curFrame.strips[i].rect.right, _curFrame.strips[i].rect.bottom); - // Sanity check. Because Cinepak is based on 4x4 blocks, the width and height of each strip needs to be divisible by 4. assert(!(_curFrame.strips[i].rect.width() % 4) && !(_curFrame.strips[i].rect.height() % 4)); @@ -184,10 +180,9 @@ void CinepakDecoder::loadCodebook(Common::SeekableReadStream *stream, uint16 str codebook[i].u = stream->readByte() + 128; codebook[i].v = stream->readByte() + 128; } else { - /* this codebook type indicates either greyscale or - * palettized video; if palettized, U & V components will - * not be used so it is safe to set them to 128 for the - * benefit of greyscale rendering in YUV420P */ + // This codebook type indicates either greyscale or + // palettized video. We don't handle palettized video + // currently. codebook[i].u = 128; codebook[i].v = 128; } |