isotropic remeshing: added early face selection check in collapse functions
This commit is contained in:
parent
f8c3e2baef
commit
ad5183e567
|
|
@ -475,14 +475,14 @@ private:
|
||||||
tri::UpdateFlags<MeshType>::VertexBorderFromNone(m);
|
tri::UpdateFlags<MeshType>::VertexBorderFromNone(m);
|
||||||
|
|
||||||
for(auto fi=m.face.begin(); fi!=m.face.end(); ++fi)
|
for(auto fi=m.face.begin(); fi!=m.face.end(); ++fi)
|
||||||
if(!(*fi).IsD())
|
if(!(*fi).IsD() && (params.selectedOnly == false || fi->IsS()))
|
||||||
{
|
{
|
||||||
for(auto i=0; i<3; ++i)
|
for(auto i=0; i<3; ++i)
|
||||||
{
|
{
|
||||||
PosType pi(&*fi, i);
|
PosType pi(&*fi, i);
|
||||||
++candidates;
|
++candidates;
|
||||||
VertexPair bp = VertexPair(pi.V(), pi.VFlip());
|
VertexPair bp = VertexPair(pi.V(), pi.VFlip());
|
||||||
Point3<ScalarType> mp = (pi.V()->P()+pi.VFlip()->P())/2.f;;
|
Point3<ScalarType> mp = (pi.V()->P()+pi.VFlip()->P())/2.f;
|
||||||
bool boundary = false;
|
bool boundary = false;
|
||||||
|
|
||||||
if(pi.V()->IsB() == pi.VFlip()->IsB())
|
if(pi.V()->IsB() == pi.VFlip()->IsB())
|
||||||
|
|
@ -581,7 +581,7 @@ private:
|
||||||
int count = 0;
|
int count = 0;
|
||||||
|
|
||||||
for(auto fi=m.face.begin(); fi!=m.face.end(); ++fi)
|
for(auto fi=m.face.begin(); fi!=m.face.end(); ++fi)
|
||||||
if(!(*fi).IsD())
|
if(!(*fi).IsD() && (params.selectedOnly == false || fi->IsS()))
|
||||||
{
|
{
|
||||||
for(auto i=0; i<3; ++i)
|
for(auto i=0; i<3; ++i)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue