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

Side by Side Diff: media/base/stream_parser_buffer.h

Issue 1018373003: Improving WebM video duration estimation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing try failure, remove unused variable for some builds. Created 5 years, 8 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/base/decoder_buffer.cc ('k') | media/base/stream_parser_buffer.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_BASE_STREAM_PARSER_BUFFER_H_ 5 #ifndef MEDIA_BASE_STREAM_PARSER_BUFFER_H_
6 #define MEDIA_BASE_STREAM_PARSER_BUFFER_H_ 6 #define MEDIA_BASE_STREAM_PARSER_BUFFER_H_
7 7
8 #include <deque> 8 #include <deque>
9 9
10 #include "media/base/decoder_buffer.h" 10 #include "media/base/decoder_buffer.h"
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 // 163 //
164 // All future timestamp, decode timestamp, config id, or track id changes to 164 // All future timestamp, decode timestamp, config id, or track id changes to
165 // this buffer will be applied to the preroll buffer as well. 165 // this buffer will be applied to the preroll buffer as well.
166 void SetPrerollBuffer(const scoped_refptr<StreamParserBuffer>& preroll); 166 void SetPrerollBuffer(const scoped_refptr<StreamParserBuffer>& preroll);
167 const scoped_refptr<StreamParserBuffer>& preroll_buffer() { 167 const scoped_refptr<StreamParserBuffer>& preroll_buffer() {
168 return preroll_buffer_; 168 return preroll_buffer_;
169 } 169 }
170 170
171 void set_timestamp(base::TimeDelta timestamp) override; 171 void set_timestamp(base::TimeDelta timestamp) override;
172 172
173 bool is_duration_estimated() const { return is_duration_estimated_; }
174
175 void set_is_duration_estimated(bool is_estimated) {
176 is_duration_estimated_ = is_estimated;
177 }
178
173 private: 179 private:
174 StreamParserBuffer(const uint8* data, int data_size, 180 StreamParserBuffer(const uint8* data, int data_size,
175 const uint8* side_data, int side_data_size, 181 const uint8* side_data, int side_data_size,
176 bool is_key_frame, Type type, 182 bool is_key_frame, Type type,
177 TrackId track_id); 183 TrackId track_id);
178 ~StreamParserBuffer() override; 184 ~StreamParserBuffer() override;
179 185
180 DecodeTimestamp decode_timestamp_; 186 DecodeTimestamp decode_timestamp_;
181 int config_id_; 187 int config_id_;
182 Type type_; 188 Type type_;
183 TrackId track_id_; 189 TrackId track_id_;
184 BufferQueue splice_buffers_; 190 BufferQueue splice_buffers_;
185 scoped_refptr<StreamParserBuffer> preroll_buffer_; 191 scoped_refptr<StreamParserBuffer> preroll_buffer_;
192 bool is_duration_estimated_;
186 193
187 DISALLOW_COPY_AND_ASSIGN(StreamParserBuffer); 194 DISALLOW_COPY_AND_ASSIGN(StreamParserBuffer);
188 }; 195 };
189 196
190 } // namespace media 197 } // namespace media
191 198
192 #endif // MEDIA_BASE_STREAM_PARSER_BUFFER_H_ 199 #endif // MEDIA_BASE_STREAM_PARSER_BUFFER_H_
OLDNEW
« no previous file with comments | « media/base/decoder_buffer.cc ('k') | media/base/stream_parser_buffer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698