remove another redundant pass checking earness
This commit is contained in:
parent
2640034124
commit
e0fa99bad4
@ -297,19 +297,17 @@ void SContour::UvTriangulateInto(SMesh *m, SSurface *srf) {
|
|||||||
|
|
||||||
int i;
|
int i;
|
||||||
// Clean the original contour by removing any zero-length edges.
|
// Clean the original contour by removing any zero-length edges.
|
||||||
|
// initialize eartypes to unknown while we're going over them.
|
||||||
l.ClearTags();
|
l.ClearTags();
|
||||||
|
l[0].ear = EarType::UNKNOWN;
|
||||||
for(i = 1; i < l.n; i++) {
|
for(i = 1; i < l.n; i++) {
|
||||||
|
l[i].ear = EarType::UNKNOWN;
|
||||||
if((l[i].p).Equals(l[i-1].p)) {
|
if((l[i].p).Equals(l[i-1].p)) {
|
||||||
l[i].tag = 1;
|
l[i].tag = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
l.RemoveTagged();
|
l.RemoveTagged();
|
||||||
|
|
||||||
// Now calculate the ear-ness of each vertex
|
|
||||||
for(i = 0; i < l.n; i++) {
|
|
||||||
(l[i]).ear = IsEar(i, scaledEps) ? EarType::EAR : EarType::NOT_EAR;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool toggle = false;
|
bool toggle = false;
|
||||||
while(l.n > 3) {
|
while(l.n > 3) {
|
||||||
int bestEar = -1;
|
int bestEar = -1;
|
||||||
|
Loading…
Reference in New Issue
Block a user