[Bf-blender-cvs] [7c06167] master: Change winding of looptris in subsurf so they point to the same direction as the surface.

Antony Riakiotakis noreply at git.blender.org
Fri Jul 17 14:56:19 CEST 2015


Commit: 7c06167982fd1947b877a53f24f9dbb9ad9b6d5e
Author: Antony Riakiotakis
Date:   Fri Jul 17 14:56:10 2015 +0200
Branches: master
https://developer.blender.org/rB7c06167982fd1947b877a53f24f9dbb9ad9b6d5e

Change winding of looptris in subsurf so they point to the same
direction as the surface.

===================================================================

M	source/blender/blenkernel/intern/subsurf_ccg.c

===================================================================

diff --git a/source/blender/blenkernel/intern/subsurf_ccg.c b/source/blender/blenkernel/intern/subsurf_ccg.c
index 159e26b..df6e33e 100644
--- a/source/blender/blenkernel/intern/subsurf_ccg.c
+++ b/source/blender/blenkernel/intern/subsurf_ccg.c
@@ -3620,14 +3620,14 @@ static const MLoopTri *ccgDM_getLoopTriArray(DerivedMesh *dm)
 			lt = &mlooptri[i];
 			/* quad is (0, 3, 2, 1) */
 			lt->tri[0] = (poly_index * 4) + 0;
-			lt->tri[1] = (poly_index * 4) + 3;
-			lt->tri[2] = (poly_index * 4) + 2;
+			lt->tri[1] = (poly_index * 4) + 2;
+			lt->tri[2] = (poly_index * 4) + 3;
 			lt->poly = poly_index;
 
 			lt = &mlooptri[i + 1];
 			lt->tri[0] = (poly_index * 4) + 0;
-			lt->tri[1] = (poly_index * 4) + 2;
-			lt->tri[2] = (poly_index * 4) + 1;
+			lt->tri[1] = (poly_index * 4) + 1;
+			lt->tri[2] = (poly_index * 4) + 2;
 			lt->poly = poly_index;
 		}
 	}




More information about the Bf-blender-cvs mailing list