EXPORTGEOJSON
EXPORTGEOJSON writes drawing geometry to a GeoJSON file (.json), for example to use it in a GIS or map program. You choose whether to export the whole drawing or only a selection, and which kinds of objects are included.
Starting
Type EXPORTGEOJSON on the command line, or use the button in the ribbon on the SCAD Data / Export tab, GIS panel.
How it works
- An
Export GeoJSONwindow opens. Under Source, choose what to export and tick which object types to include (seeOptions). - Click Export. If no type is ticked you get
Select at least one entity type.and the window stays open. Cancel ends the command. - A save window
Export GeoJSONopens. The file name defaults to the drawing name with.json. - If you chose Selection, BricsCAD now asks for the objects to export. Select them and confirm with Enter.
- The command line shows
GeoJSON exported: N features to <path>. If nothing usable was found, the command reportsNo geometry found to export.and no file is written. If you select nothing in Selection mode it saysNo selection.
Options
Source
| Option | What it does |
|---|---|
| All entities | Default. Exports everything in model space. |
| Selection | Exports only the objects you select afterwards. |
Object types — all types are on by default. The tick box at 3D Entities or 2D Entities switches the whole group on or off at once.
| Group | Types | Ends up in the file as |
|---|---|---|
| 3D Entities | Solid3d, Surface, SubDMesh, PolyFaceMesh, PolygonMesh, Face, Region, Body | Surfaces, split into triangles |
| 2D Entities | Line, Arc, MLine | Line |
| 2D Entities | Polyline, Polyline2d, Polyline3d | Closed: area. Open: line |
| 2D Entities | Circle, Solid, Hatch, Wipeout | Area |
| 2D Entities | Ellipse, Spline | Full ellipse and closed spline: area. Otherwise: line |
| 2D Entities | Point | Point |
Each object is written with its layer, object type, colour and opacity.