intel: fix EGLImage renderbuffer _BaseFormat
authorFrank Henigman <fjhenigman@google.com>
Thu, 19 Feb 2015 23:09:20 +0000 (15:09 -0800)
committerChad Versace <chad.versace@intel.com>
Tue, 3 Mar 2015 18:58:42 +0000 (10:58 -0800)
Correctly set _BaseFormat field when creating a gl_renderbuffer
with EGLImage storage.

Change-Id: I8c9f7302d18b617f54fa68304d8ffee087ed8a77
Signed-off-by: Frank Henigman <fjhenigman@google.com>
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Reviewed-by: Chad Versace <chad.versace@intel.com>
src/mesa/drivers/dri/i915/intel_fbo.c
src/mesa/drivers/dri/i965/intel_fbo.c

index 1e1397d747f285c19e0ffc93cb7a37ac2b968c0f..8ce1dbf69de45ba02881c34cf5ec469e0ead923f 100644 (file)
@@ -287,8 +287,7 @@ intel_image_target_renderbuffer_storage(struct gl_context *ctx,
    rb->Width = image->region->width;
    rb->Height = image->region->height;
    rb->Format = image->format;
-   rb->_BaseFormat = _mesa_base_fbo_format(&intel->ctx,
-                                          image->internal_format);
+   rb->_BaseFormat = _mesa_get_format_base_format(image->format);
    rb->NeedsFinishRenderTexture = true;
 }
 
index 04e50306ba308c0682137e121a4a7867e722e0fa..90fd064e836a16e7ef05de20d470af7717e6d073 100644 (file)
@@ -398,7 +398,7 @@ intel_image_target_renderbuffer_storage(struct gl_context *ctx,
    rb->Width = image->width;
    rb->Height = image->height;
    rb->Format = image->format;
-   rb->_BaseFormat = _mesa_base_fbo_format(ctx, image->internal_format);
+   rb->_BaseFormat = _mesa_get_format_base_format(image->format);
    rb->NeedsFinishRenderTexture = true;
    irb->layer_count = 1;
 }