Fix T41862: Autosmooth & multi-material glitch
This commit is contained in:
parent
87208fa699
commit
3c28eecb6e
Notes:
blender-bot
2023-02-14 10:08:17 +01:00
Referenced by issue #41862, Shading problems with Autosmooth & Material Transparency Referenced by issue #41684, Auto Smooth produce shadow (shading) problems
|
@ -1324,13 +1324,11 @@ static void cdDM_drawMappedFacesGLSL(DerivedMesh *dm,
|
|||
glNormal3fv(nor);
|
||||
}
|
||||
}
|
||||
|
||||
if (lnors) {
|
||||
ln1 = &lnors[0][0];
|
||||
ln2 = &lnors[0][1];
|
||||
ln3 = &lnors[0][2];
|
||||
ln4 = &lnors[0][3];
|
||||
lnors++;
|
||||
else if (lnors) {
|
||||
ln1 = &lnors[a][0];
|
||||
ln2 = &lnors[a][1];
|
||||
ln3 = &lnors[a][2];
|
||||
ln4 = &lnors[a][3];
|
||||
}
|
||||
|
||||
cddm_draw_attrib_vertex(&attribs, mvert, a, mface->v1, 0, ln1, smoothnormal);
|
||||
|
@ -1651,13 +1649,11 @@ static void cdDM_drawMappedFacesMat(DerivedMesh *dm,
|
|||
glNormal3fv(nor);
|
||||
}
|
||||
}
|
||||
|
||||
if (lnors) {
|
||||
ln1 = &lnors[0][0];
|
||||
ln2 = &lnors[0][1];
|
||||
ln3 = &lnors[0][2];
|
||||
ln4 = &lnors[0][3];
|
||||
lnors++;
|
||||
else if (lnors) {
|
||||
ln1 = &lnors[a][0];
|
||||
ln2 = &lnors[a][1];
|
||||
ln3 = &lnors[a][2];
|
||||
ln4 = &lnors[a][3];
|
||||
}
|
||||
|
||||
/* vertices */
|
||||
|
|
Loading…
Reference in New Issue