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 // This API is consistent with other OpenGL setup APIs like window's WGL | 5 // This API is consistent with other OpenGL setup APIs like window's WGL |
6 // and pepper's PGL. This API is used to manage OpenGL RendererGLContexts in the | 6 // and pepper's PGL. This API is used to manage OpenGL RendererGLContexts in the |
7 // Chrome renderer process in a way that is consistent with other platforms. | 7 // Chrome renderer process in a way that is consistent with other platforms. |
8 | 8 |
9 #ifndef CONTENT_RENDERER_GPU_RENDERER_GL_CONTEXT_H_ | 9 #ifndef CONTENT_RENDERER_GPU_RENDERER_GL_CONTEXT_H_ |
10 #define CONTENT_RENDERER_GPU_RENDERER_GL_CONTEXT_H_ | 10 #define CONTENT_RENDERER_GPU_RENDERER_GL_CONTEXT_H_ |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
150 // For a view RendererGLContext, display everything that has been rendered | 150 // For a view RendererGLContext, display everything that has been rendered |
151 // since the last call. For an offscreen RendererGLContext, resolve everything | 151 // since the last call. For an offscreen RendererGLContext, resolve everything |
152 // that has been rendered since the last call to a copy that can be accessed | 152 // that has been rendered since the last call to a copy that can be accessed |
153 // by the parent RendererGLContext. | 153 // by the parent RendererGLContext. |
154 bool SwapBuffers(); | 154 bool SwapBuffers(); |
155 | 155 |
156 // Run the task once the channel has been flushed. Takes care of deleting the | 156 // Run the task once the channel has been flushed. Takes care of deleting the |
157 // task whether the echo succeeds or not. | 157 // task whether the echo succeeds or not. |
158 bool Echo(const base::Closure& task); | 158 bool Echo(const base::Closure& task); |
159 | 159 |
160 bool SetSurfaceVisible(bool visibility); | |
mmocny
2011/10/13 21:48:43
TODO: add a comment here
| |
161 | |
160 // Create a TransportTextureHost object associated with the context. | 162 // Create a TransportTextureHost object associated with the context. |
161 scoped_refptr<TransportTextureHost> CreateTransportTextureHost(); | 163 scoped_refptr<TransportTextureHost> CreateTransportTextureHost(); |
162 | 164 |
163 // TODO(gman): Remove this | 165 // TODO(gman): Remove this |
164 void DisableShaderTranslation(); | 166 void DisableShaderTranslation(); |
165 | 167 |
166 // Allows direct access to the GLES2 implementation so a RendererGLContext | 168 // Allows direct access to the GLES2 implementation so a RendererGLContext |
167 // can be used without making it current. | 169 // can be used without making it current. |
168 gpu::gles2::GLES2Implementation* GetImplementation(); | 170 gpu::gles2::GLES2Implementation* GetImplementation(); |
169 | 171 |
(...skipping 28 matching lines...) Expand all Loading... | |
198 gpu::gles2::GLES2CmdHelper* gles2_helper_; | 200 gpu::gles2::GLES2CmdHelper* gles2_helper_; |
199 int32 transfer_buffer_id_; | 201 int32 transfer_buffer_id_; |
200 gpu::gles2::GLES2Implementation* gles2_implementation_; | 202 gpu::gles2::GLES2Implementation* gles2_implementation_; |
201 Error last_error_; | 203 Error last_error_; |
202 int frame_number_; | 204 int frame_number_; |
203 | 205 |
204 DISALLOW_COPY_AND_ASSIGN(RendererGLContext); | 206 DISALLOW_COPY_AND_ASSIGN(RendererGLContext); |
205 }; | 207 }; |
206 | 208 |
207 #endif // CONTENT_RENDERER_GPU_RENDERER_GL_CONTEXT_H_ | 209 #endif // CONTENT_RENDERER_GPU_RENDERER_GL_CONTEXT_H_ |
OLD | NEW |