New issue
Advanced search Search tips

Issue 606084 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner: ----
Closed: May 2016
Cc:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

DCHECK failure in ReadFromDemuxerStream() after falling back to SW decoder post EOS

Project Member Reported by tguilbert@chromium.org, Apr 22 2016

Issue description

A recent change allows DecoderStream to fallback to a SW decoder if the HW decoder fails on its first attempt to decode (see https://codereview.chromium.org/1879353003/)

However, the DecoderStream can be left in a bad state if we if reach the EOS before falling back to the SW decoder (if the video has 1-3 frames for example). Read requests might be short circuited by the EOS flag, before attempting to decode the buffers saved from the demuxer stream before fallback. This would result in 0 frames being decoded/returned, instead of the 1-3 frames.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Apr 26 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8f4a3f7d9d522797568b75ab201ed9aa9506afb6

commit 8f4a3f7d9d522797568b75ab201ed9aa9506afb6
Author: tguilbert <tguilbert@chromium.org>
Date: Tue Apr 26 03:53:48 2016

Fix EOS reached before decoder fallback

If the demuxer stream we are pulling buffers from only has a few frames
(1 to 3 for example), we can reach the demuxer's end of stream before
knowing that we need to fall back to a software decoder. DecoderStream
is left with the |decoding_eos_| flag set, and runs into a DCHECK when
calling ReadFromDemuxerStream() upon decoder reinitialization.

This change updates CanDecodeMore() to take into account
|fallback_buffers_|, so we can attempt to decode fallback buffers before
returning EOS frames.

BUG= 606084 
REVIEW=DaleCurtis
TEST=updated unit tests

Review URL: https://codereview.chromium.org/1918693003

Cr-Commit-Position: refs/heads/master@{#389687}

[modify] https://crrev.com/8f4a3f7d9d522797568b75ab201ed9aa9506afb6/media/base/fake_demuxer_stream.cc
[modify] https://crrev.com/8f4a3f7d9d522797568b75ab201ed9aa9506afb6/media/base/fake_demuxer_stream.h
[modify] https://crrev.com/8f4a3f7d9d522797568b75ab201ed9aa9506afb6/media/filters/decoder_stream.cc
[modify] https://crrev.com/8f4a3f7d9d522797568b75ab201ed9aa9506afb6/media/filters/video_frame_stream_unittest.cc

Status: Fixed (was: Available)

Sign in to add a comment