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 | 8 |
9 #include "gl/GrGLInterface.h" | 9 #include "gl/GrGLInterface.h" |
10 #include "gl/GrGLExtensions.h" | 10 #include "gl/GrGLExtensions.h" |
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
350 NULL == fFunctions.fPointAlongPath) { | 350 NULL == fFunctions.fPointAlongPath) { |
351 RETURN_FALSE_INTERFACE | 351 RETURN_FALSE_INTERFACE |
352 } | 352 } |
353 } | 353 } |
354 } | 354 } |
355 | 355 |
356 // optional function on desktop before 1.3 | 356 // optional function on desktop before 1.3 |
357 if (kGL_GrGLStandard != fStandard || | 357 if (kGL_GrGLStandard != fStandard || |
358 (glVer >= GR_GL_VER(1,3)) || | 358 (glVer >= GR_GL_VER(1,3)) || |
359 fExtensions.has("GL_ARB_texture_compression")) { | 359 fExtensions.has("GL_ARB_texture_compression")) { |
360 if (NULL == fFunctions.fCompressedTexImage2D) { | 360 if (NULL == fFunctions.fCompressedTexImage2D || |
| 361 NULL == fFunctions.fCompressedTexSubImage2D) { |
361 RETURN_FALSE_INTERFACE | 362 RETURN_FALSE_INTERFACE |
362 } | 363 } |
363 } | 364 } |
364 | 365 |
365 // part of desktop GL, but not ES | 366 // part of desktop GL, but not ES |
366 if (kGL_GrGLStandard == fStandard && | 367 if (kGL_GrGLStandard == fStandard && |
367 (NULL == fFunctions.fGetTexLevelParameteriv || | 368 (NULL == fFunctions.fGetTexLevelParameteriv || |
368 NULL == fFunctions.fDrawBuffer || | 369 NULL == fFunctions.fDrawBuffer || |
369 NULL == fFunctions.fReadBuffer)) { | 370 NULL == fFunctions.fReadBuffer)) { |
370 RETURN_FALSE_INTERFACE | 371 RETURN_FALSE_INTERFACE |
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
517 if (glVer >= GR_GL_VER(3,0) || | 518 if (glVer >= GR_GL_VER(3,0) || |
518 (kGLES_GrGLStandard == fStandard && fExtensions.has("GL_EXT_map_buffer_r
ange")) || | 519 (kGLES_GrGLStandard == fStandard && fExtensions.has("GL_EXT_map_buffer_r
ange")) || |
519 (kGL_GrGLStandard == fStandard && fExtensions.has("GL_ARB_map_buffer_ran
ge"))) { | 520 (kGL_GrGLStandard == fStandard && fExtensions.has("GL_ARB_map_buffer_ran
ge"))) { |
520 if (NULL == fFunctions.fMapBufferRange || | 521 if (NULL == fFunctions.fMapBufferRange || |
521 NULL == fFunctions.fFlushMappedBufferRange) { | 522 NULL == fFunctions.fFlushMappedBufferRange) { |
522 RETURN_FALSE_INTERFACE; | 523 RETURN_FALSE_INTERFACE; |
523 } | 524 } |
524 } | 525 } |
525 return true; | 526 return true; |
526 } | 527 } |
OLD | NEW |