Skip to content

Commit

Permalink
VIDEO: Improve a Cinepak heuristic
Browse files Browse the repository at this point in the history
Brings it inline with the FFmpeg/libav version again
  • Loading branch information
Matthew Hoops committed Nov 14, 2012
1 parent e6a4bd8 commit 51b2904
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions video/codecs/cinepak.cpp
Expand Up @@ -87,10 +87,9 @@ const Graphics::Surface *CinepakDecoder::decodeImage(Common::SeekableReadStream
// 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()) {
uint16 temp = stream->readUint16BE();
if (temp == 0xFE00)
if (stream->readUint16BE() == 0xFE00)
stream->readUint32BE();
else if (temp != _curFrame.width)
else if ((stream->size() % _curFrame.length) == 0)
stream->seek(-2, SEEK_CUR);
}

Expand Down

0 comments on commit 51b2904

Please sign in to comment.