From: Brian Paul Date: Fri, 6 Mar 2009 00:04:27 +0000 (-0700) Subject: i965: fix screen depth test in intel_validate_framebuffer)_ X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ee41bb2ed01b9480e5370d67257334b81ec0c90e;p=mesa.git i965: fix screen depth test in intel_validate_framebuffer)_ front_region may be null. --- diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c index 787c2900221..a401f730ba2 100644 --- a/src/mesa/drivers/dri/intel/intel_fbo.c +++ b/src/mesa/drivers/dri/intel/intel_fbo.c @@ -653,7 +653,8 @@ intel_validate_framebuffer(GLcontext *ctx, struct gl_framebuffer *fb) * screen depth. There currently seems to be a problem when * rendering into a rgb565 texture when the screen is abgr8888. */ - if (intel->front_region->cpp == 4) + + if (intel->ctx.Visual.rgbBits >= 24) supportedFormat = &_mesa_texformat_argb8888; else supportedFormat = &_mesa_texformat_rgb565;