Add fence support for TransferBuffers
BUG=skia:4604
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2384463003
Review-Url: https://codereview.chromium.org/2384463003
diff --git a/src/gpu/gl/GrGLCaps.cpp b/src/gpu/gl/GrGLCaps.cpp
index feb3eb6..1a7b105 100644
--- a/src/gpu/gl/GrGLCaps.cpp
+++ b/src/gpu/gl/GrGLCaps.cpp
@@ -550,6 +550,15 @@
fSampleShadingSupport = true;
}
+ // TODO: support CHROMIUM_sync_point and maybe KHR_fence_sync
+ if (kGL_GrGLStandard == standard) {
+ if (version >= GR_GL_VER(3, 2) || ctxInfo.hasExtension("GL_ARB_sync")) {
+ fFenceSyncSupport = true;
+ }
+ } else if (version >= GR_GL_VER(3, 0)) {
+ fFenceSyncSupport = true;
+ }
+
// We support manual mip-map generation (via iterative downsampling draw calls). This fixes
// bugs on some cards/drivers that produce incorrect mip-maps for sRGB textures when using
// glGenerateMipmap. Our implementation requires mip-level sampling control. Additionally,