Chromium Code Reviews| 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 <algorithm> | 5 #include <algorithm> |
| 6 #include <string> | 6 #include <string> |
| 7 | 7 |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/bind_helpers.h" | 9 #include "base/bind_helpers.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 69 for (StreamParser::BufferQueue::const_iterator buf = bufs.begin(); | 69 for (StreamParser::BufferQueue::const_iterator buf = bufs.begin(); |
| 70 buf != bufs.end(); buf++) { | 70 buf != bufs.end(); buf++) { |
| 71 DVLOG(3) << " n=" << buf - bufs.begin() | 71 DVLOG(3) << " n=" << buf - bufs.begin() |
| 72 << ", size=" << (*buf)->GetDataSize() | 72 << ", size=" << (*buf)->GetDataSize() |
| 73 << ", dur=" << (*buf)->GetDuration().InMilliseconds(); | 73 << ", dur=" << (*buf)->GetDuration().InMilliseconds(); |
| 74 EXPECT_GE((*buf)->GetTimestamp(), segment_start_); | 74 EXPECT_GE((*buf)->GetTimestamp(), segment_start_); |
| 75 } | 75 } |
| 76 return true; | 76 return true; |
| 77 } | 77 } |
| 78 | 78 |
| 79 bool KeyNeededF(scoped_array<uint8> init_data, int init_data_size) { | 79 bool KeyNeededF(const std::string& type, |
| 80 DVLOG(1) << "KeyNeededF: " << init_data_size; | 80 scoped_array<uint8> init_data, int init_data_size) { |
| 81 DVLOG(1) << "KeyNeededF: type=" << type | |
|
ddorwin
2012/10/27 00:08:26
Shouldn't we just EXPECT_STREQ the type?
xhwang
2012/10/27 00:50:14
Done.
| |
| 82 << ", init_data_size=" << init_data_size; | |
| 81 return true; | 83 return true; |
| 82 } | 84 } |
| 83 | 85 |
| 84 void NewSegmentF(TimeDelta start_dts) { | 86 void NewSegmentF(TimeDelta start_dts) { |
| 85 DVLOG(1) << "NewSegmentF: " << start_dts.InMilliseconds(); | 87 DVLOG(1) << "NewSegmentF: " << start_dts.InMilliseconds(); |
| 86 segment_start_ = start_dts; | 88 segment_start_ = start_dts; |
| 87 } | 89 } |
| 88 | 90 |
| 89 void EndOfSegmentF() { | 91 void EndOfSegmentF() { |
| 90 DVLOG(1) << "EndOfSegmentF()"; | 92 DVLOG(1) << "EndOfSegmentF()"; |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 154 EXPECT_TRUE(AppendDataInPieces(buffer->GetData(), | 156 EXPECT_TRUE(AppendDataInPieces(buffer->GetData(), |
| 155 buffer->GetDataSize(), | 157 buffer->GetDataSize(), |
| 156 512)); | 158 512)); |
| 157 } | 159 } |
| 158 | 160 |
| 159 // TODO(strobe): Create and test media which uses CENC auxiliary info stored | 161 // TODO(strobe): Create and test media which uses CENC auxiliary info stored |
| 160 // inside a private box | 162 // inside a private box |
| 161 | 163 |
| 162 } // namespace mp4 | 164 } // namespace mp4 |
| 163 } // namespace media | 165 } // namespace media |
| OLD | NEW |