+ Reply to Thread
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 11
  1. #1
    Super Moderator f700es's Avatar
    Computer Details
    f700es's Computer Details
    Operating System:
    Windows 7 Pro (W)/Windows 7 Home Premium (H)
    Computer:
    Lenovo ThinkStation D20 (W)/ Dell Inspiron 570 (H)
    Motherboard:
    Intel (W)/AMD (H)
    CPU:
    Intel Xeon E5503 (W)/AMD Athlon 2 X4 (H)
    RAM:
    4 GB DDR3 (W)/ 6GB DDR3 (H)
    Graphics:
    nVidia Quadro FX 580 (W)/nVidia GF GT430 (H)
    Primary Storage:
    500 GB HDD (W)/1 TB (H)
    Secondary Storage:
    Seagate FreeAgent Go 320gb
    Monitor:
    Samsung P2770HD 28" LCD and Samsung B2430 (W)/Dell 22" LCD (H)
    Discipline
    Facilities Mgmt
    f700es's Discipline Details
    Occupation
    Space Database Admin
    Discipline
    Facilities Mgmt
    Details
    Archibus Management
    Using
    AutoCAD 2012
    Join Date
    Sep 2002
    Location
    Winston-Salem, NC - USA
    Posts
    4,455

    Default Convert Spline to Pline

    Registered forum members do not see this ad.

    Hey guys, anybody got a lisp to convert a spline to a polyline? Need to convert one. Thanks in advance.

    F7
    Please do not PM me with CAD questions. Post your question on the forum. Our users are the best out there and you'll get the best possible answer to your question.

    - http://f700es.deviantart.com/gallery/ - - http://cad-guy.tumblr.com/ -


  2. #2
    Super Moderator fuccaro's Avatar
    Using
    AutoCAD 2006
    Join Date
    Nov 2002
    Location
    Romania, Marosvasarhely
    Posts
    3,540

    Default

    I am not shore I understand exactly your word “convert”.
    If your spline is 2D it’s easy to follow the vertexes. But you will lose an the aspect. The points used for the construction of the spline are with DXF code 11. So extract them, and draw a pline using those points. Is that what you need? The program is simple, it operate on the last entity from the DWG.
    Code:
    (defun C:spl()
      (setq pli nil)
      (setq old (getvar "osmode"))
      (setvar "osmode" 0)
      (setq li (entget (entlast)))
      (foreach at li
        (if (= 11 (car at)) (setq pli (cons (list (cadr at) (caddr at)) pli)))
        )
      (reverse pli)
      (command "pline")
      (foreach at pli (command (list (car at) (cadr at))))
      (command "")
      (setvar "osmode" old)
      )
    It's nice to be nice, but sometimes is nicer to be evil!.
    Tip: Please do not PM or email me with CAD questions - use the forums, you'll get an answer sooner.

  3. #3
    Super Moderator fuccaro's Avatar
    Using
    AutoCAD 2006
    Join Date
    Nov 2002
    Location
    Romania, Marosvasarhely
    Posts
    3,540

    Default

    I tried an other way, it works for a single spline. The precision is still limited –but only by your patience. Anyway, it’s better as using the lisp routine I sent before.
    So, lock the layer containing your spline. On a new one, with different color, draw a pline through some points of the spline. Convert the pline in spline using PEDIT. Move the grips trying to match the two curves (AutoCAD 20x). Insert additional vertexes, if need. When finished, explode “your” spline. You got now a lot of little segments. With PEDIT you may transform one of them in pline. Editing this pline, use JOIN to add all other little segments. Ready!
    It's nice to be nice, but sometimes is nicer to be evil!.
    Tip: Please do not PM or email me with CAD questions - use the forums, you'll get an answer sooner.

  4. #4
    Super Moderator f700es's Avatar
    Computer Details
    f700es's Computer Details
    Operating System:
    Windows 7 Pro (W)/Windows 7 Home Premium (H)
    Computer:
    Lenovo ThinkStation D20 (W)/ Dell Inspiron 570 (H)
    Motherboard:
    Intel (W)/AMD (H)
    CPU:
    Intel Xeon E5503 (W)/AMD Athlon 2 X4 (H)
    RAM:
    4 GB DDR3 (W)/ 6GB DDR3 (H)
    Graphics:
    nVidia Quadro FX 580 (W)/nVidia GF GT430 (H)
    Primary Storage:
    500 GB HDD (W)/1 TB (H)
    Secondary Storage:
    Seagate FreeAgent Go 320gb
    Monitor:
    Samsung P2770HD 28" LCD and Samsung B2430 (W)/Dell 22" LCD (H)
    Discipline
    Facilities Mgmt
    f700es's Discipline Details
    Occupation
    Space Database Admin
    Discipline
    Facilities Mgmt
    Details
    Archibus Management
    Using
    AutoCAD 2012
    Join Date
    Sep 2002
    Location
    Winston-Salem, NC - USA
    Posts
    4,455

    Default re: splines to polylines

    Quote Originally Posted by fuccaro
    I am not shore I understand exactly your word “convert”.
    If your spline is 2D it’s easy to follow the vertexes. But you will lose an the aspect. The points used for the construction of the spline are with DXF code 11. So extract them, and draw a pline using those points. Is that what you need? The program is simple, it operate on the last entity from the DWG.
    Code:
    (defun C:spl()
      (setq pli nil)
      (setq old (getvar "osmode"))
      (setvar "osmode" 0)
      (setq li (entget (entlast)))
      (foreach at li
        (if (= 11 (car at)) (setq pli (cons (list (cadr at) (caddr at)) pli)))
        )
      (reverse pli)
      (command "pline")
      (foreach at pli (command (list (car at) (cadr at))))
      (command "")
      (setvar "osmode" old)
      )
    Thanks for the reply sorry it took a while to respond but had to do the Thanksgiving thing. Anyways, I have an Illustrator file that I am trying to use in AutoCAD. I have conveted the file and opened it in CAD just fine. This is a part of a sign that I want to extract and make a 3D model out of. The part I am interested in is part of a neon sign and it is some script text. When opened in autocad it becomes a spline. If it is a polyline I can just extrude a circle on this path and be done but I don't think it will work on a spline. I will try your ideas. Thanks.

    F7
    Please do not PM me with CAD questions. Post your question on the forum. Our users are the best out there and you'll get the best possible answer to your question.

    - http://f700es.deviantart.com/gallery/ - - http://cad-guy.tumblr.com/ -


  5. #5
    Administrator CADTutor's Avatar
    Computer Details
    CADTutor's Computer Details
    Operating System:
    Windows 7 Home Premium 64bit
    Motherboard:
    Asus P7P55D-E PRO
    CPU:
    Intel Core i7-860
    RAM:
    4GB PC3-12800 C8 Corsair Dominator
    Graphics:
    NVIDIA Quadro FX 1800 768 MB
    Primary Storage:
    Intel X25-M SSD 160GB
    Secondary Storage:
    Samsung Spinpoint 320GB
    Monitor:
    BenQ FP241W 24" Wide
    Discipline
    Education
    CADTutor's Discipline Details
    Occupation
    Senior Lecturer (Digital Design), Landscape Architect & Web Designer
    Discipline
    Education
    Using
    AutoCAD 2014
    Join Date
    Aug 2002
    Location
    Hampshire, UK
    Posts
    3,606

    Default

    In theory, you can extrude a circle along a spline in AutoCAD. However, in practice it often refuses to work when the spline contains tight curves and the resulting sweep would cause the circle to be folded in on itself. You might find it easier to do the extrusion in VIZ or MAX and then bring it back into AutoCAD.
    Tip: Please do not PM or email me with CAD questions - use the forums, you'll get an answer sooner.
    AutoCAD Tutorials | How to add images to your posts | How to register successfully | Forum FAQ

  6. #6
    Super Moderator f700es's Avatar
    Computer Details
    f700es's Computer Details
    Operating System:
    Windows 7 Pro (W)/Windows 7 Home Premium (H)
    Computer:
    Lenovo ThinkStation D20 (W)/ Dell Inspiron 570 (H)
    Motherboard:
    Intel (W)/AMD (H)
    CPU:
    Intel Xeon E5503 (W)/AMD Athlon 2 X4 (H)
    RAM:
    4 GB DDR3 (W)/ 6GB DDR3 (H)
    Graphics:
    nVidia Quadro FX 580 (W)/nVidia GF GT430 (H)
    Primary Storage:
    500 GB HDD (W)/1 TB (H)
    Secondary Storage:
    Seagate FreeAgent Go 320gb
    Monitor:
    Samsung P2770HD 28" LCD and Samsung B2430 (W)/Dell 22" LCD (H)
    Discipline
    Facilities Mgmt
    f700es's Discipline Details
    Occupation
    Space Database Admin
    Discipline
    Facilities Mgmt
    Details
    Archibus Management
    Using
    AutoCAD 2012
    Join Date
    Sep 2002
    Location
    Winston-Salem, NC - USA
    Posts
    4,455

    Default

    Quote Originally Posted by CADTutor
    In theory, you can extrude a circle along a spline in AutoCAD. However, in practice it often refuses to work when the spline contains tight curves and the resulting sweep would cause the circle to be folded in on itself. You might find it easier to do the extrusion in VIZ or MAX and then bring it back into AutoCAD.
    ummmm???

    Good Idea!

    I'll give it a try. Thanks.

    F7
    Please do not PM me with CAD questions. Post your question on the forum. Our users are the best out there and you'll get the best possible answer to your question.

    - http://f700es.deviantart.com/gallery/ - - http://cad-guy.tumblr.com/ -


  7. #7
    Super Moderator f700es's Avatar
    Computer Details
    f700es's Computer Details
    Operating System:
    Windows 7 Pro (W)/Windows 7 Home Premium (H)
    Computer:
    Lenovo ThinkStation D20 (W)/ Dell Inspiron 570 (H)
    Motherboard:
    Intel (W)/AMD (H)
    CPU:
    Intel Xeon E5503 (W)/AMD Athlon 2 X4 (H)
    RAM:
    4 GB DDR3 (W)/ 6GB DDR3 (H)
    Graphics:
    nVidia Quadro FX 580 (W)/nVidia GF GT430 (H)
    Primary Storage:
    500 GB HDD (W)/1 TB (H)
    Secondary Storage:
    Seagate FreeAgent Go 320gb
    Monitor:
    Samsung P2770HD 28" LCD and Samsung B2430 (W)/Dell 22" LCD (H)
    Discipline
    Facilities Mgmt
    f700es's Discipline Details
    Occupation
    Space Database Admin
    Discipline
    Facilities Mgmt
    Details
    Archibus Management
    Using
    AutoCAD 2012
    Join Date
    Sep 2002
    Location
    Winston-Salem, NC - USA
    Posts
    4,455

    Default re: Spline to PL

    Hello all, thanks to all who replied but I found a .vlx routine that does the job. Here it is for all to use.
    http://www.dotsoft.com/public/spl2pl.vlx

    Here is a page of routines that might come in handy
    http://www.dotsoft.com/freestuff.htm

    Thanks again all.

    F7
    Please do not PM me with CAD questions. Post your question on the forum. Our users are the best out there and you'll get the best possible answer to your question.

    - http://f700es.deviantart.com/gallery/ - - http://cad-guy.tumblr.com/ -


  8. #8
    Administrator CADTutor's Avatar
    Computer Details
    CADTutor's Computer Details
    Operating System:
    Windows 7 Home Premium 64bit
    Motherboard:
    Asus P7P55D-E PRO
    CPU:
    Intel Core i7-860
    RAM:
    4GB PC3-12800 C8 Corsair Dominator
    Graphics:
    NVIDIA Quadro FX 1800 768 MB
    Primary Storage:
    Intel X25-M SSD 160GB
    Secondary Storage:
    Samsung Spinpoint 320GB
    Monitor:
    BenQ FP241W 24" Wide
    Discipline
    Education
    CADTutor's Discipline Details
    Occupation
    Senior Lecturer (Digital Design), Landscape Architect & Web Designer
    Discipline
    Education
    Using
    AutoCAD 2014
    Join Date
    Aug 2002
    Location
    Hampshire, UK
    Posts
    3,606

    Default

    Hey, what a great resource you found. Free LISP routines galore, free symbols and more.

    I'll post the details in the relevant forums.
    Tip: Please do not PM or email me with CAD questions - use the forums, you'll get an answer sooner.
    AutoCAD Tutorials | How to add images to your posts | How to register successfully | Forum FAQ

  9. #9
    Super Moderator f700es's Avatar
    Computer Details
    f700es's Computer Details
    Operating System:
    Windows 7 Pro (W)/Windows 7 Home Premium (H)
    Computer:
    Lenovo ThinkStation D20 (W)/ Dell Inspiron 570 (H)
    Motherboard:
    Intel (W)/AMD (H)
    CPU:
    Intel Xeon E5503 (W)/AMD Athlon 2 X4 (H)
    RAM:
    4 GB DDR3 (W)/ 6GB DDR3 (H)
    Graphics:
    nVidia Quadro FX 580 (W)/nVidia GF GT430 (H)
    Primary Storage:
    500 GB HDD (W)/1 TB (H)
    Secondary Storage:
    Seagate FreeAgent Go 320gb
    Monitor:
    Samsung P2770HD 28" LCD and Samsung B2430 (W)/Dell 22" LCD (H)
    Discipline
    Facilities Mgmt
    f700es's Discipline Details
    Occupation
    Space Database Admin
    Discipline
    Facilities Mgmt
    Details
    Archibus Management
    Using
    AutoCAD 2012
    Join Date
    Sep 2002
    Location
    Winston-Salem, NC - USA
    Posts
    4,455

    Default

    Quote Originally Posted by CADTutor
    Hey, what a great resource you found. Free LISP routines galore, free symbols and more.

    I'll post the details in the relevant forums.
    When I get back to work I'll make a list of sites with such info. Where shall I post it?

    F7
    Please do not PM me with CAD questions. Post your question on the forum. Our users are the best out there and you'll get the best possible answer to your question.

    - http://f700es.deviantart.com/gallery/ - - http://cad-guy.tumblr.com/ -


  10. #10
    Administrator CADTutor's Avatar
    Computer Details
    CADTutor's Computer Details
    Operating System:
    Windows 7 Home Premium 64bit
    Motherboard:
    Asus P7P55D-E PRO
    CPU:
    Intel Core i7-860
    RAM:
    4GB PC3-12800 C8 Corsair Dominator
    Graphics:
    NVIDIA Quadro FX 1800 768 MB
    Primary Storage:
    Intel X25-M SSD 160GB
    Secondary Storage:
    Samsung Spinpoint 320GB
    Monitor:
    BenQ FP241W 24" Wide
    Discipline
    Education
    CADTutor's Discipline Details
    Occupation
    Senior Lecturer (Digital Design), Landscape Architect & Web Designer
    Discipline
    Education
    Using
    AutoCAD 2014
    Join Date
    Aug 2002
    Location
    Hampshire, UK
    Posts
    3,606

    Default

    Registered forum members do not see this ad.

    Post it either in the LISP or Images & Models forum, whichever seems appropriate. I'll put together a new CADTutor resource page listing all the best free stuff.

    Thanks.
    Tip: Please do not PM or email me with CAD questions - use the forums, you'll get an answer sooner.
    AutoCAD Tutorials | How to add images to your posts | How to register successfully | Forum FAQ

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts