| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 "GrGLCaps.h" | 9 #include "GrGLCaps.h" |
| 10 | 10 |
| (...skipping 966 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 977 else { | 977 else { |
| 978 fPathRenderingSupport = ctxInfo.version() >= GR_GL_VER(3, 1); | 978 fPathRenderingSupport = ctxInfo.version() >= GR_GL_VER(3, 1); |
| 979 } | 979 } |
| 980 } | 980 } |
| 981 | 981 |
| 982 // For now these two are equivalent but we could have dst read in shader via
some other method | 982 // For now these two are equivalent but we could have dst read in shader via
some other method |
| 983 fDstReadInShaderSupport = fFBFetchSupport; | 983 fDstReadInShaderSupport = fFBFetchSupport; |
| 984 | 984 |
| 985 // Enable supported shader-related caps | 985 // Enable supported shader-related caps |
| 986 if (kGL_GrGLStandard == standard) { | 986 if (kGL_GrGLStandard == standard) { |
| 987 fDualSourceBlendingSupport = ctxInfo.version() >= GR_GL_VER(3, 3) || | 987 fDualSourceBlendingSupport = (ctxInfo.version() >= GR_GL_VER(3, 3) || |
| 988 ctxInfo.hasExtension("GL_ARB_blend_func_extended"); | 988 ctxInfo.hasExtension("GL_ARB_blend_func_extended")) && |
| 989 GrGLSLSupportsNamedFragmentShaderOutputs(ctxInfo.glslGeneration()); |
| 989 fShaderDerivativeSupport = true; | 990 fShaderDerivativeSupport = true; |
| 990 // we don't support GL_ARB_geometry_shader4, just GL 3.2+ GS | 991 // we don't support GL_ARB_geometry_shader4, just GL 3.2+ GS |
| 991 fGeometryShaderSupport = ctxInfo.version() >= GR_GL_VER(3, 2) && | 992 fGeometryShaderSupport = ctxInfo.version() >= GR_GL_VER(3, 2) && |
| 992 ctxInfo.glslGeneration() >= k150_GrGLSLGeneration; | 993 ctxInfo.glslGeneration() >= k150_GrGLSLGeneration; |
| 993 } | 994 } |
| 994 else { | 995 else { |
| 995 fShaderDerivativeSupport = ctxInfo.version() >= GR_GL_VER(3, 0) || | 996 fShaderDerivativeSupport = ctxInfo.version() >= GR_GL_VER(3, 0) || |
| 996 ctxInfo.hasExtension("GL_OES_standard_derivatives"); | 997 ctxInfo.hasExtension("GL_OES_standard_derivatives"); |
| 997 } | 998 } |
| 998 | 999 |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1121 if (fGeometryShaderSupport) { | 1122 if (fGeometryShaderSupport) { |
| 1122 for (int p = 0; p < kGrSLPrecisionCount; ++p) { | 1123 for (int p = 0; p < kGrSLPrecisionCount; ++p) { |
| 1123 fFloatPrecisions[kGeometry_GrShaderType][p] = fFloatPrecisions[kVert
ex_GrShaderType][p]; | 1124 fFloatPrecisions[kGeometry_GrShaderType][p] = fFloatPrecisions[kVert
ex_GrShaderType][p]; |
| 1124 } | 1125 } |
| 1125 } | 1126 } |
| 1126 } | 1127 } |
| 1127 | 1128 |
| 1128 | 1129 |
| 1129 | 1130 |
| 1130 | 1131 |
| OLD | NEW |