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 954 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
965 fBlendEquationSupport = kAdvanced_BlendEquationSupport; | 965 fBlendEquationSupport = kAdvanced_BlendEquationSupport; |
966 glslCaps->fAdvBlendEqInteraction = GrGLSLCaps::kGeneralEnable_AdvBlendEq
Interaction; | 966 glslCaps->fAdvBlendEqInteraction = GrGLSLCaps::kGeneralEnable_AdvBlendEq
Interaction; |
967 // TODO: Use kSpecificEnables_AdvBlendEqInteraction if "blend_support_al
l_equations" is | 967 // TODO: Use kSpecificEnables_AdvBlendEqInteraction if "blend_support_al
l_equations" is |
968 // slow on a particular platform. | 968 // slow on a particular platform. |
969 } else { | 969 } else { |
970 return; // No advanced blend support. | 970 return; // No advanced blend support. |
971 } | 971 } |
972 | 972 |
973 SkASSERT(this->advancedBlendEquationSupport()); | 973 SkASSERT(this->advancedBlendEquationSupport()); |
974 | 974 |
975 if (kNVIDIA_GrGLDriver == ctxInfo.driver()) { | 975 if (kNVIDIA_GrGLDriver == ctxInfo.driver() && |
976 // Blacklist color-dodge and color-burn on NVIDIA until the fix is relea
sed. | 976 ctxInfo.driverVersion() < GR_GL_DRIVER_VER(355,00)) { |
| 977 // Blacklist color-dodge and color-burn on pre-355.00 NVIDIA. |
977 fAdvBlendEqBlacklist |= (1 << kColorDodge_GrBlendEquation) | | 978 fAdvBlendEqBlacklist |= (1 << kColorDodge_GrBlendEquation) | |
978 (1 << kColorBurn_GrBlendEquation); | 979 (1 << kColorBurn_GrBlendEquation); |
979 } | 980 } |
980 if (kARM_GrGLVendor == ctxInfo.vendor()) { | 981 if (kARM_GrGLVendor == ctxInfo.vendor()) { |
981 // Blacklist color-burn on ARM until the fix is released. | 982 // Blacklist color-burn on ARM until the fix is released. |
982 fAdvBlendEqBlacklist |= (1 << kColorBurn_GrBlendEquation); | 983 fAdvBlendEqBlacklist |= (1 << kColorBurn_GrBlendEquation); |
983 } | 984 } |
984 } | 985 } |
985 | 986 |
986 namespace { | 987 namespace { |
(...skipping 947 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1934 void GrGLCaps::onApplyOptionsOverrides(const GrContextOptions& options) { | 1935 void GrGLCaps::onApplyOptionsOverrides(const GrContextOptions& options) { |
1935 if (options.fEnableInstancedRendering) { | 1936 if (options.fEnableInstancedRendering) { |
1936 fInstancedSupport = gr_instanced::GLInstancedRendering::CheckSupport(*th
is); | 1937 fInstancedSupport = gr_instanced::GLInstancedRendering::CheckSupport(*th
is); |
1937 #ifndef SK_BUILD_FOR_MAC | 1938 #ifndef SK_BUILD_FOR_MAC |
1938 // OS X doesn't seem to write correctly to floating point textures when
using | 1939 // OS X doesn't seem to write correctly to floating point textures when
using |
1939 // glDraw*Indirect, regardless of the underlying GPU. | 1940 // glDraw*Indirect, regardless of the underlying GPU. |
1940 fAvoidInstancedDrawsToFPTargets = true; | 1941 fAvoidInstancedDrawsToFPTargets = true; |
1941 #endif | 1942 #endif |
1942 } | 1943 } |
1943 } | 1944 } |
OLD | NEW |