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 #ifndef CONTENT_COMMON_GPU_MEDIA_DXVA_VIDEO_DECODE_ACCELERATOR_H_ | 5 #ifndef CONTENT_COMMON_GPU_MEDIA_DXVA_VIDEO_DECODE_ACCELERATOR_H_ |
6 #define CONTENT_COMMON_GPU_MEDIA_DXVA_VIDEO_DECODE_ACCELERATOR_H_ | 6 #define CONTENT_COMMON_GPU_MEDIA_DXVA_VIDEO_DECODE_ACCELERATOR_H_ |
7 | 7 |
8 #include <d3d9.h> | 8 #include <d3d9.h> |
9 #include <dxva2api.h> | 9 #include <dxva2api.h> |
10 #include <list> | 10 #include <list> |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 virtual ~DXVAVideoDecodeAccelerator(); | 44 virtual ~DXVAVideoDecodeAccelerator(); |
45 | 45 |
46 // media::VideoDecodeAccelerator implementation. | 46 // media::VideoDecodeAccelerator implementation. |
47 virtual bool Initialize(media::VideoCodecProfile profile) OVERRIDE; | 47 virtual bool Initialize(media::VideoCodecProfile profile) OVERRIDE; |
48 virtual void Decode(const media::BitstreamBuffer& bitstream_buffer) OVERRIDE; | 48 virtual void Decode(const media::BitstreamBuffer& bitstream_buffer) OVERRIDE; |
49 virtual void AssignPictureBuffers( | 49 virtual void AssignPictureBuffers( |
50 const std::vector<media::PictureBuffer>& buffers) OVERRIDE; | 50 const std::vector<media::PictureBuffer>& buffers) OVERRIDE; |
51 virtual void ReusePictureBuffer(int32 picture_buffer_id) OVERRIDE; | 51 virtual void ReusePictureBuffer(int32 picture_buffer_id) OVERRIDE; |
52 virtual void Flush() OVERRIDE; | 52 virtual void Flush() OVERRIDE; |
53 virtual void Reset() OVERRIDE; | 53 virtual void Reset() OVERRIDE; |
54 virtual void Destroy() OVERRIDE; | 54 virtual void Destroy(bool pass_ownership) OVERRIDE; |
55 | 55 |
56 // Initialization work needed before the process is sandboxed. | 56 // Initialization work needed before the process is sandboxed. |
57 // This includes:- | 57 // This includes:- |
58 // 1. Loads the dlls like mf/mfplat/d3d9, etc required for decoding. | 58 // 1. Loads the dlls like mf/mfplat/d3d9, etc required for decoding. |
59 // 2. Setting up the device manager instance which is shared between all | 59 // 2. Setting up the device manager instance which is shared between all |
60 // decoder instances. | 60 // decoder instances. |
61 static void PreSandboxInitialization(); | 61 static void PreSandboxInitialization(); |
62 | 62 |
63 private: | 63 private: |
64 typedef void* EGLConfig; | 64 typedef void* EGLConfig; |
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 | 196 |
197 // Set to true if all necessary initialization needed before the GPU process | 197 // Set to true if all necessary initialization needed before the GPU process |
198 // is sandboxed is done. | 198 // is sandboxed is done. |
199 // This includes the following: | 199 // This includes the following: |
200 // 1. All required decoder dlls were successfully loaded. | 200 // 1. All required decoder dlls were successfully loaded. |
201 // 2. The device manager initialization completed. | 201 // 2. The device manager initialization completed. |
202 static bool pre_sandbox_init_done_; | 202 static bool pre_sandbox_init_done_; |
203 }; | 203 }; |
204 | 204 |
205 #endif // CONTENT_COMMON_GPU_MEDIA_DXVA_VIDEO_DECODE_ACCELERATOR_H_ | 205 #endif // CONTENT_COMMON_GPU_MEDIA_DXVA_VIDEO_DECODE_ACCELERATOR_H_ |
OLD | NEW |