I'm trying to figure out a way to determine the number of connected
components (i.e. pieces) of a mesh (as apparently normal maps have to be
done separately for each component). does meshlab include this
functionality? if not, this is the way I was thinking of doing it:
pick an arbitrary face, and traverse every adjacent face that hasn't been
visited yet, until there are none left, at which point those traversed
should form one component. then you would pick an un-visited face and
continue...
questions:
1) what does "face-face adjacency" mean in the documentation?
2) are the FFp members calculated automatically when you add new faces to
the mesh, or is their some function similar to updateNormals that you have
to call? (from the wiki: "FFp(i) member store the pointer of the face that
is adjacent to the current face along the i-th edge")
3) are there any problems with the above approach?
thanks,
imran
|