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/test/pipeline_integration_test_base.h" | 5 #include "media/test/pipeline_integration_test_base.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/memory/scoped_vector.h" | 8 #include "base/memory/scoped_vector.h" |
9 #include "media/base/cdm_context.h" | 9 #include "media/base/cdm_context.h" |
10 #include "media/base/media_log.h" | 10 #include "media/base/media_log.h" |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 } | 62 } |
63 | 63 |
64 void PipelineIntegrationTestBase::OnStatusCallback( | 64 void PipelineIntegrationTestBase::OnStatusCallback( |
65 PipelineStatus status) { | 65 PipelineStatus status) { |
66 pipeline_status_ = status; | 66 pipeline_status_ = status; |
67 message_loop_.PostTask(FROM_HERE, base::MessageLoop::QuitWhenIdleClosure()); | 67 message_loop_.PostTask(FROM_HERE, base::MessageLoop::QuitWhenIdleClosure()); |
68 } | 68 } |
69 | 69 |
70 void PipelineIntegrationTestBase::DemuxerEncryptedMediaInitDataCB( | 70 void PipelineIntegrationTestBase::DemuxerEncryptedMediaInitDataCB( |
71 EmeInitDataType type, | 71 EmeInitDataType type, |
72 const std::vector<uint8>& init_data) { | 72 const std::vector<uint8_t>& init_data) { |
73 DCHECK(!init_data.empty()); | 73 DCHECK(!init_data.empty()); |
74 CHECK(!encrypted_media_init_data_cb_.is_null()); | 74 CHECK(!encrypted_media_init_data_cb_.is_null()); |
75 encrypted_media_init_data_cb_.Run(type, init_data); | 75 encrypted_media_init_data_cb_.Run(type, init_data); |
76 } | 76 } |
77 | 77 |
78 void PipelineIntegrationTestBase::OnEnded() { | 78 void PipelineIntegrationTestBase::OnEnded() { |
79 DCHECK(!ended_); | 79 DCHECK(!ended_); |
80 ended_ = true; | 80 ended_ = true; |
81 pipeline_status_ = PIPELINE_OK; | 81 pipeline_status_ = PIPELINE_OK; |
82 message_loop_.PostTask(FROM_HERE, base::MessageLoop::QuitWhenIdleClosure()); | 82 message_loop_.PostTask(FROM_HERE, base::MessageLoop::QuitWhenIdleClosure()); |
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
354 DCHECK(clockless_playback_); | 354 DCHECK(clockless_playback_); |
355 return clockless_audio_sink_->render_time(); | 355 return clockless_audio_sink_->render_time(); |
356 } | 356 } |
357 | 357 |
358 base::TimeTicks DummyTickClock::NowTicks() { | 358 base::TimeTicks DummyTickClock::NowTicks() { |
359 now_ += base::TimeDelta::FromSeconds(60); | 359 now_ += base::TimeDelta::FromSeconds(60); |
360 return now_; | 360 return now_; |
361 } | 361 } |
362 | 362 |
363 } // namespace media | 363 } // namespace media |
OLD | NEW |