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

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

Issue 10690124: Revert 145965 - Make sure previous seek points in SourceBufferStream are ignored during overlaps (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | media/filters/source_buffer_stream.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_SOURCE_BUFFER_STREAM_H_ 5 #ifndef MEDIA_FILTERS_SOURCE_BUFFER_STREAM_H_
6 #define MEDIA_FILTERS_SOURCE_BUFFER_STREAM_H_ 6 #define MEDIA_FILTERS_SOURCE_BUFFER_STREAM_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <list> 9 #include <list>
10 #include <utility> 10 #include <utility>
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 RangeList::iterator FindExistingRangeFor(base::TimeDelta start_timestamp); 148 RangeList::iterator FindExistingRangeFor(base::TimeDelta start_timestamp);
149 149
150 // Inserts |new_range| into |ranges_| preserving sorted order. Returns an 150 // Inserts |new_range| into |ranges_| preserving sorted order. Returns an
151 // iterator in |ranges_| that points to |new_range|. 151 // iterator in |ranges_| that points to |new_range|.
152 RangeList::iterator AddToRanges(SourceBufferRange* new_range); 152 RangeList::iterator AddToRanges(SourceBufferRange* new_range);
153 153
154 // Returns an iterator that points to the place in |ranges_| where 154 // Returns an iterator that points to the place in |ranges_| where
155 // |selected_range_| lives. 155 // |selected_range_| lives.
156 RangeList::iterator GetSelectedRangeItr(); 156 RangeList::iterator GetSelectedRangeItr();
157 157
158 // Sets the |selected_range_| to |range| and resets the next buffer position
159 // for the previous |selected_range_|.
160 void SetSelectedRange(SourceBufferRange* range);
161
162 // Returns true if the timestamps of |buffers| are monotonically increasing 158 // Returns true if the timestamps of |buffers| are monotonically increasing
163 // since the previous append to the media segment, false otherwise. 159 // since the previous append to the media segment, false otherwise.
164 bool IsMonotonicallyIncreasing(const BufferQueue& buffers); 160 bool IsMonotonicallyIncreasing(const BufferQueue& buffers);
165 161
166 // Returns true if |selected_range_| is the only range in |ranges_| that
167 // HasNextBufferPosition().
168 bool OnlySelectedRangeIsSeeked() const;
169
170 // Measures the distances between buffer timestamps and tracks the max. 162 // Measures the distances between buffer timestamps and tracks the max.
171 void UpdateMaxInterbufferDistance(const BufferQueue& buffers); 163 void UpdateMaxInterbufferDistance(const BufferQueue& buffers);
172 164
173 // List of disjoint buffered ranges, ordered by start time. 165 // List of disjoint buffered ranges, ordered by start time.
174 RangeList ranges_; 166 RangeList ranges_;
175 167
176 AudioDecoderConfig audio_config_; 168 AudioDecoderConfig audio_config_;
177 VideoDecoderConfig video_config_; 169 VideoDecoderConfig video_config_;
178 170
179 // True if more data needs to be appended before the Seek() can complete, 171 // True if more data needs to be appended before the Seek() can complete,
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 203
212 // Stores the largest distance between two adjacent buffers in this stream. 204 // Stores the largest distance between two adjacent buffers in this stream.
213 base::TimeDelta max_interbuffer_distance_; 205 base::TimeDelta max_interbuffer_distance_;
214 206
215 DISALLOW_COPY_AND_ASSIGN(SourceBufferStream); 207 DISALLOW_COPY_AND_ASSIGN(SourceBufferStream);
216 }; 208 };
217 209
218 } // namespace media 210 } // namespace media
219 211
220 #endif // MEDIA_FILTERS_SOURCE_BUFFER_STREAM_H_ 212 #endif // MEDIA_FILTERS_SOURCE_BUFFER_STREAM_H_
OLDNEW
« no previous file with comments | « no previous file | media/filters/source_buffer_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698