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

Unified Diff: media/formats/mp2t/mp2t_stream_parser_unittest.cc

Issue 143973009: SourceState: Coalesce OnNewBuffers() CB to include OnTextBuffers() behavior (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address PS2 comments Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/formats/mp2t/mp2t_stream_parser.cc ('k') | media/formats/mp3/mp3_stream_parser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/formats/mp2t/mp2t_stream_parser_unittest.cc
diff --git a/media/formats/mp2t/mp2t_stream_parser_unittest.cc b/media/formats/mp2t/mp2t_stream_parser_unittest.cc
index a88e40e9a07a17f799dd8769a59db466ca6e573e..02370f2e6bb0a1f88e6c8b7b3fb9984c45e18f97 100644
--- a/media/formats/mp2t/mp2t_stream_parser_unittest.cc
+++ b/media/formats/mp2t/mp2t_stream_parser_unittest.cc
@@ -83,12 +83,18 @@ class Mp2tStreamParserTest : public testing::Test {
}
bool OnNewBuffers(const StreamParser::BufferQueue& audio_buffers,
- const StreamParser::BufferQueue& video_buffers) {
+ const StreamParser::BufferQueue& video_buffers,
+ const StreamParser::TextBufferQueueMap& text_map) {
DumpBuffers("audio_buffers", audio_buffers);
DumpBuffers("video_buffers", video_buffers);
audio_frame_count_ += audio_buffers.size();
video_frame_count_ += video_buffers.size();
+ // TODO(wolenetz/acolwell): Add text track support to more MSE parsers. See
+ // http://crbug.com/336926.
+ if (!text_map.empty())
+ return false;
+
if (video_min_dts_ == kNoTimestamp() && !video_buffers.empty())
video_min_dts_ = video_buffers.front()->GetDecodeTimestamp();
if (!video_buffers.empty()) {
@@ -126,7 +132,7 @@ class Mp2tStreamParserTest : public testing::Test {
base::Unretained(this)),
base::Bind(&Mp2tStreamParserTest::OnNewBuffers,
base::Unretained(this)),
- StreamParser::NewTextBuffersCB(),
+ true,
base::Bind(&Mp2tStreamParserTest::OnKeyNeeded,
base::Unretained(this)),
base::Bind(&Mp2tStreamParserTest::OnNewSegment,
« no previous file with comments | « media/formats/mp2t/mp2t_stream_parser.cc ('k') | media/formats/mp3/mp3_stream_parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698