Fix #35354: dyntopo - materials and UI display issues

Textured dyntopo draw was leaving 2d textures enabled when it shouldn't.

Root of the issue was figured out by Campbell, actual place where
2D textures left enabled found by self.

Also, simplified fix is suggested by Campbell (mine was 2 lines longer! :)
This commit is contained in:
Sergey Sharybin
2013-05-15 12:33:28 +00:00
parent 8230584582
commit a5dd469a06

View File

@@ -658,9 +658,8 @@ static void cdDM_drawFacesTex_common(DerivedMesh *dm,
*/
if (cddm->pbvh && cddm->pbvh_draw && BKE_pbvh_type(cddm->pbvh) == PBVH_BMESH) {
if (dm->numTessFaceData) {
glDisable(GL_TEXTURE_2D);
GPU_set_tpage(NULL, false, false);
BKE_pbvh_draw(cddm->pbvh, NULL, NULL, NULL, FALSE);
glEnable(GL_TEXTURE_2D);
}
return;