Jump to content

Drawing a line at an angle with another line as the x axis?


neuri

Recommended Posts

Hi,

 

I have to draw a rather weird drawing with a lot of angled lines. Currently I'm using UCS to draw them but it's really tiresome.

 

I would draw 1 line, then type in UCS, select the X and Y axis, draw that line, escape, then hit in UCS again, rinse and repeat.

 

Is there a simpler way? I tried polar tracking "relative to last segment" but it still uses the x axis as the base, which is not what I want. I want the line to be the X axis.

Link to comment
Share on other sites

Hi,

 

I have to draw a rather weird drawing with a lot of angled lines. Currently I'm using UCS to draw them but it's really tiresome.

 

I would draw 1 line, then type in UCS, select the X and Y axis, draw that line, escape, then hit in UCS again, rinse and repeat.

 

Is there a simpler way? I tried polar tracking "relative to last segment" but it still uses the x axis as the base, which is not what I want. I want the line to be the X axis.

 

Since you are using 2010 you have the benefit of Geometric and Dimensional Constraints. This allows changing of angles without having to re-draw line segments... It can be quit handy.

 

constr.jpg

 

KC

Link to comment
Share on other sites

err.. yea i think so. Pick the end of the previous line, change the angle relative to the line, and distance it.

 

This is a lisp thing? I'm not familiar with lisp

Link to comment
Share on other sites

This is a lisp thing? I'm not familiar with lisp ??? you have made 54 posts you must have been told to use lisp for some things Autocads programing language.

 

Any way heres a start

(setq tp1 (entsel "\nSelect line near end : "))
(setq tpp1 (entget (car tp1)))
(setq pt1 (cdr (assoc 10 tpp1)))      ; start pt
(setq pt2 (cdr (assoc 11 tpp1)))      ; end pt
(setq pt3 (cadr tp1))
(setq d1 (distance pt1 pt3))
(setq d2 (distance pt2 pt3))
 (if (> d1 d2)
 (progn 
  (setq temp pt1)
  (setq pt1 pt2)
  (setq pt2 temp)
 )
 )   ; swap pt1 pt2 so correct end picked
 (setq ang (angle pt1 pt2))  ; ang is angle of ex line
(setq angdiff (getreal "\ntype in distance . "))
(setq newang (+ ang angdiff))

 

your turn now look up the polar command to work out new pt3 and then just line pt1 pt3

Link to comment
Share on other sites

You can draw line with using the geometric constraint. Draw your first line that you want to use for the relative angle measurement. From the second point you can draw a line with a specified length and then put the geometrical constraint on the both line as the first one to be selected firstly so that your second lines get rotated and gets oriented to the desired angle.

 

-CNatka

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...