Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(701)

Side by Side Diff: src/gpu/gl/GrGLInterface.cpp

Issue 2038743002: Support ARB extensions for indirect drawing (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/gpu/gl/GrGLCaps.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 582 matching lines...) Expand 10 before | Expand all | Expand 10 after
593 } 593 }
594 } 594 }
595 } else if (kGLES_GrGLStandard == fStandard) { 595 } else if (kGLES_GrGLStandard == fStandard) {
596 if (glVer >= GR_GL_VER(3,0) || fExtensions.has("GL_EXT_instanced_arrays" )) { 596 if (glVer >= GR_GL_VER(3,0) || fExtensions.has("GL_EXT_instanced_arrays" )) {
597 if (nullptr == fFunctions.fVertexAttribDivisor) { 597 if (nullptr == fFunctions.fVertexAttribDivisor) {
598 RETURN_FALSE_INTERFACE 598 RETURN_FALSE_INTERFACE
599 } 599 }
600 } 600 }
601 } 601 }
602 602
603 if ((kGL_GrGLStandard == fStandard && glVer >= GR_GL_VER(4,3)) || 603 if ((kGL_GrGLStandard == fStandard &&
604 (glVer >= GR_GL_VER(4,0) || fExtensions.has("GL_ARB_draw_indirect"))) | |
604 (kGLES_GrGLStandard == fStandard && glVer >= GR_GL_VER(3,1))) { 605 (kGLES_GrGLStandard == fStandard && glVer >= GR_GL_VER(3,1))) {
605 if (NULL == fFunctions.fDrawArraysIndirect || 606 if (NULL == fFunctions.fDrawArraysIndirect ||
606 NULL == fFunctions.fDrawElementsIndirect) { 607 NULL == fFunctions.fDrawElementsIndirect) {
607 RETURN_FALSE_INTERFACE 608 RETURN_FALSE_INTERFACE
608 } 609 }
609 } 610 }
610 611
611 if ((kGL_GrGLStandard == fStandard && glVer >= GR_GL_VER(4,3)) || 612 if ((kGL_GrGLStandard == fStandard &&
613 (glVer >= GR_GL_VER(4,3) || fExtensions.has("GL_ARB_multi_draw_indirect "))) ||
612 (kGLES_GrGLStandard == fStandard && fExtensions.has("GL_EXT_multi_draw_i ndirect"))) { 614 (kGLES_GrGLStandard == fStandard && fExtensions.has("GL_EXT_multi_draw_i ndirect"))) {
613 if (NULL == fFunctions.fMultiDrawArraysIndirect || 615 if (NULL == fFunctions.fMultiDrawArraysIndirect ||
614 NULL == fFunctions.fMultiDrawElementsIndirect) { 616 NULL == fFunctions.fMultiDrawElementsIndirect) {
615 RETURN_FALSE_INTERFACE 617 RETURN_FALSE_INTERFACE
616 } 618 }
617 } 619 }
618 620
619 if (fExtensions.has("GL_NV_bindless_texture")) { 621 if (fExtensions.has("GL_NV_bindless_texture")) {
620 if (nullptr == fFunctions.fGetTextureHandle || 622 if (nullptr == fFunctions.fGetTextureHandle ||
621 nullptr == fFunctions.fGetTextureSamplerHandle || 623 nullptr == fFunctions.fGetTextureSamplerHandle ||
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
785 787
786 if (fExtensions.has("EGL_KHR_image") || fExtensions.has("EGL_KHR_image_base" )) { 788 if (fExtensions.has("EGL_KHR_image") || fExtensions.has("EGL_KHR_image_base" )) {
787 if (nullptr == fFunctions.fEGLCreateImage || 789 if (nullptr == fFunctions.fEGLCreateImage ||
788 nullptr == fFunctions.fEGLDestroyImage) { 790 nullptr == fFunctions.fEGLDestroyImage) {
789 RETURN_FALSE_INTERFACE 791 RETURN_FALSE_INTERFACE
790 } 792 }
791 } 793 }
792 794
793 return true; 795 return true;
794 } 796 }
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLCaps.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698