VXFL LISP: Insert Even Vertices per Segment (Free AutoLISP Download)
VXFL increases the vertex density of one or more selected polylines by inserting the same number of new, evenly-spaced vertices into every segment. Unlike text-marker-driven vertex insertion, this is a purely mathematical operation: you tell it how many new points per segment, and it distributes them uniformly along each segment's length.
VXFILL-bgol (Insert Even Vertices per Segment)
Command Type: AutoLISP routine (works in AutoCAD, BricsCAD, ZWCAD and most AutoLISP-compatible CAD platforms)
Developed by: BGol Community, bgol.in
Inspired by the general concept of uniform vertex-densification utilities used in CAD/survey drafting. This is an original, independently written routine, new file name, new command name, new source code, created so the CAD community has a free, editable, open-source alternative.
Overview
VXFL increases the vertex density of one or more selected polylines by inserting the same number of new, evenly-spaced vertices into every segment. Unlike text-marker-driven vertex insertion, this is a purely mathematical operation: you tell it how many new points per segment, and it distributes them uniformly along each segment's length.
How to Use
- Load
VXFILL-bgol.lspinto your CAD session (drag-and-drop the file onto the drawing window, or use theAPPLOADcommand). - Type
VXFLat the command line and press Enter. - Select one or more LWPOLYLINE entities.
- Enter the number of new vertices to insert per segment (default 2).
- A new, denser LWPOLYLINE is created on a dedicated layer,
BGOL-VXFL(colour blue), for each polyline selected. Original entities are left completely untouched.
Why Use It
- Precision, adds finer, uniform resolution across an entire polyline, useful for representing curves/angles more precisely once flattened into straight segments.
- User control, you decide exactly how many vertices to add per segment, tailoring detail level to the drawing's needs.
- Batch-friendly, select many polylines at once; every one gets the same densification treatment in a single run.
Where to Use It
- Increasing vertex density/resolution of a polyline uniformly, e.g., to prepare it for elevation interpolation or smoother visual appearance.
- Preparing decurved (flattened) polylines for further vertex-based processing that benefits from more granular data.
- Architectural, engineering, or artistic drafting projects needing finer control over polyline detail level.
Notes
- Works on LWPOLYLINE entities; closed polylines get new vertices inserted on the closing segment as well.
- New points are straight-line interpolations between original vertices, no curve fitting or smoothing is applied. For a smoothing pass, see the separate cross-section smoothing routine in this collection.
- Source code is fully open, feel free to study, modify, and redistribute it under the same open, free-for-all spirit.
Credits
Developed and shared for the CAD community by BGol Community. Website: https://bgol.in/ Free and open-source, use it, modify it, share it, for personal or commercial work alike.
Frequently Asked Questions
VXFL is a standard AutoLISP routine, so it runs in AutoCAD, BricsCAD, ZWCAD, and most other AutoLISP-compatible CAD platforms without modification.
Works on LWPOLYLINE entities; closed polylines get new vertices inserted on the closing segment as well.
Precision, adds finer, uniform resolution across an entire polyline, useful for representing curves/angles more precisely once flattened into straight segments.
Yes. VXFL is fully open-source and free to use, modify, and redistribute for both personal and commercial work, developed and shared by the BGol Community.
Drag and drop VXFILL-bgol.lsp onto your open drawing window, or load it through the APPLOAD command, then type VXFL at the command line to run it.
๐ค About BGol Community
BGol Community of Advanced Surveying builds and shares free, open-source tools for the survey and CAD drafting community.
๐ Made with โค๏ธ by BGol Community of Advanced Surveying
Free, open-source, and built for the CAD community, for personal or commercial use, always.