diff options
author | Francisco Jerez <[email protected]> | 2018-02-12 14:48:20 -0800 |
---|---|---|
committer | Francisco Jerez <[email protected]> | 2018-02-24 15:28:36 -0800 |
commit | 378e918e2891b2712b64c4ad1ef92bfc539a13e7 (patch) | |
tree | fc508b27410980b09b84d9f804f2f2744a25d366 /src/mesa | |
parent | e4124f9bc119ae22e34daea6f44bd3ddec454ec7 (diff) |
mesa: Implement glFramebufferFetchBarrierEXT entry point.
Reviewed-by: Plamena Manolova <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/main/barrier.c | 17 | ||||
-rw-r--r-- | src/mesa/main/barrier.h | 3 | ||||
-rw-r--r-- | src/mesa/main/tests/dispatch_sanity.cpp | 6 |
3 files changed, 24 insertions, 2 deletions
diff --git a/src/mesa/main/barrier.c b/src/mesa/main/barrier.c index 0f0b0a210d1..2be30220e49 100644 --- a/src/mesa/main/barrier.c +++ b/src/mesa/main/barrier.c @@ -127,8 +127,7 @@ _mesa_BlendBarrier(void) { GET_CURRENT_CONTEXT(ctx); - if (!ctx->Extensions.EXT_shader_framebuffer_fetch_non_coherent && - !ctx->Extensions.KHR_blend_equation_advanced) { + if (!ctx->Extensions.KHR_blend_equation_advanced) { _mesa_error(ctx, GL_INVALID_OPERATION, "glBlendBarrier(not supported)"); return; @@ -136,3 +135,17 @@ _mesa_BlendBarrier(void) ctx->Driver.FramebufferFetchBarrier(ctx); } + +void GLAPIENTRY +_mesa_FramebufferFetchBarrierEXT(void) +{ + GET_CURRENT_CONTEXT(ctx); + + if (!ctx->Extensions.EXT_shader_framebuffer_fetch_non_coherent) { + _mesa_error(ctx, GL_INVALID_OPERATION, + "glFramebufferFetchBarrierEXT(not supported)"); + return; + } + + ctx->Driver.FramebufferFetchBarrier(ctx); +} diff --git a/src/mesa/main/barrier.h b/src/mesa/main/barrier.h index 53ecf863f07..acc15c67794 100644 --- a/src/mesa/main/barrier.h +++ b/src/mesa/main/barrier.h @@ -53,4 +53,7 @@ _mesa_MemoryBarrierByRegion(GLbitfield barriers); void GLAPIENTRY _mesa_BlendBarrier(void); +void GLAPIENTRY +_mesa_FramebufferFetchBarrierEXT(void); + #endif /* BARRIER_H */ diff --git a/src/mesa/main/tests/dispatch_sanity.cpp b/src/mesa/main/tests/dispatch_sanity.cpp index d697343627e..83a4b046542 100644 --- a/src/mesa/main/tests/dispatch_sanity.cpp +++ b/src/mesa/main/tests/dispatch_sanity.cpp @@ -1023,6 +1023,9 @@ const struct function common_desktop_functions_possible[] = { /* GL_ARB_gl_spirv */ { "glSpecializeShaderARB", 45, -1 }, + /* GL_EXT_shader_framebuffer_fetch_non_coherent */ + { "glFramebufferFetchBarrierEXT", 20, -1 }, + { NULL, 0, -1 } }; @@ -2446,6 +2449,9 @@ const struct function gles2_functions_possible[] = { { "glGetQueryObjectui64vEXT", 20, -1 }, { "glQueryCounterEXT", 20, -1 }, + /* GL_EXT_shader_framebuffer_fetch_non_coherent */ + { "glFramebufferFetchBarrierEXT", 20, -1 }, + { NULL, 0, -1 } }; |