Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(283)

Issue 2669253003: media: Fix MediaCodecAudioDecoder reinitialization (Closed)

Created:
3 years, 10 months ago by xhwang
Modified:
3 years, 10 months ago
CC:
chromium-reviews
Target Ref:
refs/pending/branch-heads/2987
Project:
chromium
Visibility:
Public.

Description

media: Fix MediaCodecAudioDecoder reinitialization According to media::AudioDecoder documentation, a decoder can be reinitialized with a different config after it's previously initialized. In this case, the decoder should drop all internal buffers and reset to a clean state. Currently this is not supported by MediaCodecAudioDecoder and running the newly added test would cause DCHECKs to fire. This CL fixes MediaCodecAudioDecoder to support reinitialization, where it will always call SetInitialConfiguration() and CreateMediaCodecLoop() to initialize the decoder with the new config. New unit tests are added to cover this case. As part of the process I also made some cleanup changes in the unit test file. NOTRY=true NOPRESUBMIT=true TBR=dalecurtis@chromium.org,timav@chromium.org BUG=679095 TEST=New test added. Review-Url: https://codereview.chromium.org/2642823004 Cr-Commit-Position: refs/heads/master@{#445280} (cherry picked from commit 2c1f8ed028edcb44c954cb2a0625a8f278933481) Review-Url: https://codereview.chromium.org/2669253003 Cr-Commit-Position: refs/branch-heads/2987@{#278} Cr-Branched-From: ad51088c0e8776e8dcd963dbe752c4035ba6dab6-refs/heads/master@{#444943} Committed: https://chromium.googlesource.com/chromium/src/+/2d0fbfd1f7c4fc522c344b839dd97a28ea596177

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+232 lines, -144 lines) Patch
M media/filters/android/media_codec_audio_decoder.cc View 2 chunks +17 lines, -3 lines 0 comments Download
M media/filters/audio_decoder_unittest.cc View 15 chunks +215 lines, -141 lines 0 comments Download

Messages

Total messages: 6 (4 generated)
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2669253003/1
3 years, 10 months ago (2017-02-02 19:58:58 UTC) #3
commit-bot: I haz the power
3 years, 10 months ago (2017-02-02 20:01:06 UTC) #6
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://chromium.googlesource.com/chromium/src/+/2d0fbfd1f7c4fc522c344b839dd9...

Powered by Google App Engine
This is Rietveld 408576698