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

Side by Side Diff: media/webm/webm_cluster_parser.h

Issue 15342004: Adding VP8 Alpha support in Media Source (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: addressing comments Created 7 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 unified diff | Download patch
« no previous file with comments | « media/filters/pipeline_integration_test.cc ('k') | media/webm/webm_cluster_parser.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_WEBM_WEBM_CLUSTER_PARSER_H_ 5 #ifndef MEDIA_WEBM_WEBM_CLUSTER_PARSER_H_
6 #define MEDIA_WEBM_WEBM_CLUSTER_PARSER_H_ 6 #define MEDIA_WEBM_WEBM_CLUSTER_PARSER_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 bool cluster_ended() const { return cluster_ended_; } 103 bool cluster_ended() const { return cluster_ended_; }
104 104
105 private: 105 private:
106 // WebMParserClient methods. 106 // WebMParserClient methods.
107 virtual WebMParserClient* OnListStart(int id) OVERRIDE; 107 virtual WebMParserClient* OnListStart(int id) OVERRIDE;
108 virtual bool OnListEnd(int id) OVERRIDE; 108 virtual bool OnListEnd(int id) OVERRIDE;
109 virtual bool OnUInt(int id, int64 val) OVERRIDE; 109 virtual bool OnUInt(int id, int64 val) OVERRIDE;
110 virtual bool OnBinary(int id, const uint8* data, int size) OVERRIDE; 110 virtual bool OnBinary(int id, const uint8* data, int size) OVERRIDE;
111 111
112 bool ParseBlock(bool is_simple_block, const uint8* buf, int size, 112 bool ParseBlock(bool is_simple_block, const uint8* buf, int size,
113 int duration); 113 const uint8* additional, int additional_size, int duration);
114 bool OnBlock(bool is_simple_block, int track_num, int timecode, int duration, 114 bool OnBlock(bool is_simple_block, int track_num, int timecode, int duration,
115 int flags, const uint8* data, int size); 115 int flags, const uint8* data, int size,
116 const uint8* additional, int additional_size);
116 117
117 // Resets the Track objects associated with each text track. 118 // Resets the Track objects associated with each text track.
118 void ResetTextTracks(); 119 void ResetTextTracks();
119 120
120 // Search for the indicated track_num among the text tracks. Returns NULL 121 // Search for the indicated track_num among the text tracks. Returns NULL
121 // if that track num is not a text track. 122 // if that track num is not a text track.
122 Track* FindTextTrack(int track_num); 123 Track* FindTextTrack(int track_num);
123 124
124 double timecode_multiplier_; // Multiplier used to convert timecodes into 125 double timecode_multiplier_; // Multiplier used to convert timecodes into
125 // microseconds. 126 // microseconds.
126 std::set<int64> ignored_tracks_; 127 std::set<int64> ignored_tracks_;
127 std::string audio_encryption_key_id_; 128 std::string audio_encryption_key_id_;
128 std::string video_encryption_key_id_; 129 std::string video_encryption_key_id_;
129 130
130 WebMListParser parser_; 131 WebMListParser parser_;
131 132
132 int64 last_block_timecode_; 133 int64 last_block_timecode_;
133 scoped_ptr<uint8[]> block_data_; 134 scoped_ptr<uint8[]> block_data_;
134 int block_data_size_; 135 int block_data_size_;
135 int64 block_duration_; 136 int64 block_duration_;
137 int64 block_add_id_;
138 scoped_ptr<uint8[]> block_additional_data_;
139 int block_additional_data_size_;
136 140
137 int64 cluster_timecode_; 141 int64 cluster_timecode_;
138 base::TimeDelta cluster_start_time_; 142 base::TimeDelta cluster_start_time_;
139 bool cluster_ended_; 143 bool cluster_ended_;
140 144
141 Track audio_; 145 Track audio_;
142 Track video_; 146 Track video_;
143 TextTrackMap text_track_map_; 147 TextTrackMap text_track_map_;
144 LogCB log_cb_; 148 LogCB log_cb_;
145 149
146 DISALLOW_IMPLICIT_CONSTRUCTORS(WebMClusterParser); 150 DISALLOW_IMPLICIT_CONSTRUCTORS(WebMClusterParser);
147 }; 151 };
148 152
149 } // namespace media 153 } // namespace media
150 154
151 #endif // MEDIA_WEBM_WEBM_CLUSTER_PARSER_H_ 155 #endif // MEDIA_WEBM_WEBM_CLUSTER_PARSER_H_
OLDNEW
« no previous file with comments | « media/filters/pipeline_integration_test.cc ('k') | media/webm/webm_cluster_parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698