added useful he functions
This commit is contained in:
parent
b89a689a15
commit
6ca76c16b1
|
@ -1669,6 +1669,31 @@ namespace vcg
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static vector<FacePointer> get_adjacent_faces(FacePointer fp)
|
||||||
|
{
|
||||||
|
assert(fp);
|
||||||
|
assert(!fp->IsD());
|
||||||
|
|
||||||
|
vector<FacePointer> ret;
|
||||||
|
|
||||||
|
Pos<MeshType> p( fp->FHp() );
|
||||||
|
assert(p.F() == fp);
|
||||||
|
|
||||||
|
do
|
||||||
|
{
|
||||||
|
p.FlipF();
|
||||||
|
ret.push_back( p.F() );
|
||||||
|
p.FlipF();
|
||||||
|
|
||||||
|
p.FlipV();
|
||||||
|
p.FlipE();
|
||||||
|
|
||||||
|
} while(p.HE() != fp->FHp());
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* Gets all hedges incident to a vertex
|
* Gets all hedges incident to a vertex
|
||||||
*
|
*
|
||||||
|
|
|
@ -100,6 +100,17 @@ namespace vcg
|
||||||
return he->HOp()->HVp();
|
return he->HOp()->HVp();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* Gets opposite vertex
|
||||||
|
*/
|
||||||
|
VertexPointer Vo()
|
||||||
|
{
|
||||||
|
if(!direction)
|
||||||
|
return he->HVp();
|
||||||
|
else
|
||||||
|
return he->HOp()->HVp();
|
||||||
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* Gets pointed hedge
|
* Gets pointed hedge
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in New Issue