| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_COMMON_GPU_MEDIA_GPU_VIDEO_ENCODE_ACCELERATOR_H_ | 5 #ifndef CONTENT_COMMON_GPU_MEDIA_GPU_VIDEO_ENCODE_ACCELERATOR_H_ |
| 6 #define CONTENT_COMMON_GPU_MEDIA_GPU_VIDEO_ENCODE_ACCELERATOR_H_ | 6 #define CONTENT_COMMON_GPU_MEDIA_GPU_VIDEO_ENCODE_ACCELERATOR_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 | 69 |
| 70 private: | 70 private: |
| 71 typedef scoped_ptr<media::VideoEncodeAccelerator>(*CreateVEAFp)(); | 71 typedef scoped_ptr<media::VideoEncodeAccelerator>(*CreateVEAFp)(); |
| 72 | 72 |
| 73 // Return a set of VEA Create function pointers applicable to the current | 73 // Return a set of VEA Create function pointers applicable to the current |
| 74 // platform. | 74 // platform. |
| 75 static std::vector<CreateVEAFp> CreateVEAFps(); | 75 static std::vector<CreateVEAFp> CreateVEAFps(); |
| 76 static scoped_ptr<media::VideoEncodeAccelerator> CreateV4L2VEA(); | 76 static scoped_ptr<media::VideoEncodeAccelerator> CreateV4L2VEA(); |
| 77 static scoped_ptr<media::VideoEncodeAccelerator> CreateVaapiVEA(); | 77 static scoped_ptr<media::VideoEncodeAccelerator> CreateVaapiVEA(); |
| 78 static scoped_ptr<media::VideoEncodeAccelerator> CreateAndroidVEA(); | 78 static scoped_ptr<media::VideoEncodeAccelerator> CreateAndroidVEA(); |
| 79 static scoped_ptr<media::VideoEncodeAccelerator> CreateVTVEA(); |
| 79 | 80 |
| 80 // IPC handlers, proxying media::VideoEncodeAccelerator for the renderer | 81 // IPC handlers, proxying media::VideoEncodeAccelerator for the renderer |
| 81 // process. | 82 // process. |
| 82 void OnEncode(const AcceleratedVideoEncoderMsg_Encode_Params& params); | 83 void OnEncode(const AcceleratedVideoEncoderMsg_Encode_Params& params); |
| 83 void OnEncode2(const AcceleratedVideoEncoderMsg_Encode_Params2& params); | 84 void OnEncode2(const AcceleratedVideoEncoderMsg_Encode_Params2& params); |
| 84 void OnUseOutputBitstreamBuffer(int32_t buffer_id, | 85 void OnUseOutputBitstreamBuffer(int32_t buffer_id, |
| 85 base::SharedMemoryHandle buffer_handle, | 86 base::SharedMemoryHandle buffer_handle, |
| 86 uint32_t buffer_size); | 87 uint32_t buffer_size); |
| 87 void OnRequestEncodingParametersChange(uint32_t bitrate, uint32_t framerate); | 88 void OnRequestEncodingParametersChange(uint32_t bitrate, uint32_t framerate); |
| 88 | 89 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 116 | 117 |
| 117 // Weak pointer for media::VideoFrames that refer back to |this|. | 118 // Weak pointer for media::VideoFrames that refer back to |this|. |
| 118 base::WeakPtrFactory<GpuVideoEncodeAccelerator> weak_this_factory_; | 119 base::WeakPtrFactory<GpuVideoEncodeAccelerator> weak_this_factory_; |
| 119 | 120 |
| 120 DISALLOW_COPY_AND_ASSIGN(GpuVideoEncodeAccelerator); | 121 DISALLOW_COPY_AND_ASSIGN(GpuVideoEncodeAccelerator); |
| 121 }; | 122 }; |
| 122 | 123 |
| 123 } // namespace content | 124 } // namespace content |
| 124 | 125 |
| 125 #endif // CONTENT_COMMON_GPU_MEDIA_GPU_VIDEO_ENCODE_ACCELERATOR_H_ | 126 #endif // CONTENT_COMMON_GPU_MEDIA_GPU_VIDEO_ENCODE_ACCELERATOR_H_ |
| OLD | NEW |