OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <stddef.h> | 5 #include <stddef.h> |
6 #include <stdint.h> | 6 #include <stdint.h> |
7 | 7 |
8 #include <algorithm> | 8 #include <algorithm> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
149 DVLOG(1) << "KeyNeededF: " << init_data.size(); | 149 DVLOG(1) << "KeyNeededF: " << init_data.size(); |
150 EXPECT_EQ(EmeInitDataType::CENC, type); | 150 EXPECT_EQ(EmeInitDataType::CENC, type); |
151 EXPECT_FALSE(init_data.empty()); | 151 EXPECT_FALSE(init_data.empty()); |
152 } | 152 } |
153 | 153 |
154 void NewSegmentF() { | 154 void NewSegmentF() { |
155 DVLOG(1) << "NewSegmentF"; | 155 DVLOG(1) << "NewSegmentF"; |
156 lower_bound_ = kNoDecodeTimestamp(); | 156 lower_bound_ = kNoDecodeTimestamp(); |
157 } | 157 } |
158 | 158 |
159 void EndOfSegmentF() { | 159 bool EndOfSegmentF() { |
160 DVLOG(1) << "EndOfSegmentF()"; | 160 DVLOG(1) << "EndOfSegmentF()"; |
161 lower_bound_ = | 161 lower_bound_ = |
162 DecodeTimestamp::FromPresentationTime(base::TimeDelta::Max()); | 162 DecodeTimestamp::FromPresentationTime(base::TimeDelta::Max()); |
163 return true; // BIG TODO test ! | |
chcunningham
2016/01/07 22:23:57
:)
wolenetz
2016/01/16 01:23:35
No longer changed (PS5, at least).
| |
163 } | 164 } |
164 | 165 |
165 void InitializeParserAndExpectLiveness( | 166 void InitializeParserAndExpectLiveness( |
166 DemuxerStream::Liveness expected_liveness) { | 167 DemuxerStream::Liveness expected_liveness) { |
167 parser_->Init( | 168 parser_->Init( |
168 base::Bind(&MP4StreamParserTest::InitF, base::Unretained(this), | 169 base::Bind(&MP4StreamParserTest::InitF, base::Unretained(this), |
169 expected_liveness), | 170 expected_liveness), |
170 base::Bind(&MP4StreamParserTest::NewConfigF, base::Unretained(this)), | 171 base::Bind(&MP4StreamParserTest::NewConfigF, base::Unretained(this)), |
171 base::Bind(&MP4StreamParserTest::NewBuffersF, base::Unretained(this)), | 172 base::Bind(&MP4StreamParserTest::NewBuffersF, base::Unretained(this)), |
172 true, | 173 true, |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
336 scoped_refptr<DecoderBuffer> buffer = | 337 scoped_refptr<DecoderBuffer> buffer = |
337 ReadTestDataFile("bear-640x360-non_square_pixel-with_pasp.mp4"); | 338 ReadTestDataFile("bear-640x360-non_square_pixel-with_pasp.mp4"); |
338 | 339 |
339 EXPECT_MEDIA_LOG(VideoCodecLog("avc1.6401e")); | 340 EXPECT_MEDIA_LOG(VideoCodecLog("avc1.6401e")); |
340 EXPECT_TRUE(AppendDataInPieces(buffer->data(), buffer->data_size(), 512)); | 341 EXPECT_TRUE(AppendDataInPieces(buffer->data(), buffer->data_size(), 512)); |
341 EXPECT_EQ(gfx::Size(639, 360), video_decoder_config_.natural_size()); | 342 EXPECT_EQ(gfx::Size(639, 360), video_decoder_config_.natural_size()); |
342 } | 343 } |
343 | 344 |
344 } // namespace mp4 | 345 } // namespace mp4 |
345 } // namespace media | 346 } // namespace media |
OLD | NEW |