OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #ifndef GrGLInterface_DEFINED | 8 #ifndef GrGLInterface_DEFINED |
9 #define GrGLInterface_DEFINED | 9 #define GrGLInterface_DEFINED |
10 | 10 |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
211 GLPtr<GrGLLoadIdentityProc> fLoadIdentity; | 211 GLPtr<GrGLLoadIdentityProc> fLoadIdentity; |
212 GLPtr<GrGLLoadMatrixfProc> fLoadMatrixf; | 212 GLPtr<GrGLLoadMatrixfProc> fLoadMatrixf; |
213 GLPtr<GrGLMapBufferProc> fMapBuffer; | 213 GLPtr<GrGLMapBufferProc> fMapBuffer; |
214 GLPtr<GrGLMatrixModeProc> fMatrixMode; | 214 GLPtr<GrGLMatrixModeProc> fMatrixMode; |
215 GLPtr<GrGLPixelStoreiProc> fPixelStorei; | 215 GLPtr<GrGLPixelStoreiProc> fPixelStorei; |
216 GLPtr<GrGLQueryCounterProc> fQueryCounter; | 216 GLPtr<GrGLQueryCounterProc> fQueryCounter; |
217 GLPtr<GrGLReadBufferProc> fReadBuffer; | 217 GLPtr<GrGLReadBufferProc> fReadBuffer; |
218 GLPtr<GrGLReadPixelsProc> fReadPixels; | 218 GLPtr<GrGLReadPixelsProc> fReadPixels; |
219 GLPtr<GrGLRenderbufferStorageProc> fRenderbufferStorage; | 219 GLPtr<GrGLRenderbufferStorageProc> fRenderbufferStorage; |
220 | 220 |
221 #if !GR_GL_IGNORE_ES3_MSAA | |
222 // On OpenGL ES there are multiple incompatible extensions that add support
for MSAA | 221 // On OpenGL ES there are multiple incompatible extensions that add support
for MSAA |
223 // and ES3 adds MSAA support to the standard. On an ES3 driver we may still
use the | 222 // and ES3 adds MSAA support to the standard. On an ES3 driver we may still
use the |
224 // older extensions for performance reasons or due to ES3 driver bugs. We w
ant the function | 223 // older extensions for performance reasons or due to ES3 driver bugs. We w
ant the function |
225 // that creates the GrGLInterface to provide all available functions and in
ternally | 224 // that creates the GrGLInterface to provide all available functions and in
ternally |
226 // we will select among them. They all have a method called glRenderbufferS
torageMultisample*. | 225 // we will select among them. They all have a method called glRenderbufferS
torageMultisample*. |
227 // So we have separate function pointers for GL_IMG/EXT_multisampled_to_tex
ture, | 226 // So we have separate function pointers for GL_IMG/EXT_multisampled_to_tex
ture, |
228 // GL_CHROMIUM/ANGLE_framebuffer_multisample/ES3, and GL_APPLE_framebuffer_
multisample | 227 // GL_CHROMIUM/ANGLE_framebuffer_multisample/ES3, and GL_APPLE_framebuffer_
multisample |
229 // variations. | 228 // variations. |
230 // | 229 // |
231 // If a driver supports multiple GL_ARB_framebuffer_multisample-style exten
sions then we will | 230 // If a driver supports multiple GL_ARB_framebuffer_multisample-style exten
sions then we will |
232 // assume the function pointers for the standard (or equivalent GL_ARB) ver
sion have | 231 // assume the function pointers for the standard (or equivalent GL_ARB) ver
sion have |
233 // been preferred over GL_EXT, GL_CHROMIUM, or GL_ANGLE variations that hav
e reduced | 232 // been preferred over GL_EXT, GL_CHROMIUM, or GL_ANGLE variations that hav
e reduced |
234 // functionality. | 233 // functionality. |
235 | 234 |
236 // GL_EXT_multisampled_render_to_texture (preferred) or GL_IMG_multisampled
_render_to_texture | 235 // GL_EXT_multisampled_render_to_texture (preferred) or GL_IMG_multisampled
_render_to_texture |
237 GLPtr<GrGLRenderbufferStorageMultisampleProc> fRenderbufferStorageMultisampl
eES2EXT; | 236 GLPtr<GrGLRenderbufferStorageMultisampleProc> fRenderbufferStorageMultisampl
eES2EXT; |
238 // GL_APPLE_framebuffer_multisample | 237 // GL_APPLE_framebuffer_multisample |
239 GLPtr<GrGLRenderbufferStorageMultisampleProc> fRenderbufferStorageMultisampl
eES2APPLE; | 238 GLPtr<GrGLRenderbufferStorageMultisampleProc> fRenderbufferStorageMultisampl
eES2APPLE; |
240 #endif | 239 |
241 // This is used to store the pointer for GL_ARB/EXT/ANGLE/CHROMIUM_framebuf
fer_multisample or | 240 // This is used to store the pointer for GL_ARB/EXT/ANGLE/CHROMIUM_framebuf
fer_multisample or |
242 // the standard function in ES3+ or GL 3.0+. | 241 // the standard function in ES3+ or GL 3.0+. |
243 GLPtr<GrGLRenderbufferStorageMultisampleProc> fRenderbufferStorageMultisampl
e; | 242 GLPtr<GrGLRenderbufferStorageMultisampleProc> fRenderbufferStorageMultisampl
e; |
244 | 243 |
245 // Pointer to BindUniformLocationCHROMIUM from the GL_CHROMIUM_bind_uniform_
location extension. | 244 // Pointer to BindUniformLocationCHROMIUM from the GL_CHROMIUM_bind_uniform_
location extension. |
246 GLPtr<GrGLBindUniformLocation> fBindUniformLocation; | 245 GLPtr<GrGLBindUniformLocation> fBindUniformLocation; |
247 | 246 |
248 GLPtr<GrGLResolveMultisampleFramebufferProc> fResolveMultisampleFramebuffer; | 247 GLPtr<GrGLResolveMultisampleFramebufferProc> fResolveMultisampleFramebuffer; |
249 GLPtr<GrGLScissorProc> fScissor; | 248 GLPtr<GrGLScissorProc> fScissor; |
250 GLPtr<GrGLShaderSourceProc> fShaderSource; | 249 GLPtr<GrGLShaderSourceProc> fShaderSource; |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
344 | 343 |
345 // Per-GL func callback | 344 // Per-GL func callback |
346 #if GR_GL_PER_GL_FUNC_CALLBACK | 345 #if GR_GL_PER_GL_FUNC_CALLBACK |
347 GrGLInterfaceCallbackProc fCallback; | 346 GrGLInterfaceCallbackProc fCallback; |
348 GrGLInterfaceCallbackData fCallbackData; | 347 GrGLInterfaceCallbackData fCallbackData; |
349 #endif | 348 #endif |
350 | 349 |
351 }; | 350 }; |
352 | 351 |
353 #endif | 352 #endif |
OLD | NEW |