mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-19 02:38:32 +00:00
NANCY: Skip unsupported video frame types for now
This commit is contained in:
parent
d5ea0c840a
commit
bd7e83cf8e
@ -97,7 +97,8 @@ AVFDecoder::AVFVideoTrack::AVFVideoTrack(Common::SeekableReadStream *stream) {
|
||||
info.offset = stream->readUint32LE();
|
||||
info.compressedSize = stream->readUint32LE();
|
||||
info.size = stream->readUint32LE();
|
||||
stream->skip(5); // Unknown
|
||||
info.type = stream->readByte();
|
||||
stream->skip(4); // Unknown;
|
||||
_chunkInfo.push_back(info);
|
||||
}
|
||||
}
|
||||
@ -114,6 +115,11 @@ const Graphics::Surface *AVFDecoder::AVFVideoTrack::decodeNextFrame() {
|
||||
_fileStream->seek(_chunkInfo[_curFrame].offset);
|
||||
uint size = _chunkInfo[_curFrame].size;
|
||||
|
||||
if (_chunkInfo[_curFrame].type != 0) {
|
||||
warning("Skipping frame type %d", _chunkInfo[_curFrame].type);
|
||||
return _surface;
|
||||
}
|
||||
|
||||
if (_compressed) {
|
||||
Common::ReadStream *input = _fileStream->readStream(_chunkInfo[_curFrame].compressedSize);
|
||||
Common::MemoryWriteStream output((byte *)_surface->getPixels(), size);
|
||||
|
@ -67,6 +67,7 @@ private:
|
||||
uint32 offset;
|
||||
uint32 compressedSize;
|
||||
uint32 size;
|
||||
byte type;
|
||||
};
|
||||
|
||||
bool decodeFrame(byte *rleData, int rleSize, byte *litData, int litSize, byte *dest, int left, int width, int height, int colorKey);
|
||||
|
Loading…
x
Reference in New Issue
Block a user