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 // The bulk of this file is support code; sorry about that. Here's an overview | 5 // The bulk of this file is support code; sorry about that. Here's an overview |
6 // to hopefully help readers of this code: | 6 // to hopefully help readers of this code: |
7 // - RenderingHelper is charged with interacting with X11/{EGL/GLES2,GLX/GL} or | 7 // - RenderingHelper is charged with interacting with X11/{EGL/GLES2,GLX/GL} or |
8 // Win/EGL. | 8 // Win/EGL. |
9 // - ClientState is an enum for the state of the decode client used by the test. | 9 // - ClientState is an enum for the state of the decode client used by the test. |
10 // - ClientStateNotification is a barrier abstraction that allows the test code | 10 // - ClientStateNotification is a barrier abstraction that allows the test code |
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 int delay_reuse_after_frame_num, | 228 int delay_reuse_after_frame_num, |
229 int decode_calls_per_second, | 229 int decode_calls_per_second, |
230 bool render_as_thumbnails); | 230 bool render_as_thumbnails); |
231 virtual ~GLRenderingVDAClient(); | 231 virtual ~GLRenderingVDAClient(); |
232 void CreateAndStartDecoder(); | 232 void CreateAndStartDecoder(); |
233 | 233 |
234 // VideoDecodeAccelerator::Client implementation. | 234 // VideoDecodeAccelerator::Client implementation. |
235 // The heart of the Client. | 235 // The heart of the Client. |
236 virtual void ProvidePictureBuffers(uint32 requested_num_of_buffers, | 236 virtual void ProvidePictureBuffers(uint32 requested_num_of_buffers, |
237 const gfx::Size& dimensions, | 237 const gfx::Size& dimensions, |
238 uint32 texture_target) OVERRIDE; | 238 uint32 texture_target) override; |
239 virtual void DismissPictureBuffer(int32 picture_buffer_id) OVERRIDE; | 239 virtual void DismissPictureBuffer(int32 picture_buffer_id) override; |
240 virtual void PictureReady(const media::Picture& picture) OVERRIDE; | 240 virtual void PictureReady(const media::Picture& picture) override; |
241 // Simple state changes. | 241 // Simple state changes. |
242 virtual void NotifyEndOfBitstreamBuffer(int32 bitstream_buffer_id) OVERRIDE; | 242 virtual void NotifyEndOfBitstreamBuffer(int32 bitstream_buffer_id) override; |
243 virtual void NotifyFlushDone() OVERRIDE; | 243 virtual void NotifyFlushDone() override; |
244 virtual void NotifyResetDone() OVERRIDE; | 244 virtual void NotifyResetDone() override; |
245 virtual void NotifyError(VideoDecodeAccelerator::Error error) OVERRIDE; | 245 virtual void NotifyError(VideoDecodeAccelerator::Error error) override; |
246 | 246 |
247 void OutputFrameDeliveryTimes(base::File* output); | 247 void OutputFrameDeliveryTimes(base::File* output); |
248 | 248 |
249 // Simple getters for inspecting the state of the Client. | 249 // Simple getters for inspecting the state of the Client. |
250 int num_done_bitstream_buffers() { return num_done_bitstream_buffers_; } | 250 int num_done_bitstream_buffers() { return num_done_bitstream_buffers_; } |
251 int num_skipped_fragments() { return num_skipped_fragments_; } | 251 int num_skipped_fragments() { return num_skipped_fragments_; } |
252 int num_queued_fragments() { return num_queued_fragments_; } | 252 int num_queued_fragments() { return num_queued_fragments_; } |
253 int num_decoded_frames() { return num_decoded_frames_; } | 253 int num_decoded_frames() { return num_decoded_frames_; } |
254 double frames_per_second(); | 254 double frames_per_second(); |
255 // Return the median of the decode time of all decoded frames. | 255 // Return the median of the decode time of all decoded frames. |
(...skipping 1173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1429 if (it->first == "v" || it->first == "vmodule") | 1429 if (it->first == "v" || it->first == "vmodule") |
1430 continue; | 1430 continue; |
1431 LOG(FATAL) << "Unexpected switch: " << it->first << ":" << it->second; | 1431 LOG(FATAL) << "Unexpected switch: " << it->first << ":" << it->second; |
1432 } | 1432 } |
1433 | 1433 |
1434 base::ShadowingAtExitManager at_exit_manager; | 1434 base::ShadowingAtExitManager at_exit_manager; |
1435 content::RenderingHelper::InitializeOneOff(); | 1435 content::RenderingHelper::InitializeOneOff(); |
1436 | 1436 |
1437 return RUN_ALL_TESTS(); | 1437 return RUN_ALL_TESTS(); |
1438 } | 1438 } |
OLD | NEW |