MikeP Posted October 26, 2010 Share Posted October 26, 2010 Since you cant explode a circle. I need to be able to convert a circle to a poly line. Quote Link to comment Share on other sites More sharing options...
ReMark Posted October 26, 2010 Share Posted October 26, 2010 As previously suggested by profcad: Use the BOUNDARY command and pick a point inside the circle. AutoCAD will create a polyline on top of the circle. This polyline can now be assigned a width. Quote Link to comment Share on other sites More sharing options...
jcap91163 Posted October 26, 2010 Share Posted October 26, 2010 Use this application, load it from the appload dialog box and you'll have the option to convert circles to polylines. circle2pl.zip Quote Link to comment Share on other sites More sharing options...
MikeP Posted October 26, 2010 Author Share Posted October 26, 2010 thats what i have been doing, but i then have to delete the circle. and honesty im just lazy lol Quote Link to comment Share on other sites More sharing options...
pBe Posted October 26, 2010 Share Posted October 26, 2010 As previously suggested by profcad: Use the BOUNDARY command and pick a point inside the circle. AutoCAD will create a polyline on top of the circle. This polyline can now be assigned a width. simple like that ... Quote Link to comment Share on other sites More sharing options...
Tharwat Posted October 26, 2010 Share Posted October 26, 2010 Here is mine hope you like it ............ (defun c:C2PL (/ o e) ; Tharwat Tue 26.10.2010 (if (and (setq o (car (entsel "\n Select Circle :"))) (eq (cdr (assoc 0 (setq e (entget o)))) "CIRCLE") ) (progn (vl-cmdf "_.donut" (* (cdr (assoc 40 e)) 2) (* (cdr (assoc 40 e)) 2) (cdr (assoc 10 e)) "") (vl-cmdf "_.erase" o "") ) (princ) ) (princ) ) Tharwat Quote Link to comment Share on other sites More sharing options...
ReMark Posted October 26, 2010 Share Posted October 26, 2010 I just need a lisp for the donut's hole. Anybody have one? Quote Link to comment Share on other sites More sharing options...
David Bethel Posted October 26, 2010 Share Posted October 26, 2010 Dunkiitthhpp Dounuttthhppp with a liissttthhppp Quote Link to comment Share on other sites More sharing options...
ReMark Posted October 26, 2010 Share Posted October 26, 2010 I meant one for the "void". I need to create the "nothing". Quote Link to comment Share on other sites More sharing options...
MikeP Posted October 26, 2010 Author Share Posted October 26, 2010 for what im using this for, it kinda sounds stupid but it will actually help me. Quote Link to comment Share on other sites More sharing options...
MikeP Posted October 26, 2010 Author Share Posted October 26, 2010 perfect except can i have it be able to select multiple circles rather than one at time? Quote Link to comment Share on other sites More sharing options...
alanjt Posted October 26, 2010 Share Posted October 26, 2010 I meant one for the "void". I need to create the "nothing".but The Nothing will kill Fantasia and all that inhabit it. Quote Link to comment Share on other sites More sharing options...
alanjt Posted October 26, 2010 Share Posted October 26, 2010 (defun c:C2P (/ ss) ;; Circles to LWPolylines ;; Alan J. Thompson, 10.26.10 (if (setq ss (ssget "_:L" '((0 . "CIRCLE")))) ((lambda (i / e d l) (while (setq e (ssname ss (setq i (1+ i)))) (setq l nil) (foreach x (setq d (entget e)) (and (member (car x) '(6 8 39 48 62)) (setq l (cons x l)))) (entmakex (append (list (cons 0 "LWPOLYLINE") (cons 100 "AcDbEntity") (cons 100 "AcDbPolyline") (cons 90 2) (cons 70 1) ) l (list (cons 10 (polar (cdr (assoc 10 d)) 0. (cdr (assoc 40 d)))) '(42 . 1) (cons 10 (polar (cdr (assoc 10 d)) pi (cdr (assoc 40 d)))) '(42 . 1) ) ) ) (entdel e) ) ) -1 ) ) (princ) ) Quote Link to comment Share on other sites More sharing options...
The Buzzard Posted October 26, 2010 Share Posted October 26, 2010 Since you cant explode a circle. I need to be able to convert a circle to a poly line. MikeP Try this lisp, It draws the circle as a closed polyline made by two arcs. (defun C:CIR (/ CDIA CPNT PT01 PT02) (or CIR:CDIA (setq CIR:CDIA 1.0)) (initget (+ 2 4)) (setq CIR:CDIA (cond ((getreal (strcat "\nSpecify circle diameter. <"(rtos CIR:CDIA 2 4)">: "))) (T CIR:CDIA))) (setq CDIA CIR:CDIA) (while (if (/= (setq CPNT (getpoint "\nSpecify center point: ")) nil) (progn (setq PT01 (polar CPNT (CIR_DTR 0.0)(/ CDIA 2.0))) (setq PT02 (polar PT01 (CIR_DTR 180.0) CDIA)) (CIR_DLWP (list PT01 PT02 PT01)(list -1.0 -1.0 -1.0) 0)))) (princ)) (defun CIR_DLWP (VRT BF FLG) (entmakex (append (list (cons 0 "LWPOLYLINE") (cons 100 "AcDbEntity") (cons 100 "AcDbPolyline") (cons 90 (length VRT)) (cons 70 FLG)) (apply (function append) (mapcar (function (lambda (PNT BF) (list (cons 10 PNT) (cons 42 BF)))) VRT BF)))) (princ)) (defun CIR_DTR (a)(* pi (/ a 180.0))) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.