Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 03/26/2019 in all areas

  1. Good information, but there is another solution to copy/pasting the whole drawing into a new drawing if the text gets messed up after 3D orbit. The problem isn't actually with 3D orbit, it's that panning while in the 3D orbit command moves the "target" of the view, and if the "Target" isn't at the same Z position as the TrueType font then smoothing (anti-aliasing) is disabled. This is the same reason TrueType fonts with z-values other than 0 (relative to the view) display jagged. To correct the problem, use DVIEW to reset the z-value of the view to 0. Here's a macro that will reset the view, which I've assigned to a button to quickly reset any view. ^C^C_.Dview;;_Point;0,0,0;0,0,1;;
    1 point
  2. This is the one that I currently use... it is not ideal for a grid like this because you still need to manually run each segment, but it gets the job done. ; multiple interpolation function to populate text elevation labels ; base lisp from thread at http://forums.augi.com/showthread.php?69723-LOOKING-FOR-A-LISP-ROUTINE, Last edited by CAB2k; 2007-10-25 at 08:51 PM. ; modified by Nete Laana on 24.01.18 ; 22.03.18 ADDED SLOPE OUTPUT (defun c:MINTS (/ p1 p2 p3 p4 el1 el2 el3 d12 vecs tmpPt deltaE deltaE3 t1 s1 l1 mpt) (setq p1 (getpoint "\nPick First point: ")) (setq el1 (getdist "\nEnter elevation.")) (setq p2 (getpoint p1 "\nPick Second point: ")) (setq el2 (getdist "\nEnter elevation.")) (setq s1 (*(/ (- el2 el1) (distance p1 p2))100)); calc slope percentile (print (strcat "the slope is " (rtos s1)"%")); cmd slope (setq l1 (strcat (rtos s1)"% SLOPE")); string for slope (print l1); cmd string (setq mpt (polar p1 (angle p1 p2) (/ (distance p1 p2) 2.) )); find midpoint (command ".TEXT" mpt 1.2 (* (angle p1 p2) (/ 180 pi)) l1); dump slope as text object (command "Line" p1 p2 "");draw the line (and (setq deltaE (- el2 el1) d12 (distance p1 p2)) (while (setq p3 (getpoint "\nPick point for elevation: ")) (redraw) (grvecs (list 1 p1 p3 p3 p2)) (setq tmpPt (polar p3 (+ (/ pi 2) (angle p1 p2)) 10.0)) (setq p4 (inters p1 p2 p3 tmpPt nil)) (setq deltaE3 (*(/ (distance p1 p4) (distance p1 p2))deltaE)) (if (> (distance p2 p4) d12) (setq el3 (- el1 deltaE3)) (setq el3 (+ el1 deltaE3)) ) (print (strcat "Elevation at point is " (rtos el3))) (setq t1 (rtos el3 2 2)); convert to text string rounded to two digits (command "circle" p4 0.15); draw circle to identify point (and(command ".TEXT" p3 1.2 0 t1); dump el3 as text object ) ) ) (princ) ) in some newer drawings, I run into issues with the "text" command, and have modified: ; multiple interpolation function to populate text elevation labels ; base lisp from thread at http://forums.augi.com/showthread.php?69723-LOOKING-FOR-A-LISP-ROUTINE, Last edited by CAB2k; 2007-10-25 at 08:51 PM. ; modified by Nete Laana on 2018.01.24 ; 2018.03.22 netelaana added slope output ; 2018.10.24 netelaana modified text function (defun c:MINTS (/ p1 p2 p3 p4 el1 el2 el3 d12 vecs tmpPt deltaE deltaE3 t1 s1 l1 mpt) (setq p1 (getpoint "\nPick First point: ")) (setq el1 (getdist "\nEnter elevation.")) (setq p2 (getpoint p1 "\nPick Second point: ")) (setq el2 (getdist "\nEnter elevation.")) (setq s1 (*(/ (- el2 el1) (distance p1 p2))100)); calc slope percentile (print (strcat "the slope is " (rtos s1)"%")); cmd slope (setq l1 (strcat (rtos s1)"% SLOPE")); string for slope (print l1); cmd string (setq mpt (polar p1 (angle p1 p2) (/ (distance p1 p2) 2.) )); find midpoint (command ".TEXT" mpt (* (angle p1 p2) (/ 180 pi)) l1); dump slope as text object (command "Line" p1 p2 "");draw the line (and (setq deltaE (- el2 el1) d12 (distance p1 p2)) (while (setq p3 (getpoint "\nPick point for elevation: ")) (redraw) (grvecs (list 1 p1 p3 p3 p2)) (setq tmpPt (polar p3 (+ (/ pi 2) (angle p1 p2)) 10.0)) (setq p4 (inters p1 p2 p3 tmpPt nil)) (setq deltaE3 (*(/ (distance p1 p4) (distance p1 p2))deltaE)) (if (> (distance p2 p4) d12) (setq el3 (- el1 deltaE3)) (setq el3 (+ el1 deltaE3)) ) (print (strcat "Elevation at point is " (rtos el3))) (setq t1 (rtos el3 2 2)); convert to text string rounded to two digits (command "circle" p4 0.15); draw circle to identify point (and(command ".TEXT" p3 0 t1); dump el3 as text object ) ) ) (princ) ) hopefully this helps.... - NL
    -1 points
×
×
  • Create New...