| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef CONTENT_RENDERER_PEPPER_PLATFORM_VIDEO_DECODER_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_PEPPER_PLATFORM_VIDEO_DECODER_IMPL_H_ |
| 6 #define CONTENT_RENDERER_PEPPER_PLATFORM_VIDEO_DECODER_IMPL_H_ | 6 #define CONTENT_RENDERER_PEPPER_PLATFORM_VIDEO_DECODER_IMPL_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 public: | 23 public: |
| 24 PlatformVideoDecoderImpl( | 24 PlatformVideoDecoderImpl( |
| 25 media::VideoDecodeAccelerator::Client* client, | 25 media::VideoDecodeAccelerator::Client* client, |
| 26 int32 command_buffer_route_id, | 26 int32 command_buffer_route_id, |
| 27 gpu::CommandBufferHelper* cmd_buffer_helper); | 27 gpu::CommandBufferHelper* cmd_buffer_helper); |
| 28 | 28 |
| 29 // PlatformVideoDecoder (a.k.a. VideoDecodeAccelerator) implementation. | 29 // PlatformVideoDecoder (a.k.a. VideoDecodeAccelerator) implementation. |
| 30 virtual bool Initialize(const std::vector<uint32>& configs) OVERRIDE; | 30 virtual bool Initialize(const std::vector<uint32>& configs) OVERRIDE; |
| 31 virtual void Decode( | 31 virtual void Decode( |
| 32 const media::BitstreamBuffer& bitstream_buffer) OVERRIDE; | 32 const media::BitstreamBuffer& bitstream_buffer) OVERRIDE; |
| 33 virtual void AssignGLESBuffers( | 33 virtual void AssignPictureBuffers( |
| 34 const std::vector<media::GLESBuffer>& buffers) OVERRIDE; | 34 const std::vector<media::PictureBuffer>& buffers) OVERRIDE; |
| 35 virtual void ReusePictureBuffer(int32 picture_buffer_id); | 35 virtual void ReusePictureBuffer(int32 picture_buffer_id); |
| 36 virtual void Flush() OVERRIDE; | 36 virtual void Flush() OVERRIDE; |
| 37 virtual void Reset() OVERRIDE; | 37 virtual void Reset() OVERRIDE; |
| 38 virtual void Destroy() OVERRIDE; | 38 virtual void Destroy() OVERRIDE; |
| 39 | 39 |
| 40 // VideoDecodeAccelerator::Client implementation. | 40 // VideoDecodeAccelerator::Client implementation. |
| 41 virtual void ProvidePictureBuffers( | 41 virtual void ProvidePictureBuffers( |
| 42 uint32 requested_num_of_buffers, | 42 uint32 requested_num_of_buffers, const gfx::Size& dimensions) OVERRIDE; |
| 43 const gfx::Size& dimensions, | |
| 44 media::VideoDecodeAccelerator::MemoryType type) OVERRIDE; | |
| 45 virtual void PictureReady(const media::Picture& picture) OVERRIDE; | 43 virtual void PictureReady(const media::Picture& picture) OVERRIDE; |
| 46 virtual void DismissPictureBuffer(int32 picture_buffer_id) OVERRIDE; | 44 virtual void DismissPictureBuffer(int32 picture_buffer_id) OVERRIDE; |
| 47 virtual void NotifyInitializeDone() OVERRIDE; | 45 virtual void NotifyInitializeDone() OVERRIDE; |
| 48 virtual void NotifyEndOfStream() OVERRIDE; | 46 virtual void NotifyEndOfStream() OVERRIDE; |
| 49 virtual void NotifyError( | 47 virtual void NotifyError( |
| 50 media::VideoDecodeAccelerator::Error error) OVERRIDE; | 48 media::VideoDecodeAccelerator::Error error) OVERRIDE; |
| 51 virtual void NotifyEndOfBitstreamBuffer(int32 bitstream_buffer_id) OVERRIDE; | 49 virtual void NotifyEndOfBitstreamBuffer(int32 bitstream_buffer_id) OVERRIDE; |
| 52 virtual void NotifyFlushDone() OVERRIDE; | 50 virtual void NotifyFlushDone() OVERRIDE; |
| 53 virtual void NotifyResetDone() OVERRIDE; | 51 virtual void NotifyResetDone() OVERRIDE; |
| 54 | 52 |
| (...skipping 11 matching lines...) Expand all Loading... |
| 66 | 64 |
| 67 // Helper for the command buffer associated with video decoder's context. | 65 // Helper for the command buffer associated with video decoder's context. |
| 68 gpu::CommandBufferHelper* cmd_buffer_helper_; | 66 gpu::CommandBufferHelper* cmd_buffer_helper_; |
| 69 | 67 |
| 70 // Holds a GpuVideoDecodeAcceleratorHost. | 68 // Holds a GpuVideoDecodeAcceleratorHost. |
| 71 scoped_refptr<media::VideoDecodeAccelerator> decoder_; | 69 scoped_refptr<media::VideoDecodeAccelerator> decoder_; |
| 72 | 70 |
| 73 DISALLOW_COPY_AND_ASSIGN(PlatformVideoDecoderImpl); | 71 DISALLOW_COPY_AND_ASSIGN(PlatformVideoDecoderImpl); |
| 74 }; | 72 }; |
| 75 #endif // CONTENT_RENDERER_PEPPER_PLATFORM_VIDEO_DECODER_IMPL_H_ | 73 #endif // CONTENT_RENDERER_PEPPER_PLATFORM_VIDEO_DECODER_IMPL_H_ |
| OLD | NEW |