Rhino 6 ngon adjacent vertices, edges, faces


#1

Hi,
Is it possible to provide a simple example of accessing the adjacent vertices,edges,faces in an ngon mesh?
I am getting some confusing results.
For example the MeshTopologyVertexList.ConnectedEdges() method somehow returns not the adjacent edges of a mesh vertex, but somehow the adjacent edges, as if all ngon faces have been triangulated.

Am I missing something or there might be a different way of accessing the topology of ngon meshes in Rhino 6 (different from the one we used in Rhino 5)?

Any help would be welcome.


(Dale Fugier) #3

Hi @djordje,

Keep in mind that the function you reference does not take ngons into account.

Can you give us a better idea of what you are trying to do and why? This might help us provide a good solution.

Thanks,

– Dale


#4

Hi Dale,

I have a Rhino mesh which consists of triangle faces, quads and ngon faces. They are all joined together, and possibly welded. I would like to extract the adjacent vertex, edges, faces information from that mesh.
It can be any mesh consisted of upper mentioned ones.

Okay. So I need to somehow access the adjacency data from MeshNgonsList? Can some C#/VB.NET/Python example code be provided, please?


(Dale Fugier) #5

Hi @djordje,

An ngon does not contain this kind of information. However, this is possible to figure out (with some bookkeeping). An ngon contains lists of ordered vertices. Thus, adjacent ngons will share the same two (or more) topological vertices (but the order will probably be reversed).

Does this help?

– Dale