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

Issue 240123004: Simplify AudioSplicer logic which slots buffers before or after a splice point. (Closed)

Created:
6 years, 8 months ago by DaleCurtis
Modified:
6 years, 8 months ago
Reviewers:
wolenetz
CC:
chromium-reviews, feature-media-reviews_chromium.org
Visibility:
Public.

Description

Simplify AudioSplicer logic which slots buffers before or after a splice point. Since the first post splice buffer after the config change has a splice_timestamp() of kNoTimestamp() we can definitively say when we have the first post splice buffer instead of having to relying on a problematic timestamp match. The new code makes it so that clients must always call SetSpliceTimestamp() with kNoTimestamp() once the first post splice buffer is received. Adds tests to the AudioRendererImpl to verify behavior of the AudioBufferConverter which impacts the splicer. BUG=334493 TEST=existing tests pass. Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=264766 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=264944

Patch Set 1 #

Total comments: 6

Patch Set 2 : Docs. #

Total comments: 4

Patch Set 3 : Remove duplicate checks. #

Patch Set 4 : Drain AudioBufferConverter on config change. #

Patch Set 5 : Add tests. #

Total comments: 8

Patch Set 6 : Comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+120 lines, -167 lines) Patch
M media/base/audio_splicer.h View 2 chunks +13 lines, -4 lines 0 comments Download
M media/base/audio_splicer.cc View 1 2 3 9 chunks +22 lines, -43 lines 0 comments Download
M media/base/audio_splicer_unittest.cc View 1 2 8 chunks +10 lines, -104 lines 0 comments Download
M media/base/stream_parser_buffer.h View 1 1 chunk +3 lines, -2 lines 0 comments Download
M media/filters/audio_renderer_impl.cc View 1 2 3 1 chunk +5 lines, -0 lines 0 comments Download
M media/filters/audio_renderer_impl_unittest.cc View 1 2 3 4 5 6 chunks +53 lines, -11 lines 0 comments Download
M media/filters/decoder_stream.h View 2 chunks +7 lines, -0 lines 0 comments Download
M media/filters/decoder_stream.cc View 2 chunks +7 lines, -3 lines 0 comments Download

Messages

Total messages: 26 (0 generated)
DaleCurtis
6 years, 8 months ago (2014-04-17 01:08:41 UTC) #1
DaleCurtis
acolwell: Even though we discussed this, if you're overloaded I can pass this to scherkus@ ...
6 years, 8 months ago (2014-04-17 01:13:35 UTC) #2
acolwell GONE FROM CHROMIUM
On 2014/04/17 01:13:35, DaleCurtis wrote: > acolwell: Even though we discussed this, if you're overloaded ...
6 years, 8 months ago (2014-04-17 17:30:09 UTC) #3
wolenetz
My first round of comments is mostly just clarification questions: https://codereview.chromium.org/240123004/diff/1/media/base/audio_splicer_unittest.cc File media/base/audio_splicer_unittest.cc (left): https://codereview.chromium.org/240123004/diff/1/media/base/audio_splicer_unittest.cc#oldcode719 ...
6 years, 8 months ago (2014-04-17 18:24:03 UTC) #4
DaleCurtis
https://codereview.chromium.org/240123004/diff/1/media/base/audio_splicer_unittest.cc File media/base/audio_splicer_unittest.cc (left): https://codereview.chromium.org/240123004/diff/1/media/base/audio_splicer_unittest.cc#oldcode719 media/base/audio_splicer_unittest.cc:719: TEST_F(AudioSplicerTest, SpliceIncorrectlySlotted) { On 2014/04/17 18:24:03, wolenetz wrote: > ...
6 years, 8 months ago (2014-04-17 20:03:18 UTC) #5
wolenetz
looking pretty good. Thanks for clarifying. A couple more comments: https://codereview.chromium.org/240123004/diff/20001/media/base/audio_splicer.h File media/base/audio_splicer.h (right): https://codereview.chromium.org/240123004/diff/20001/media/base/audio_splicer.h#newcode56 ...
6 years, 8 months ago (2014-04-17 22:29:30 UTC) #6
DaleCurtis
https://codereview.chromium.org/240123004/diff/20001/media/base/audio_splicer.h File media/base/audio_splicer.h (right): https://codereview.chromium.org/240123004/diff/20001/media/base/audio_splicer.h#newcode56 media/base/audio_splicer.h:56: // of the overlap range will be discarded. On ...
6 years, 8 months ago (2014-04-17 23:52:33 UTC) #7
wolenetz
lgtm
6 years, 8 months ago (2014-04-18 00:53:40 UTC) #8
DaleCurtis
The CQ bit was checked by dalecurtis@chromium.org
6 years, 8 months ago (2014-04-18 01:01:29 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dalecurtis@chromium.org/240123004/40001
6 years, 8 months ago (2014-04-18 01:02:06 UTC) #10
commit-bot: I haz the power
Change committed as 264766
6 years, 8 months ago (2014-04-18 10:33:07 UTC) #11
DaleCurtis
wolenetz: PTAL at patch set #4. With the codec_delay() and duration changes a new test ...
6 years, 8 months ago (2014-04-18 19:41:41 UTC) #12
wolenetz
Patch set 4 is looking pretty good, though I would like to see a unit ...
6 years, 8 months ago (2014-04-18 21:01:15 UTC) #13
DaleCurtis
PTAL. Tests added which found a bug in the AudioBufferConverter! This patch now depends on ...
6 years, 8 months ago (2014-04-18 23:55:39 UTC) #14
wolenetz
Thanks for adding tests - it looks like they've already been useful :) https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc File ...
6 years, 8 months ago (2014-04-19 00:56:18 UTC) #15
DaleCurtis
https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc File media/filters/audio_renderer_impl_unittest.cc (right): https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc#newcode86 media/filters/audio_renderer_impl_unittest.cc:86: kOutputSamplesPerSecond, On 2014/04/19 00:56:18, wolenetz wrote: > Do any ...
6 years, 8 months ago (2014-04-19 00:59:33 UTC) #16
wolenetz
sorry, one further nit: https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc File media/filters/audio_renderer_impl_unittest.cc (right): https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc#newcode635 media/filters/audio_renderer_impl_unittest.cc:635: const int kInitialFramesBuffered = 1114; ...
6 years, 8 months ago (2014-04-19 01:00:53 UTC) #17
wolenetz
lgtm % my last nit, above.
6 years, 8 months ago (2014-04-19 01:01:57 UTC) #18
DaleCurtis
https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc File media/filters/audio_renderer_impl_unittest.cc (right): https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc#newcode635 media/filters/audio_renderer_impl_unittest.cc:635: const int kInitialFramesBuffered = 1114; On 2014/04/19 01:00:53, wolenetz ...
6 years, 8 months ago (2014-04-19 01:03:24 UTC) #19
wolenetz
On 2014/04/19 01:03:24, DaleCurtis wrote: > https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc > File media/filters/audio_renderer_impl_unittest.cc (right): > > https://codereview.chromium.org/240123004/diff/80001/media/filters/audio_renderer_impl_unittest.cc#newcode635 > ...
6 years, 8 months ago (2014-04-19 01:04:49 UTC) #20
DaleCurtis
The CQ bit was checked by dalecurtis@chromium.org
6 years, 8 months ago (2014-04-19 04:02:06 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dalecurtis@chromium.org/240123004/100001
6 years, 8 months ago (2014-04-19 04:02:11 UTC) #22
DaleCurtis
The CQ bit was unchecked by dalecurtis@chromium.org
6 years, 8 months ago (2014-04-19 04:08:55 UTC) #23
DaleCurtis
The CQ bit was checked by dalecurtis@chromium.org
6 years, 8 months ago (2014-04-19 04:55:07 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dalecurtis@chromium.org/240123004/100001
6 years, 8 months ago (2014-04-19 04:55:10 UTC) #25
commit-bot: I haz the power
6 years, 8 months ago (2014-04-20 22:04:06 UTC) #26
Message was sent while issue was closed.
Change committed as 264944

Powered by Google App Engine
This is Rietveld 408576698