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

Unified Diff: media/filters/source_buffer_stream_unittest.cc

Issue 149153002: MSE: Add StreamParser buffer remuxing utility and tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased, fixed comments from PS3, and prepped for TrackId unification work. Created 6 years, 10 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
Index: media/filters/source_buffer_stream_unittest.cc
diff --git a/media/filters/source_buffer_stream_unittest.cc b/media/filters/source_buffer_stream_unittest.cc
index 7db62a1b7343b92e1bee11dfb8353ed1f0332216..5c621426fc7cdfb7b413e80993cc9e01b7f371aa 100644
--- a/media/filters/source_buffer_stream_unittest.cc
+++ b/media/filters/source_buffer_stream_unittest.cc
@@ -303,8 +303,10 @@ class SourceBufferStreamTest : public testing::Test {
for (int i = 0; i < number_of_buffers; i++) {
int position = starting_position + i;
bool is_keyframe = position % keyframe_interval == 0;
+ // Buffer type and track ID is meaningless to these tests.
xhwang 2014/02/07 00:09:56 s/is/are
wolenetz 2014/02/07 00:29:18 Done.
scoped_refptr<StreamParserBuffer> buffer =
- StreamParserBuffer::CopyFrom(data, size, is_keyframe);
+ StreamParserBuffer::CopyFrom(data, size, is_keyframe,
+ DemuxerStream::AUDIO, 0);
base::TimeDelta timestamp = frame_duration_ * position;
if (i == 0)
@@ -391,9 +393,10 @@ class SourceBufferStreamTest : public testing::Test {
int time_in_ms;
CHECK(base::StringToInt(timestamps[i], &time_in_ms));
- // Create buffer.
+ // Create buffer. Buffer type and track ID is meaningless to these tests.
xhwang 2014/02/07 00:09:56 ditto
wolenetz 2014/02/07 00:29:18 Done.
scoped_refptr<StreamParserBuffer> buffer =
- StreamParserBuffer::CopyFrom(&kDataA, kDataSize, is_keyframe);
+ StreamParserBuffer::CopyFrom(&kDataA, kDataSize, is_keyframe,
+ DemuxerStream::AUDIO, 0);
base::TimeDelta timestamp =
base::TimeDelta::FromMilliseconds(time_in_ms);
buffer->set_timestamp(timestamp);

Powered by Google App Engine
This is Rietveld 408576698