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

Side by Side Diff: media/filters/chunk_demuxer.h

Issue 2718483003: Use base::Optional for selected video track. (Closed)
Patch Set: rebase Created 3 years, 9 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 unified diff | Download patch
« no previous file with comments | « media/blink/webmediaplayer_impl.cc ('k') | media/filters/chunk_demuxer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MEDIA_FILTERS_CHUNK_DEMUXER_H_ 5 #ifndef MEDIA_FILTERS_CHUNK_DEMUXER_H_
6 #define MEDIA_FILTERS_CHUNK_DEMUXER_H_ 6 #define MEDIA_FILTERS_CHUNK_DEMUXER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 void RemoveId(const std::string& id); 232 void RemoveId(const std::string& id);
233 233
234 // Gets the currently buffered ranges for the specified ID. 234 // Gets the currently buffered ranges for the specified ID.
235 Ranges<base::TimeDelta> GetBufferedRanges(const std::string& id) const; 235 Ranges<base::TimeDelta> GetBufferedRanges(const std::string& id) const;
236 236
237 // Gets the highest buffered PTS for the specified |id|. If there is nothing 237 // Gets the highest buffered PTS for the specified |id|. If there is nothing
238 // buffered, returns base::TimeDelta(). 238 // buffered, returns base::TimeDelta().
239 base::TimeDelta GetHighestPresentationTimestamp(const std::string& id) const; 239 base::TimeDelta GetHighestPresentationTimestamp(const std::string& id) const;
240 240
241 void OnEnabledAudioTracksChanged(const std::vector<MediaTrack::Id>& track_ids, 241 void OnEnabledAudioTracksChanged(const std::vector<MediaTrack::Id>& track_ids,
242 base::TimeDelta currTime) override; 242 base::TimeDelta curr_time) override;
243 // |track_ids| is either empty or contains a single video track id. 243 // |track_id| either contains the selected video track id or is null,
244 void OnSelectedVideoTrackChanged(const std::vector<MediaTrack::Id>& track_ids, 244 // indicating that all video tracks are deselected/disabled.
245 base::TimeDelta currTime) override; 245 void OnSelectedVideoTrackChanged(base::Optional<MediaTrack::Id> track_id,
246 base::TimeDelta curr_time) override;
246 247
247 // Appends media data to the source buffer associated with |id|, applying 248 // Appends media data to the source buffer associated with |id|, applying
248 // and possibly updating |*timestamp_offset| during coded frame processing. 249 // and possibly updating |*timestamp_offset| during coded frame processing.
249 // |append_window_start| and |append_window_end| correspond to the MSE spec's 250 // |append_window_start| and |append_window_end| correspond to the MSE spec's
250 // similarly named source buffer attributes that are used in coded frame 251 // similarly named source buffer attributes that are used in coded frame
251 // processing. Returns true on success, false if the caller needs to run the 252 // processing. Returns true on success, false if the caller needs to run the
252 // append error algorithm with decode error parameter set to true. 253 // append error algorithm with decode error parameter set to true.
253 bool AppendData(const std::string& id, 254 bool AppendData(const std::string& id,
254 const uint8_t* data, 255 const uint8_t* data,
255 size_t length, 256 size_t length,
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
455 int detected_text_track_count_; 456 int detected_text_track_count_;
456 457
457 std::map<MediaTrack::Id, ChunkDemuxerStream*> track_id_to_demux_stream_map_; 458 std::map<MediaTrack::Id, ChunkDemuxerStream*> track_id_to_demux_stream_map_;
458 459
459 DISALLOW_COPY_AND_ASSIGN(ChunkDemuxer); 460 DISALLOW_COPY_AND_ASSIGN(ChunkDemuxer);
460 }; 461 };
461 462
462 } // namespace media 463 } // namespace media
463 464
464 #endif // MEDIA_FILTERS_CHUNK_DEMUXER_H_ 465 #endif // MEDIA_FILTERS_CHUNK_DEMUXER_H_
OLDNEW
« no previous file with comments | « media/blink/webmediaplayer_impl.cc ('k') | media/filters/chunk_demuxer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698