From 45c58982308210e50610b5f5997a45f33c09ac40 Mon Sep 17 00:00:00 2001 From: Martin Kiewitz Date: Thu, 4 Jun 2015 16:01:43 +0200 Subject: SHERLOCK: 3DO movie player comments --- engines/sherlock/scalpel/3do/movie_decoder.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'engines/sherlock/scalpel/3do') diff --git a/engines/sherlock/scalpel/3do/movie_decoder.cpp b/engines/sherlock/scalpel/3do/movie_decoder.cpp index a50362c99a..8aefa42177 100644 --- a/engines/sherlock/scalpel/3do/movie_decoder.cpp +++ b/engines/sherlock/scalpel/3do/movie_decoder.cpp @@ -268,9 +268,10 @@ void Scalpel3DOMovieDecoder::readNextPacket() { case MKTAG('F', 'R', 'M', 'E'): // Found frame data if (_streamVideoOffset <= chunkOffset) { + // We are at an offset that is still relevant to video decoding if (!videoDone) { if (!videoGotFrame) { - // If we previously found one, this is just to get the time offset of the next one + // We haven't decoded any frame yet, so do so now _stream->readUint32BE(); videoFrameSize = _stream->readUint32BE(); _videoTrack->decodeFrame(_stream->readStream(videoFrameSize), videoTimeStamp); @@ -279,7 +280,8 @@ void Scalpel3DOMovieDecoder::readNextPacket() { videoGotFrame = true; } else { - // Already decoded a frame, so seek back to current chunk and exit + // Already decoded a frame, so get timestamp of follow-up frame + // and then we are done with video // Calculate next frame time // 3DO clock time for movies runs at 240Hh, that's why timestamps are based on 240. @@ -314,6 +316,7 @@ void Scalpel3DOMovieDecoder::readNextPacket() { case MKTAG('S', 'S', 'M', 'P'): // Got audio chunk if (_streamAudioOffset <= chunkOffset) { + // We are at an offset that is still relevant to audio decoding if (!audioDone) { audioBytes = _stream->readUint32BE(); _audioTrack->queueAudio(_stream, audioBytes); -- cgit v1.2.3