OLD | NEW |
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/base/stream_parser_buffer.h" | 5 #include "media/base/stream_parser_buffer.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "media/base/buffers.h" | 8 #include "media/base/buffers.h" |
9 | 9 |
10 namespace media { | 10 namespace media { |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 pre_splice_buffers.back()->timestamp() + | 134 pre_splice_buffers.back()->timestamp() + |
135 pre_splice_buffers.back()->duration()) - | 135 pre_splice_buffers.back()->duration()) - |
136 first_splice_buffer->timestamp()); | 136 first_splice_buffer->timestamp()); |
137 | 137 |
138 // Copy all pre splice buffers into our wrapper buffer. | 138 // Copy all pre splice buffers into our wrapper buffer. |
139 for (BufferQueue::const_iterator it = pre_splice_buffers.begin(); | 139 for (BufferQueue::const_iterator it = pre_splice_buffers.begin(); |
140 it != pre_splice_buffers.end(); | 140 it != pre_splice_buffers.end(); |
141 ++it) { | 141 ++it) { |
142 const scoped_refptr<StreamParserBuffer>& buffer = *it; | 142 const scoped_refptr<StreamParserBuffer>& buffer = *it; |
143 DCHECK(!buffer->end_of_stream()); | 143 DCHECK(!buffer->end_of_stream()); |
144 DCHECK(buffer->get_splice_buffers().empty()); | 144 DCHECK(buffer->splice_buffers().empty()); |
145 splice_buffers_.push_back(CopyBuffer(*buffer)); | 145 splice_buffers_.push_back(CopyBuffer(*buffer)); |
146 splice_buffers_.back()->set_splice_timestamp(splice_timestamp()); | 146 splice_buffers_.back()->set_splice_timestamp(splice_timestamp()); |
147 } | 147 } |
148 | 148 |
149 splice_buffers_.push_back(overlapping_buffer); | 149 splice_buffers_.push_back(overlapping_buffer); |
150 } | 150 } |
151 | 151 |
152 } // namespace media | 152 } // namespace media |
OLD | NEW |