diff options
author | Ilia Mirkin <imirkin@alum.mit.edu> | 2019-02-12 21:32:27 -0500 |
---|---|---|
committer | Ilia Mirkin <imirkin@alum.mit.edu> | 2019-02-18 12:13:54 -0500 |
commit | 070a5e5d9248a77aa84375f74fe48c5067362ea8 (patch) | |
tree | c24b06fe2bec5e2a636c54fff2bb6640d970c13b /src/mesa/main/fbobject.c | |
parent | 47616810ed7cfce21d239391131ad9a5ef558b52 (diff) |
mesa: add explicit enable for EXT_float_blend, and error condition
If EXT_float_blend is not supported, error out on blending of FP32
attachments in an ES2 context.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Diffstat (limited to 'src/mesa/main/fbobject.c')
-rw-r--r-- | src/mesa/main/fbobject.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 341fd93efc6..1298e09e1b0 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -1004,6 +1004,7 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx, fb->_HasAttachments = true; fb->_IntegerBuffers = 0; fb->_RGBBuffers = 0; + fb->_FP32Buffers = 0; /* Start at -2 to more easily loop over all attachment points. * -2: depth buffer @@ -1153,6 +1154,9 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx, if (f == GL_RGB) fb->_RGBBuffers |= (1 << i); + if (type == GL_FLOAT && _mesa_get_format_max_bits(attFormat) > 16) + fb->_FP32Buffers |= (1 << i); + fb->_AllColorBuffersFixedPoint = fb->_AllColorBuffersFixedPoint && (type == GL_UNSIGNED_NORMALIZED || type == GL_SIGNED_NORMALIZED); |