Any help would be greatly appreciated!! (and soon would be great, but
beggers can't be choosers)
Thanks
Bob
Bob Mills <rmi...@kern.com> wrote in article
<35357bb8...@news.kern.com>...
>I need a routine that will "flatten" my (ver 12) dwgs to have 0 (zero) as the
>z coordinate. I have found a couple of routines on the net, but they would
>not work on my version 12 drawing. My line labeling routine uses the actual
>(3D) length of a line (NOT horizontal dist.) and this is NOT what I need it
>to do.
better change your labeling routine to calc the 2d distance if you got
the sources. flattening is destroying useful information just for a
dimensioning problem.
e.g.: instead of
(distance pt1 pt2)
you may use:
(distance (xy-of pt1) (xy-of pt2))
(defun xy-of (pt) (list (car pt) (cadr pt)))
Flattening
from http://xarch.tu-graz.ac.at/autocad/news/faq/autocad-faq-part2.txt
"Subject: [2.10] How to set objects to Zero Elevation? FLATTEN.LSP"
AutoDESK provides a PROJECT.LSP with two commands (PROJECT1,
PROJECT2) to project entities to a plane. This may be used to project
entities to z=0.0 and will be better than other lisps like
FLATTEN which only set the z-coordinate of all entities to zero.
Pro's: Handles Blocks and Polylines in turned UCS.
Contra's: Does not handle TEXT, 3DSOLID's and entities with a width.
For 3DSOLID's you'll need SOLPROF or create meshes from solids
(3DSOUT-3DSIN) (see [2.7.5]), otherwise check out the very simple
FLATTEN.LSP e.g.
at http://www.cadalog.com/cadalog/files/lispd-l/Flatten.zip
; FLATTEN sets the Z-coordinates of LINEs, POLYLINEs, CIRCLEs, ARCs,
; TEXT, Block INSERTs, POINTs, and SOLIDs to 0.
-- Reini Urban
AutoCAD stuff at http://xarch.tu-graz.ac.at/autocad/