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

Unified Diff: media/formats/mp4/mp4_stream_parser.cc

Issue 149153002: MSE: Add StreamParser buffer remuxing utility and tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments from PS4 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
« no previous file with comments | « media/formats/mp3/mp3_stream_parser.cc ('k') | media/formats/webm/webm_cluster_parser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/formats/mp4/mp4_stream_parser.cc
diff --git a/media/formats/mp4/mp4_stream_parser.cc b/media/formats/mp4/mp4_stream_parser.cc
index b5ab62d6f0b8f13ebceef01298f758c7419c95cd..e6de37e6ee76b77fc45a9127444045309c4b79c3 100644
--- a/media/formats/mp4/mp4_stream_parser.cc
+++ b/media/formats/mp4/mp4_stream_parser.cc
@@ -497,9 +497,15 @@ bool MP4StreamParser::EnqueueSample(BufferQueue* audio_buffers,
new DecryptConfig("1", "", std::vector<SubsampleEntry>()));
}
+ StreamParserBuffer::Type buffer_type = audio ? DemuxerStream::AUDIO :
+ DemuxerStream::VIDEO;
+
+ // TODO(wolenetz/acolwell): Validate and use a common cross-parser TrackId
+ // type and allow multiple tracks for same media type, if applicable. See
+ // https://crbug.com/341581.
scoped_refptr<StreamParserBuffer> stream_buf =
- StreamParserBuffer::CopyFrom(&frame_buf[0], frame_buf.size(),
- runs_->is_keyframe());
+ StreamParserBuffer::CopyFrom(&frame_buf[0], frame_buf.size(),
+ runs_->is_keyframe(), buffer_type, 0);
if (decrypt_config)
stream_buf->set_decrypt_config(decrypt_config.Pass());
« no previous file with comments | « media/formats/mp3/mp3_stream_parser.cc ('k') | media/formats/webm/webm_cluster_parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698