Exporting to CAD (DXF and 1:1 SVG)

Download your plan as a DXF for LibreCAD, QCAD, Fusion 360 or AutoCAD, or as a true-size SVG for a laser cutter or a CNC router, with boards, track, joins and the benchwork framing each on their own layer.

Sometimes the plan has to go on into another program: a CAD program to draw the benchwork round it, a laser cutter to cut a roadbed or a template, a CNC router to cut a board to shape. Export to CAD writes the plan as a file those programs open at true size, with each kind of line on its own layer so you keep only what you need.

Making one

#

Export → Export to CAD… in the editor's top bar (or Export to CAD in the command palette) opens the CAD export dialog. Choose:

  • Format. DXF opens in LibreCAD, QCAD, Fusion 360, AutoCAD and Inkscape, and in laser software such as LightBurn. SVG 1:1 opens in Inkscape, LightBurn or your cutter's own software.
  • Draw. The whole layout, or one board on its own (on a layout with boards).
  • Layers. Tick the kinds of line you want: board outlines, track outlines, track centrelines, rail joins and buildings. Part numbers on the track adds each piece's catalogue number as text.
  • Include benchwork framing. With the Benchwork & Cut List module, adds the frame under your boards on layers of its own (see Benchwork framing below). The box shows when the layout has boards to frame, and like the other choices it's remembered for next time.

The Pro options work here too: Leave out hidden layers draws only what the canvas shows, and Deck draws one level of a layout with several decks.

What's in the file

#
LayerWhat's on itColour
BOARDSEach board's outlinewhite or black
TRACK_OUTLINEEach piece's bed, its real width: one outline for each road of a turnout, as the 1:1 print draws it, and one round a whole piece of flexdark grey
TRACK_CENTRELINEThe middle of the trackred
JOINSA short line across the track at each rail joinblue
JOINS_INSULATEDThe same, for joins with insulated rail joinersmagenta
STRUCTURESThe outlines of buildings and other structurescyan
PART_NUMBERSEach piece's catalogue number, centred on itgreen

On a layout with several decks, every layer comes once per deck, named after it (UPPER-TRACK_CENTRELINE), so you can show one level at a time. A board you've tied to a deck goes on that deck's BOARDS layer.

Benchwork framing

#

Tick Include benchwork framing and the frame the Benchwork & Cut List module works out goes in the file too, drawn where it sits under the boards, from your benchwork settings:

LayerWhat's on itColour
BENCHWORK_FRAMEEach rail and cross-member seen from above, at its true size: the timber's thickness across, its ends square or mitred as they're cutorange
BENCHWORK_LEGSEach leg's footprintbrown
BENCHWORK_JOINTSWhere boards are bolted together, and where an L-shaped board's boxes are: each bolt as a circle its real size (8 mm for M8, or 5/16 in) on the line the two meet along, and each alignment dowel as a small cross on its centrered-orange
BENCHWORK_LABELSEach part's letter, at its middle, as in the cut listgrey

The dowels are crosses rather than circles because their size is whichever dowels you buy: the module doesn't choose one. The legs' coach bolts are counted in the shopping list but not placed, so they aren't drawn. Bolts and dowels are marked on the line where two boards meet, so on one board drawn on its own their marks reach a few millimetres past its edge; hide BENCHWORK_JOINTS if your router mustn't see anything there.

With the whole layout in the file, each letter starts with its board's number (2B is part B on Board 2), as the cutting plan reads. One board on its own brings that board's framing alone, with the bolts and dowels on the edges it shares with its neighbours, lettered as on its own sheet, and turned into the board's frame with everything else. On a layout with several decks the benchwork layers come per deck as well (UPPER-BENCHWORK_FRAME).

The parts are drawn where they go, not laid out flat to cut: a file of each part on its own, for a CNC router to cut, isn't done yet.

Size and position

#

Everything is in millimetres, at 1:1: 1 mm of track is 1 mm in the file. A DXF says so in its header ($INSUNITS), so a program that reads units opens it at the right size; one that asks, wants millimetres.

The plan comes out the way the canvas shows it, X to the right and Y up:

  • The whole layout keeps the plan's own coordinates, so two files exported from the same layout line up.
  • One board on its own is drawn in the board's own frame: turned square, its front along X, and the lower-left corner of its outline at 0,0, so every coordinate is positive. That's what a CNC router wants. Pieces that run onto the next board are drawn whole, so you can see where they go.

Exact curves

#

Curves stay curves, not chains of short straights:

  • a straight is a line and a curve an arc, with its true centre and radius; a turnout is its roads, each a line or an arc;
  • a curved board edge and a curved bed outline are arcs too;
  • flex track keeps its straights and curves exact. Its easements (where the curve tightens gradually) are spirals, which DXF can't hold, so they're written as a run of very short arcs that stays within a hundredth of a millimetre of the true curve.

The file is flat: everything sits at height 0. A helix shows as its turns drawn over one another, as in the plan.

The DXF

#

The DXF is a plain-text file in the format of AutoCAD release 12, the version almost every program reads. Part numbers use the standard CAD font, so they look a little different from the planner's.

The 1:1 SVG

#

The SVG's page is the drawing's size, given in millimetres, so it imports at true size without a scale to set. Lines are thin (0.1 mm) and in their layer's colour, with nothing filled in, and each layer is a layer in Inkscape. Most laser software sets cutting, scoring or engraving by colour, so you can give each layer its own setting.

Export image's PNG and JPEG are pictures for the screen, measured in pixels, not to scale. For a file to cut, use this one.

Tips

#
  • Check the size before you cut: measure a straight you know in your CAD or laser program.
  • Turn off the layers you don't want cut, such as the part numbers and centrelines, or untick them before you export.
  • Track outlines overlap where a turnout's roads meet, just as on the 1:1 print. Merge them in your CAD program if you want one outline to cut.

Not included

#

Scenery zones, text labels and heights aren't in the file, and nor are the benchwork's parts laid out flat for cutting.