| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 MEDIA_GPU_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ | 5 #ifndef MEDIA_GPU_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ |
| 6 #define MEDIA_GPU_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ | 6 #define MEDIA_GPU_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <list> | 10 #include <list> |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 const base::WeakPtr<Client>& decode_client, | 137 const base::WeakPtr<Client>& decode_client, |
| 138 const scoped_refptr<base::SingleThreadTaskRunner>& decode_task_runner) | 138 const scoped_refptr<base::SingleThreadTaskRunner>& decode_task_runner) |
| 139 override; | 139 override; |
| 140 | 140 |
| 141 // AVDAStateProvider implementation: | 141 // AVDAStateProvider implementation: |
| 142 const gfx::Size& GetSize() const override; | 142 const gfx::Size& GetSize() const override; |
| 143 const base::ThreadChecker& ThreadChecker() const override; | 143 const base::ThreadChecker& ThreadChecker() const override; |
| 144 base::WeakPtr<gpu::gles2::GLES2Decoder> GetGlDecoder() const override; | 144 base::WeakPtr<gpu::gles2::GLES2Decoder> GetGlDecoder() const override; |
| 145 gpu::gles2::TextureRef* GetTextureForPicture( | 145 gpu::gles2::TextureRef* GetTextureForPicture( |
| 146 const media::PictureBuffer& picture_buffer) override; | 146 const media::PictureBuffer& picture_buffer) override; |
| 147 scoped_refptr<gfx::SurfaceTexture> CreateAttachedSurfaceTexture( |
| 148 GLuint* service_id) override; |
| 147 void PostError(const ::tracked_objects::Location& from_here, | 149 void PostError(const ::tracked_objects::Location& from_here, |
| 148 media::VideoDecodeAccelerator::Error error) override; | 150 media::VideoDecodeAccelerator::Error error) override; |
| 149 | 151 |
| 150 static media::VideoDecodeAccelerator::Capabilities GetCapabilities( | 152 static media::VideoDecodeAccelerator::Capabilities GetCapabilities( |
| 151 const gpu::GpuPreferences& gpu_preferences); | 153 const gpu::GpuPreferences& gpu_preferences); |
| 152 | 154 |
| 153 // Notifies about SurfaceTexture::OnFrameAvailable. This can happen on any | 155 // Notifies about SurfaceTexture::OnFrameAvailable. This can happen on any |
| 154 // thread at any time! | 156 // thread at any time! |
| 155 void OnFrameAvailable(); | 157 void OnFrameAvailable(); |
| 156 | 158 |
| (...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 462 | 464 |
| 463 // WeakPtrFactory for posting tasks back to |this|. | 465 // WeakPtrFactory for posting tasks back to |this|. |
| 464 base::WeakPtrFactory<AndroidVideoDecodeAccelerator> weak_this_factory_; | 466 base::WeakPtrFactory<AndroidVideoDecodeAccelerator> weak_this_factory_; |
| 465 | 467 |
| 466 friend class AndroidVideoDecodeAcceleratorTest; | 468 friend class AndroidVideoDecodeAcceleratorTest; |
| 467 }; | 469 }; |
| 468 | 470 |
| 469 } // namespace media | 471 } // namespace media |
| 470 | 472 |
| 471 #endif // MEDIA_GPU_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ | 473 #endif // MEDIA_GPU_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ |
| OLD | NEW |