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

Unified Diff: media/base/demuxer.h

Issue 1922333002: Implement mapping blink track id to demuxer streams (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: CR feedback Created 4 years, 7 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 | « no previous file | media/base/media_tracks.h » ('j') | media/base/media_tracks.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/demuxer.h
diff --git a/media/base/demuxer.h b/media/base/demuxer.h
index 9c6607f9cb212555c5eee02d494b2b2e407d52a5..3f533b33151fea3c7f85a36efafde522a663d784 100644
--- a/media/base/demuxer.h
+++ b/media/base/demuxer.h
@@ -67,7 +67,7 @@ class MEDIA_EXPORT Demuxer : public DemuxerStreamProvider {
const std::vector<uint8_t>& init_data)>;
// Notifies demuxer clients that media track configuration has been updated
- // (e.g. the inital stream metadata has been parsed successfully, or a new
+ // (e.g. the initial stream metadata has been parsed successfully, or a new
// init segment has been parsed successfully in MSE case).
using MediaTracksUpdatedCB =
base::Callback<void(std::unique_ptr<MediaTracks>)>;
@@ -135,6 +135,18 @@ class MEDIA_EXPORT Demuxer : public DemuxerStreamProvider {
// Returns the memory usage in bytes for the demuxer.
virtual int64_t GetMemoryUsage() const = 0;
+ // Notifies the demuxer that blink track ids have been assigned to |tracks|.
xhwang 2016/06/03 18:52:45 nit: "media" doesn't know about blink. So the |tra
+ // The |track_ids| collection must contain blink track ids in the same
+ // sequence as media tracks in |tracks|. The collection sizes must be the
+ // same.
+ virtual void OnTrackIdsAssigned(const MediaTracks& tracks,
+ const std::vector<unsigned>& track_ids) = 0;
xhwang 2016/06/03 18:52:45 We don't like to use "unsigned" or "unsigned int"
+
+ // Finds a DemuxerStream corresponding to the given blink |track_id|. Note
+ // that the input track id is blink track id and not bytestream track id.
+ virtual const DemuxerStream* GetDemuxerStreamByTrackId(
+ unsigned track_id) const = 0;
+
private:
DISALLOW_COPY_AND_ASSIGN(Demuxer);
};
« no previous file with comments | « no previous file | media/base/media_tracks.h » ('j') | media/base/media_tracks.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698