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 29 matching lines...) Expand all Loading... |
40 fTwoFormatLimit = false; | 40 fTwoFormatLimit = false; |
41 fFragCoordsConventionSupport = false; | 41 fFragCoordsConventionSupport = false; |
42 fVertexArrayObjectSupport = false; | 42 fVertexArrayObjectSupport = false; |
43 fInstancedDrawingSupport = false; | 43 fInstancedDrawingSupport = false; |
44 fDirectStateAccessSupport = false; | 44 fDirectStateAccessSupport = false; |
45 fDebugSupport = false; | 45 fDebugSupport = false; |
46 fES2CompatibilitySupport = false; | 46 fES2CompatibilitySupport = false; |
47 fMultisampleDisableSupport = false; | 47 fMultisampleDisableSupport = false; |
48 fUseNonVBOVertexAndIndexDynamicData = false; | 48 fUseNonVBOVertexAndIndexDynamicData = false; |
49 fIsCoreProfile = false; | 49 fIsCoreProfile = false; |
50 fFullClearIsFree = false; | |
51 fBindFragDataLocationSupport = false; | 50 fBindFragDataLocationSupport = false; |
52 fSRGBWriteControl = false; | 51 fSRGBWriteControl = false; |
53 fRGBA8888PixelsOpsAreSlow = false; | 52 fRGBA8888PixelsOpsAreSlow = false; |
54 fPartialFBOReadIsSlow = false; | 53 fPartialFBOReadIsSlow = false; |
55 | 54 |
56 fReadPixelsSupportedCache.reset(); | 55 fReadPixelsSupportedCache.reset(); |
57 | 56 |
58 fShaderCaps.reset(SkNEW_ARGS(GrGLSLCaps, (contextOptions))); | 57 fShaderCaps.reset(SkNEW_ARGS(GrGLSLCaps, (contextOptions))); |
59 | 58 |
60 this->init(contextOptions, ctxInfo, glInterface); | 59 this->init(contextOptions, ctxInfo, glInterface); |
(...skipping 1075 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1136 r.appendf("Two Format Limit: %s\n", (fTwoFormatLimit ? "YES": "NO")); | 1135 r.appendf("Two Format Limit: %s\n", (fTwoFormatLimit ? "YES": "NO")); |
1137 r.appendf("Fragment coord conventions support: %s\n", | 1136 r.appendf("Fragment coord conventions support: %s\n", |
1138 (fFragCoordsConventionSupport ? "YES": "NO")); | 1137 (fFragCoordsConventionSupport ? "YES": "NO")); |
1139 r.appendf("Vertex array object support: %s\n", (fVertexArrayObjectSupport ?
"YES": "NO")); | 1138 r.appendf("Vertex array object support: %s\n", (fVertexArrayObjectSupport ?
"YES": "NO")); |
1140 r.appendf("Instanced drawing support: %s\n", (fInstancedDrawingSupport ? "YE
S": "NO")); | 1139 r.appendf("Instanced drawing support: %s\n", (fInstancedDrawingSupport ? "YE
S": "NO")); |
1141 r.appendf("Direct state access support: %s\n", (fDirectStateAccessSupport ?
"YES": "NO")); | 1140 r.appendf("Direct state access support: %s\n", (fDirectStateAccessSupport ?
"YES": "NO")); |
1142 r.appendf("Debug support: %s\n", (fDebugSupport ? "YES": "NO")); | 1141 r.appendf("Debug support: %s\n", (fDebugSupport ? "YES": "NO")); |
1143 r.appendf("Multisample disable support: %s\n", (fMultisampleDisableSupport ?
"YES" : "NO")); | 1142 r.appendf("Multisample disable support: %s\n", (fMultisampleDisableSupport ?
"YES" : "NO")); |
1144 r.appendf("Use non-VBO for dynamic data: %s\n", | 1143 r.appendf("Use non-VBO for dynamic data: %s\n", |
1145 (fUseNonVBOVertexAndIndexDynamicData ? "YES" : "NO")); | 1144 (fUseNonVBOVertexAndIndexDynamicData ? "YES" : "NO")); |
1146 r.appendf("Full screen clear is free: %s\n", (fFullClearIsFree ? "YES" : "NO
")); | |
1147 r.appendf("SRGB write contol: %s\n", (fSRGBWriteControl ? "YES" : "NO")); | 1145 r.appendf("SRGB write contol: %s\n", (fSRGBWriteControl ? "YES" : "NO")); |
1148 r.appendf("RGBA 8888 pixel ops are slow: %s\n", (fRGBA8888PixelsOpsAreSlow?
"YES" : "NO")); | 1146 r.appendf("RGBA 8888 pixel ops are slow: %s\n", (fRGBA8888PixelsOpsAreSlow?
"YES" : "NO")); |
1149 r.appendf("Partial FBO read is slow: %s\n", (fPartialFBOReadIsSlow? "YES" :
"NO")); | 1147 r.appendf("Partial FBO read is slow: %s\n", (fPartialFBOReadIsSlow? "YES" :
"NO")); |
1150 return r; | 1148 return r; |
1151 } | 1149 } |
1152 | 1150 |
1153 static GrGLenum precision_to_gl_float_type(GrSLPrecision p) { | 1151 static GrGLenum precision_to_gl_float_type(GrSLPrecision p) { |
1154 switch (p) { | 1152 switch (p) { |
1155 case kLow_GrSLPrecision: | 1153 case kLow_GrSLPrecision: |
1156 return GR_GL_LOW_FLOAT; | 1154 return GR_GL_LOW_FLOAT; |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1230 for (int p = 0; p < kGrSLPrecisionCount; ++p) { | 1228 for (int p = 0; p < kGrSLPrecisionCount; ++p) { |
1231 glslCaps->fFloatPrecisions[kGeometry_GrShaderType][p] = | 1229 glslCaps->fFloatPrecisions[kGeometry_GrShaderType][p] = |
1232 glslCaps->fFloatPrecisions[kVerte
x_GrShaderType][p]; | 1230 glslCaps->fFloatPrecisions[kVerte
x_GrShaderType][p]; |
1233 } | 1231 } |
1234 } | 1232 } |
1235 } | 1233 } |
1236 | 1234 |
1237 | 1235 |
1238 | 1236 |
1239 | 1237 |
OLD | NEW |