Extract points from brep as shown in image with rhino3dm js

Hi @dale @fraguada,

How do I get the following points from this brep as shown in the image using rhino3dm.js?

1.Get the largest face
2.Filter the largest face based on condition (I’m not sure what your requirements are to chose the top or bottom face in this case)
3.Extract curve start and end points
4.Remove the duplicate points
You’re left off with p1,p2,3,p4 and so on.

Hi Farouk,

Thank you for your help. I am more or less aware of the logic.

I was looking for the specific code in rhino3dm.js as it is different from rhinocommon. Rhino3dmjs also is not as well documented as rhinocommon which makes the job a bit more difficult.

Thanks again.

For some reason we are not exposing the BrepVertexList. I will check out why that is since I believe it is already exposed in the .net lib. Unfortunately for now you’d need to somehow get that info from going through the BrepEdgeList and then go through all of the brep edges and extract points. Having the BrepVertexList will be a bit less painful, but there is no guarantee that the points will be in any useful order.

1 Like

Cool. Makes sense. Thank you @fraguada