- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi everyone,
I'm using a LISP routine that generates a rebar mesh inside a concrete slab, based on a closed polyline or a circle. The script asks for a cover distance and spacing, creates an inward offset, and then draws horizontal and vertical bars that should be trimmed to fit within the offset boundary.
The routine works perfectly when the slab is a rectangle (see image 1), but when using irregular, circular, or triangular shapes, the bars are not trimmed properly (see image 2). Full-length bars are drawn, ignoring the actual shape of the slab.
Figura 1
Figura 2
The trimming is done using IntersectWith, but I believe the code assumes there are always exactly two intersection points per bar, which doesn't hold true for more complex shapes.
Any guidance on how to adapt the routine so that it works with any closed polyline, regardless of shape, would be greatly appreciated.
Thanks in advance!
(Images attached)
Attached lisp and dwg file
Solved! Go to Solution.