Draws a rafter as it is actually cut — the sloping member, the birdsmouth seat where it sits on the wall plate, the tail overhang, and the blocking behind the seat. RAFTER draws a single cut rafter; RAFTERTRUSS draws a truss rafter with separate top and bottom cords. Both will mirror about the ridge to give you the opposite side in the same operation.
What RafterCut does
Note: there are two RAFTER routines on this site. This one and the older RAFTER LISP both define a command called RAFTER, so load one or the other, not both — whichever is loaded second silently replaces the first. They solve the job differently and both are worth having, so neither has been retired.
Pitch is given as rise and run, because that is how a roof is specified and how a framing square is set. Give 6 and 12 for a 6-in-12 roof; the routine works out the angle.
How to use it
- Load the routine with
APPLOAD, or put it on your support file search path. - Type
RAFTERorRAFTERTRUSS. - Give the pitch as rise and run, and the member depth, tail and seat dimensions.
- Pick the seat point first, then the ridge.
- Mirror about the ridge if you want the opposite side.
How it works
The trigonometry, said plainly:
pitch angle = (atan rise run)
vertical depth of a
rafter cut square = depth / (cos pitch)
The routine this replaces carried two helper functions that between them ran to nine lines of nested polar and sqrt calls, building right triangles out of unit vectors to recover an angle. They compute exactly the two lines above.
The second is the standard result that a member of perpendicular depth D, laid at a pitch, measures D / cos(pitch) when you measure it vertically. That is the dimension the tail cut is set out from.
Which way the roof slopes comes from your two picks. Seat point first, ridge second — drawing right to left is as valid as left to right, and the seat, the blocking and the tail all flip with it.
The baseline must be horizontal, because a wall plate is, and the routine says so rather than drawing a nonsense rafter.
Notes and limits
- Command name clash. Do not load this alongside the older RAFTER LISP.
- Pitch as rise and run, the way a framing square is set.
- Seat point first, ridge second — that sets the hand.
- One undo group covers the rafter.
Download and details
| Name | RafterCut — draw a rafter as it is actually cut |
| Download | RafterCut.lsp — 13.9 KB, plain AutoLISP source. Downloads directly; no zip to unpack. |
| Type | AutoCAD AutoLISP routine |
| Commands | RAFTER, RAFTERTRUSS |
| Requires | nothing beyond a CAD platform with AutoLISP. |
| Source size | 13.9 KB, 337 lines |
| Error handling | Yes — a *error* handler restores every system variable it changed, on cancel as well as on error. |
| Undo | The whole operation is wrapped in a single undo group, so one U reverses all of it. |
| Compatibility | AutoCAD (any release with AutoLISP), BricsCAD, ZWCAD, GstarCAD, ProgeCAD and other IntelliCAD-based platforms. AutoCAD LT needs a LISP enabler. No .NET, no ObjectARX, no installer. |
| Author | YZ, August 2026 |
| Licence | Free to use, supplied “as is” with no warranty. |
References
- RAFTER LISP — the older routine of the same command name
- TRUSSFRAME LISP — the whole truss in six web patterns
- ROOFPITCH LISP — the pitch triangle the numbers come from
- More free AutoLISP routines on this site
- Wisey’s Steel Shapes — free structural steel section drawing program