It is currently Mon Jun 25, 2018 7:46 am

 

Draftsite - Convert splines to polylines?

General software related questions should be posted here.
djreiswig
Posts: 278
Joined: Thu Nov 19, 2015 10:02 pm

Draftsite - Convert splines to polylines?

Postby djreiswig » Mon Jan 01, 2018 10:51 pm

Some of the files on here consist of splines. For example:
viewtopic.php?f=6&t=24713

When I try to work with these files in DraftSight, they are uncooperative. If I try and scale them or basically modify them in any way, the lines get all choppy and the design in unusable.

I've tried bringing them into Inkscape and resaving, but it didn't help.

How can I get rid of these annoying splines?
2014 Bulltear (StarLab) 4x8
C&CNC EtherCut
Mach3, SheetCam, Draftsight
Hypertherm PM65
Oxy/Acetylene Flame Torch
Pneumatic Plate Marker, Ohmic, 10 inch Rotary Chuck (in progress)

hemichargersrt8
Elite Contributing Member
Elite Contributing Member
Posts: 213
Joined: Sun Dec 09, 2012 6:31 am

Re: How do I convert splines to polylines?

Postby hemichargersrt8 » Tue Jan 02, 2018 6:16 am

To create a 2D polyline approximation of the original spline:
Save the drawing in R12 DXF format.
Reopen the DXF file. ...
Use the EXPLODE command on the 3D polyline, which will turn it into line objects.
Use the PEDIT command, and select one of the lines.
At the prompt to convert this to a polyline, select Yes.

djreiswig
Posts: 278
Joined: Thu Nov 19, 2015 10:02 pm

Re: How do I convert splines to polylines?

Postby djreiswig » Tue Jan 02, 2018 8:59 pm

Okay, I got the first 3 steps and got rid of the splines. A little unclear on the PEDIT. Not in the help file for DraftSight.
Select one of the lines?? One segment, one outline?
If I click one line segment and then say Yes I get a prompt to Specify option
Close, Decurve, Edit vertex, Fit, Join, Linegen, Spline, Undo, Width, eXit.

Tried several of the options and nothing seems to happen. The drawing now has lots of nodes.
(With PEDIT it appears to only allow selecting a single entity)
I assume I'm supposed to end up with less nodes when I get done.
What am I missing?

I'm using DS V1R5.1 if that matters.
2014 Bulltear (StarLab) 4x8
C&CNC EtherCut
Mach3, SheetCam, Draftsight
Hypertherm PM65
Oxy/Acetylene Flame Torch
Pneumatic Plate Marker, Ohmic, 10 inch Rotary Chuck (in progress)

scn64
Posts: 7
Joined: Sun Nov 12, 2017 8:06 pm

Re: How do I convert splines to polylines?

Postby scn64 » Wed Jan 03, 2018 8:30 am

I use this function all the time to clean up items and validate closed geometry. (see the attached screen shot of a typical list of commands)

When you perform the poly line edit you should first get the option to select multiple
Capture.JPG

Type the letter M and then select the geometry you wish to turn in to a poly line (or window the entire drawing)

Once you have selected the desired geometry you must Join it to make a continuous poly line. (you can change the gap values but I use 0 to ensure that I do not have open or intersecting nodes

You do not have access to download this dxf file.
Become a Contributing Member to gain access to the thousands of files shared by our members. Click Here


djreiswig
Posts: 278
Joined: Thu Nov 19, 2015 10:02 pm

Re: How do I convert splines to polylines?

Postby djreiswig » Wed Jan 03, 2018 10:13 am

Thanks for the clarification. Can I select the whole drawing even if the lines aren't connected?
2014 Bulltear (StarLab) 4x8
C&CNC EtherCut
Mach3, SheetCam, Draftsight
Hypertherm PM65
Oxy/Acetylene Flame Torch
Pneumatic Plate Marker, Ohmic, 10 inch Rotary Chuck (in progress)

scn64
Posts: 7
Joined: Sun Nov 12, 2017 8:06 pm

Re: How do I convert splines to polylines?

Postby scn64 » Wed Jan 03, 2018 3:17 pm

You can select the entire drawing but the poly line will only join along common nodes. Thus if your geometry is not closed or has intersections you will create multiple poly line segments. When this occurs I usually will change the color of the "segments to get a clear picture of where the problems are and then zoom in on the broken areas to make repairs. (trim, extend, add fillets, drag nodes, etc.) to the geometry
FYI - converted text can be a real B***

Once you feel the geometry has been properly closed, repeat the poly line edit using the multiple joining process but do not window the whole drawing. Pick each segmented poly line and try joining again.

Also, when you explode your splines try playing with the precision value to reduce the number of nodes to an acceptable level. (the bigger the number the fewer nodes)
spline explode Capture.JPG


It takes a little practice but I'm sure you can develop a few techniques to get the desired results. When all else fails I use the create poly line functions on a separate layer and trace the existing geometry to clean up my file and produce acceptable results for the laser or plasma machines I program

You do not have access to download this dxf file.
Become a Contributing Member to gain access to the thousands of files shared by our members. Click Here


djreiswig
Posts: 278
Joined: Thu Nov 19, 2015 10:02 pm

Re: How do I convert splines to polylines?

Postby djreiswig » Wed Jan 03, 2018 9:42 pm

Took a while to join, but following your excellent instructions seemed to be the trick. Thanks.
2014 Bulltear (StarLab) 4x8
C&CNC EtherCut
Mach3, SheetCam, Draftsight
Hypertherm PM65
Oxy/Acetylene Flame Torch
Pneumatic Plate Marker, Ohmic, 10 inch Rotary Chuck (in progress)

djreiswig
Posts: 278
Joined: Thu Nov 19, 2015 10:02 pm

Re: How do I convert splines to polylines?

Postby djreiswig » Wed Jan 03, 2018 10:00 pm

Thanks hemichargersrt8 for your help as well. You guys are great.
2014 Bulltear (StarLab) 4x8
C&CNC EtherCut
Mach3, SheetCam, Draftsight
Hypertherm PM65
Oxy/Acetylene Flame Torch
Pneumatic Plate Marker, Ohmic, 10 inch Rotary Chuck (in progress)

scn64
Posts: 7
Joined: Sun Nov 12, 2017 8:06 pm

Re: How do I convert splines to polylines?

Postby scn64 » Thu Jan 04, 2018 8:16 am

Glad it worked out for you!! :)

Splines and ellipses are not fun to deal with for most machines but if you take the time to work around them you can come up with some good results and add to your skills set to be more productive.

Have a good one!!

SegoMan DeSigns
Posts: 62
Joined: Sat Jan 06, 2018 4:45 pm

Re: How do I convert splines to polylines?

Postby SegoMan DeSigns » Mon Jan 08, 2018 12:40 am

For you non DraftSight users this works pretty good too:

http://www.cadkas.com/dxf-splines-to-arcs.php


Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 2 guests

Easyscriber engrave attachment for Hypertherm torch's