From: Xiang, Haihao Date: Wed, 30 Apr 2008 08:27:52 +0000 (+0800) Subject: intel: test cpp to ensure mipmap tree matches texture image. X-Git-Tag: 062012170305~18726 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d12fa3511da23d8285f3ea1a51a1f328cdbb1462;p=profile%2Fivi%2Fmesa.git intel: test cpp to ensure mipmap tree matches texture image. --- diff --git a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c index 55503f4..9205627 100644 --- a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c +++ b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c @@ -272,6 +272,11 @@ intel_miptree_match_image(struct intel_mipmap_tree *mt, image->IsCompressed != mt->compressed) return GL_FALSE; + if (!image->IsCompressed && + !mt->compressed && + image->TexFormat->TexelBytes != mt->cpp) + return GL_FALSE; + /* Test image dimensions against the base level image adjusted for * minification. This will also catch images not present in the * tree, changed targets, etc.