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

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

Issue 213573003: Revert of Disable audio splice frame generation for now. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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 #include "media/filters/source_buffer_stream.h" 5 #include "media/filters/source_buffer_stream.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 947 matching lines...) Expand 10 before | Expand all | Expand 10 after
958 // position. 958 // position.
959 // TODO(acolwell): Figure out a more elegant way to do this. 959 // TODO(acolwell): Figure out a more elegant way to do this.
960 SeekAndSetSelectedRange(*range_for_next_append_, seek_timestamp); 960 SeekAndSetSelectedRange(*range_for_next_append_, seek_timestamp);
961 temporarily_select_range = true; 961 temporarily_select_range = true;
962 } 962 }
963 } 963 }
964 964
965 // Handle splices between the existing buffers and the new buffers. If a 965 // Handle splices between the existing buffers and the new buffers. If a
966 // splice is generated the timestamp and duration of the first buffer in 966 // splice is generated the timestamp and duration of the first buffer in
967 // |new_buffers| will be modified. 967 // |new_buffers| will be modified.
968 // TODO(dalecurtis): Disabled until issues 356073, 356545 are fixed. 968 GenerateSpliceFrame(new_buffers);
969 // GenerateSpliceFrame(new_buffers);
970 969
971 base::TimeDelta prev_timestamp = last_appended_buffer_timestamp_; 970 base::TimeDelta prev_timestamp = last_appended_buffer_timestamp_;
972 bool prev_is_keyframe = last_appended_buffer_is_keyframe_; 971 bool prev_is_keyframe = last_appended_buffer_is_keyframe_;
973 base::TimeDelta next_timestamp = new_buffers.front()->GetDecodeTimestamp(); 972 base::TimeDelta next_timestamp = new_buffers.front()->GetDecodeTimestamp();
974 bool next_is_keyframe = new_buffers.front()->IsKeyframe(); 973 bool next_is_keyframe = new_buffers.front()->IsKeyframe();
975 974
976 if (prev_timestamp != kNoTimestamp() && prev_timestamp != next_timestamp) { 975 if (prev_timestamp != kNoTimestamp() && prev_timestamp != next_timestamp) {
977 // Clean up the old buffers between the last appended buffer and the 976 // Clean up the old buffers between the last appended buffer and the
978 // beginning of |new_buffers|. 977 // beginning of |new_buffers|.
979 RemoveInternal(prev_timestamp, next_timestamp, true, deleted_buffers); 978 RemoveInternal(prev_timestamp, next_timestamp, true, deleted_buffers);
(...skipping 1202 matching lines...) Expand 10 before | Expand all | Expand 10 after
2182 if (buffer->end_of_stream() || buffer->timestamp() >= end) 2181 if (buffer->end_of_stream() || buffer->timestamp() >= end)
2183 break; 2182 break;
2184 if (buffer->timestamp() + buffer->duration() <= start) 2183 if (buffer->timestamp() + buffer->duration() <= start)
2185 continue; 2184 continue;
2186 buffers->push_back(buffer); 2185 buffers->push_back(buffer);
2187 } 2186 }
2188 return previous_size < buffers->size(); 2187 return previous_size < buffers->size();
2189 } 2188 }
2190 2189
2191 } // namespace media 2190 } // namespace media
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698