To avoid having to process the session file over and over again to extract the information about the form diagram, we export the Form Diagram data to a separate JSON file (form.json
) that can then be used as input instead. We also draw the form diagram as a simple mesh in Rhino.
After exporting the data we can create the form diagram as follows.
For this discretisation exercise, we will use the form diagram and thrust surface resulting from a pattern designed "from freatures" and inspired by the geometry and boundary conditions of the British Museum. We will generate a tessellation based on the dual of a remeshed triangulation of the thrust surface.
We will do this in small incremental steps using JSON files to store various updated versions of the Form Diagram mesh and communicate between parts of the procedure.
To triangulate the Form Diagram mesh we can simply convert all quads to triangles. Note that the quality of the resulting mesh is not considered in this step. This is okay because we will still improve mesh quality through remeshing.
For the remeshing we will use compas_cgal
. The underlying remeshing function in CGAL is documented here: https://doc.cgal.org/latest/Polygon_mesh_processing/index.html#title7
We will remesh in VS Code using the COMPAS viewer for visualisation, and again export the result to JSON to continue working with the remeshed triangulation in Rhino. The result is available for download at the bottom of this page.
Note that you could also do this directly from Rhino using the RPC cloud. However, the current procedure illustrates an alternative workflow using CPython directly in an editor outside of Rhino.