Homeโ€บ Blogโ€บ SP2P LISP: Convert Smooth Polyline to Regular Polyline Free Download
๐Ÿ“ LISP

SP2P LISP: Convert Smooth Polyline to Regular Polyline Free Download

๐Ÿงฎ 3  |  ๐ŸŸข 3
10 Mar 2026 Trishunya Team
SP2P LISP: Convert Smooth Polyline to Regular Polyline Free Download
๐Ÿ“ LISP · CAD UTILITIES

SP2P LISP: Convert Smooth Polyline to Regular Polyline (Free AutoLISP Download)

๐Ÿ“… 10 Mar 2026 ๐Ÿท๏ธ CAD BGBgol Global
SP2P AutoLISP routine, Convert Smooth Polyline to Regular Polyline, shown inside a CAD window

SP2P converts a smoothed (PEDIT โ†’ Spline) polyline back into a regular polyline built from many closely-spaced straight segments that trace the smooth curve's true shape. AutoCAD's spline-fit smoothing is purely cosmetic, many LISP tools still only see the original coarse vertices. This routine bridges that gap.

SPL2SEG-bgol (Convert Smooth Polyline to Regular Polyline)

CATEGORY
Polyline Lisps
COMMAND NAME
SP2P
LISP FILE
SPL2SEG-bgol.lsp
LICENSE
Open-source, free

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 spline-to-polyline resampling 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

SP2P converts a smoothed (PEDIT โ†’ Spline) polyline back into a regular polyline built from many closely-spaced straight segments that trace the smooth curve's true shape. AutoCAD's spline-fit smoothing is purely cosmetic, many LISP tools still only see the original coarse vertices. This routine bridges that gap.

How to Use

  1. Load SPL2SEG-bgol.lsp into your CAD session (drag-and-drop the file onto the drawing window, or use the APPLOAD command).
  2. Type SP2P at the command line and press Enter.
  3. Select the smoothed (splined) LWPOLYLINE.
  4. A new, densely-segmented regular polyline that closely traces the original smooth curve is created on a dedicated layer, BGOL-SP2P (colour cyan). The original smooth polyline is left untouched.

Why Use It

  • Bridges cosmetic vs. real geometry, spline-fit smoothing is visual only; this produces a polyline other LISP routines can process correctly.
  • Keeps the smooth look, the dense segment spacing still appears visually smooth at normal zoom levels.
  • Prep step, useful before running any other vertex-dependent routine (coordinate export, vertex marking, interpolation) on a polyline that was originally smoothed for presentation.

Where to Use It

  • Converting aesthetically smoothed survey or design lines back into a computationally usable, densely-segmented polyline.
  • Preparing curve-heavy drawings for export or analysis tools that require actual polyline vertex data rather than a spline definition.
  • Any workflow where a polyline was smoothed for visual presentation but now needs vertex-based processing.

Notes

  • Sampling density defaults to 60 points along the curve; edit the *bgol-sp2p-samples* constant near the top of the .lsp file for a finer or coarser result.
  • Works on LWPOLYLINE entities; both open and closed smoothed polylines are supported.
  • The original smoothed polyline is not deleted, so you can compare or remove it manually once you have confirmed the conversion.
  • 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

What CAD platforms does SP2P work on?

SP2P is a standard AutoLISP routine, so it runs in AutoCAD, BricsCAD, ZWCAD, and most other AutoLISP-compatible CAD platforms without modification.

What should I know before using SP2P?

Sampling density defaults to 60 points along the curve; edit the *bgol-sp2p-samples* constant near the top of the .lsp file for a finer or coarser result.

What is the main benefit of using SP2P?

Bridges cosmetic vs. real geometry, spline-fit smoothing is visual only; this produces a polyline other LISP routines can process correctly.

Is SP2P free to use for commercial projects?

Yes. SP2P is fully open-source and free to use, modify, and redistribute for both personal and commercial work, developed and shared by the BGol Community.

How do I load the SP2P command into my drawing?

Drag and drop SPL2SEG-bgol.lsp onto your open drawing window, or load it through the APPLOAD command, then type SP2P 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.

Back to all articles