Skip to main content

Rhino

Connect Giraffe and Rhino

Holly Conrad Smith avatar
Written by Holly Conrad Smith
Updated over a month ago

Rhino, or Rhinoceros, is a powerful 3D modeling software used in various fields like architecture, industrial design, and product design for its ability to create precise, freeform shapes. It specializes in NURBS (Non-Uniform Rational B-Splines) curves, surfaces, and solids, allowing for complex designs with high precision, and also supports polygon meshes and point clouds. Rhino can be integrated with its visual scripting add-on, Grasshopper, to create complex generative designs and is compatible with hundreds of other CAD, CAM, and rendering programs.

Bring Giraffe into Rhino

Bringing Giraffe into Rhino as editable geometries requires some scripting.

We have created a set of scripts to help you convert Giraffe GeoJSON to Rhino geometries. While some basic knowledge of Python is helpful, the necessary scripts have been created and provided by the Giraffe team to streamline the process.

Giraffe Export Menu

For Rhino compatibility, we recommend exporting as a GeoJSON (in longitude, latitude or the project defined coordinate transform)

Access the export menu via the main menu (☰) → Export -> Projected GeoJSON

Download your Python Script

Giraffe to Rhino projected - Python script

The file ‘giraffeToRhino_projected’ accounts for XY Euler/Cartesian coordinates

Giraffe to Rhino - Python script

The file ‘giraffeToRhino’ accounts for longitude and latitude coordinates

Run the Script in Rhino

  1. In the command line, type ‘RunPythonScript’

  2. Select and open the relevant script that you downloaded at the start of this guide

  3. Another window will appear - select the GeoJSON file export from Giraffe

  4. Click Ok to continue

  5. Success! You’ve now imported you Giraffe model into Rhino.

Bring Rhino Into Giraffe

Giraffe is much simpler than Rhino. Rhino deals with all sorts of geometries while Giraffe only uses extrusions defined by a format called geojson.

Editable

To bring a Rhino file into Giraffe as editable geometries, you should convert your Rhino model to GeoJSON, then Upload the GeoJSON as a layer or simply copy/paste the JSON into your Giraffe window.

The following script reads in a Rhino Geometry, sections it to create polylines, adds the correct attribution and exports the polylines as a geoJSON.

The script uses decoding spaces to project from Rhino coordinates to global coordinates. This requires the user to know what projection their Rhino file is in. The user can copy the WKT format of their local projection into a panel in Grasshopper in order to get the right projection. We use https://spatialreference.org/ to find the WKT.

Alternatively, use a plugin like ShrimpGIS to create the GeoJSON.

Visual Only

Export as GLTF from Rhino, then upload the 3D model.

Did this answer your question?