| 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_RENDERING_HELPER_H_ | 5 #ifndef CONTENT_COMMON_GPU_MEDIA_RENDERING_HELPER_H_ |
| 6 #define CONTENT_COMMON_GPU_MEDIA_RENDERING_HELPER_H_ | 6 #define CONTENT_COMMON_GPU_MEDIA_RENDERING_HELPER_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 | 88 |
| 89 // Render thumbnail in the |texture_id| to the FBO buffer using target | 89 // Render thumbnail in the |texture_id| to the FBO buffer using target |
| 90 // |texture_target|. | 90 // |texture_target|. |
| 91 void RenderThumbnail(uint32 texture_target, uint32 texture_id); | 91 void RenderThumbnail(uint32 texture_target, uint32 texture_id); |
| 92 | 92 |
| 93 // Queues the VideoFrame for rendering. | 93 // Queues the VideoFrame for rendering. |
| 94 void QueueVideoFrame(size_t window_id, scoped_ptr<VideoFrame> video_frame); | 94 void QueueVideoFrame(size_t window_id, scoped_ptr<VideoFrame> video_frame); |
| 95 | 95 |
| 96 void ClearVideoFrames(size_t window_id); | 96 void ClearVideoFrames(size_t window_id); |
| 97 | 97 |
| 98 // Sets the callback who will be invoked when all pending video frames has |
| 99 // been rendered. |
| 100 void SetWaitRenderingCB(size_t window_id, |
| 101 const base::Closure& wait_rendering_cb); |
| 102 |
| 98 // Delete |texture_id|. | 103 // Delete |texture_id|. |
| 99 void DeleteTexture(uint32 texture_id); | 104 void DeleteTexture(uint32 texture_id); |
| 100 | 105 |
| 101 // Get the platform specific handle to the OpenGL display. | 106 // Get the platform specific handle to the OpenGL display. |
| 102 void* GetGLDisplay(); | 107 void* GetGLDisplay(); |
| 103 | 108 |
| 104 // Get the platform specific handle to the OpenGL context. | 109 // Get the platform specific handle to the OpenGL context. |
| 105 void* GetGLContext(); | 110 void* GetGLContext(); |
| 106 | 111 |
| 107 // Get rendered thumbnails as RGB. | 112 // Get rendered thumbnails as RGB. |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 151 gfx::Size thumbnail_size_; | 156 gfx::Size thumbnail_size_; |
| 152 GLuint program_; | 157 GLuint program_; |
| 153 base::TimeDelta frame_duration_; | 158 base::TimeDelta frame_duration_; |
| 154 | 159 |
| 155 DISALLOW_COPY_AND_ASSIGN(RenderingHelper); | 160 DISALLOW_COPY_AND_ASSIGN(RenderingHelper); |
| 156 }; | 161 }; |
| 157 | 162 |
| 158 } // namespace content | 163 } // namespace content |
| 159 | 164 |
| 160 #endif // CONTENT_COMMON_GPU_MEDIA_RENDERING_HELPER_H_ | 165 #endif // CONTENT_COMMON_GPU_MEDIA_RENDERING_HELPER_H_ |
| OLD | NEW |