aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/gl
diff options
context:
space:
mode:
authorGravatar Chris Dalton <csmartdalton@google.com>2018-04-23 21:14:42 -0600
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-04-24 15:23:06 +0000
commit6f5e77a08faf9d967eba8194811cbf2391092c23 (patch)
tree577ea1030e16bd68c47eaa5cd3c494785c7204e6 /src/gpu/gl
parentb97f28b90399c2571712401a30b0299d37b4b52e (diff)
ccpr: Cull extremely thin triangles
When triangles get too thin it's possible for FP round-off error to actually give us the wrong winding direction, causing rendering artifacts. This change also allows us to unblacklist ANGLE. Bug: skia:7805 Bug: skia:7820 Change-Id: Ibaa0f033eba625d720e3a594c4515d8264cc413d Reviewed-on: https://skia-review.googlesource.com/123262 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
Diffstat (limited to 'src/gpu/gl')
-rw-r--r--src/gpu/gl/GrGLCaps.cpp19
1 files changed, 3 insertions, 16 deletions
diff --git a/src/gpu/gl/GrGLCaps.cpp b/src/gpu/gl/GrGLCaps.cpp
index c569e031e2..3bd857d53a 100644
--- a/src/gpu/gl/GrGLCaps.cpp
+++ b/src/gpu/gl/GrGLCaps.cpp
@@ -2271,7 +2271,9 @@ void GrGLCaps::applyDriverCorrectnessWorkarounds(const GrGLContextInfo& ctxInfo,
fRequiresCullFaceEnableDisableWhenDrawingLinesAfterNonLines = true;
}
- if (kIntelSkylake_GrGLRenderer == ctxInfo.renderer()) {
+ if (kIntelSkylake_GrGLRenderer == ctxInfo.renderer() ||
+ (kANGLE_GrGLRenderer == ctxInfo.renderer() &&
+ GrGLANGLERenderer::kSkylake == ctxInfo.angleRenderer())) {
fRequiresFlushBetweenNonAndInstancedDraws = true;
}
@@ -2319,21 +2321,6 @@ void GrGLCaps::applyDriverCorrectnessWorkarounds(const GrGLContextInfo& ctxInfo,
fDrawArraysBaseVertexIsBroken = true;
}
- // Blacklisting CCPR on ANGLE while we investigate http://skbug.com/7805.
- if (kANGLE_GrGLRenderer == ctxInfo.renderer()) {
- fBlacklistCoverageCounting = true;
- }
-
- // The ccpr vertex-shader implementation does not work on this platform. Only allow CCPR with
- // GS.
- if (kANGLE_GrGLRenderer == ctxInfo.renderer() &&
- GrGLANGLERenderer::kSkylake == ctxInfo.angleRenderer()) {
- bool gsSupport = fShaderCaps->geometryShaderSupport();
-#if GR_TEST_UTILS
- gsSupport &= !contextOptions.fSuppressGeometryShaders;
-#endif
- fBlacklistCoverageCounting = !gsSupport;
- }
// Currently the extension is advertised but fb fetch is broken on 500 series Adrenos like the
// Galaxy S7.
// TODO: Once this is fixed we can update the check here to look at a driver version number too.