[Mesa-dev] [PATCH 15/16] mesa: Fix error reporting for some cases of incomplete FBO attachments
Ian Romanick
idr at freedesktop.org
Thu Dec 11 18:28:41 PST 2014
On 12/11/2014 02:34 PM, Eduardo Lima Mitev wrote:
> From: Iago Toral Quiroga <itoral at igalia.com>
>
> According to the OpenGL and OpenGL ES specs (sections
> "FRAMEBUFFER COMPLETENESS" and "Whole Framebuffer Completeness"),
> the image for color, depth or stencil attachments must be renderable,
> otherwise the attachment is considered incomplete and we should report
> GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT. Currently, we detect this
> situation properly but report a different error.
>
> This fixes the following 3 piglit tests:
> dEQP-GLES3.functional.fbo.completeness.renderable.texture.color0.rgb_unsigned_int_2_10_10_10_rev
> dEQP-GLES3.functional.fbo.completeness.renderable.texture.color0.rgba_unsigned_int_2_10_10_10_rev
> dEQP-GLES3.functional.fbo.completeness.renderable.texture.color0.rgb16f
> ---
> src/mesa/main/fbobject.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c
> index a18f11c..28ba45f 100644
> --- a/src/mesa/main/fbobject.c
> +++ b/src/mesa/main/fbobject.c
> @@ -966,7 +966,7 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx,
> if (!is_format_color_renderable(ctx, attFormat,
> texImg->InternalFormat) &&
> !is_legal_depth_format(ctx, f)) {
> - fb->_Status = GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT;
> + fb->_Status = GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT;
If we're going to change the enum, use the non-_EXT version. With that
fixed, this patch is
Reviewed-by: Ian Romanick <ian.d.romanick at intel.com>
> fbo_incomplete(ctx, "texture attachment incomplete", -1);
> return;
> }
>
More information about the mesa-dev
mailing list