OLD | NEW |
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 <stdio.h> | 5 #include <stdio.h> |
6 #include <string.h> | 6 #include <string.h> |
7 | 7 |
8 #include <iostream> | 8 #include <iostream> |
9 #include <queue> | 9 #include <queue> |
10 #include <sstream> | 10 #include <sstream> |
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
240 encoded_data_next_pos_to_decode_(0), | 240 encoded_data_next_pos_to_decode_(0), |
241 next_picture_id_(0), | 241 next_picture_id_(0), |
242 flushing_(false), | 242 flushing_(false), |
243 resetting_(false), | 243 resetting_(false), |
244 total_latency_(0.0), | 244 total_latency_(0.0), |
245 num_pictures_(0) { | 245 num_pictures_(0) { |
246 core_if_ = static_cast<const PPB_Core*>( | 246 core_if_ = static_cast<const PPB_Core*>( |
247 pp::Module::Get()->GetBrowserInterface(PPB_CORE_INTERFACE)); | 247 pp::Module::Get()->GetBrowserInterface(PPB_CORE_INTERFACE)); |
248 | 248 |
249 #if defined USE_VP8_TESTDATA_INSTEAD_OF_H264 | 249 #if defined USE_VP8_TESTDATA_INSTEAD_OF_H264 |
250 const PP_VideoProfile kBitstreamProfile = PP_VIDEOPROFILE_VP8MAIN; | 250 const PP_VideoProfile kBitstreamProfile = PP_VIDEOPROFILE_VP8_ANY; |
251 #else | 251 #else |
252 const PP_VideoProfile kBitstreamProfile = PP_VIDEOPROFILE_H264MAIN; | 252 const PP_VideoProfile kBitstreamProfile = PP_VIDEOPROFILE_H264MAIN; |
253 #endif | 253 #endif |
254 | 254 |
255 assert(!decoder_->is_null()); | 255 assert(!decoder_->is_null()); |
256 decoder_->Initialize(graphics_3d, | 256 decoder_->Initialize(graphics_3d, |
257 kBitstreamProfile, | 257 kBitstreamProfile, |
258 PP_TRUE /* allow_software_fallback */, | 258 PP_TRUE /* allow_software_fallback */, |
259 callback_factory_.NewCallback(&Decoder::InitializeDone)); | 259 callback_factory_.NewCallback(&Decoder::InitializeDone)); |
260 } | 260 } |
(...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
727 }; | 727 }; |
728 | 728 |
729 } // anonymous namespace | 729 } // anonymous namespace |
730 | 730 |
731 namespace pp { | 731 namespace pp { |
732 // Factory function for your specialization of the Module object. | 732 // Factory function for your specialization of the Module object. |
733 Module* CreateModule() { | 733 Module* CreateModule() { |
734 return new MyModule(); | 734 return new MyModule(); |
735 } | 735 } |
736 } // namespace pp | 736 } // namespace pp |
OLD | NEW |