DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

dxf export problem with closed curve

Started by davidorth, March 22, 2010, 05:26:19 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

davidorth

Hi, folks, I'm new here but have been using DC since it was a black screen with green lines.

I've got a free form closed curve shape that looks like an amoeba and I need to export to a dxf file that a CNC glass cutter can use. When making the original object in DC, I snapped my last point to the first point and got a fair curve all around (this will become relevant in a sec).

I was a little nervous about whether the shape would hold when I exported it and so I tried an experiment and imported the dxf I had just exported back into the drawing for comparison.  Sure enough it was a little off near the start-end point. Just for fun, I exported it again and brought it back in as a second generation export/import and that first point was now a sharp corner.

It seems like the native DC curve object does the job of hiding/blending the start/end point and making it all fair, but the dxf treats those points differently.  Is there a way to fix the start/end point in the original DC object so that it doesn't do this? Or a way to close the line when I'm first creating it so that start/end point does not have this behavior?  Is this clear?  I'm using DC16.1

David Orth

 

Rob S

#1
First off, I think you may be the only user on earth who has stuck with 16.1 - current opinion is it was the worst version ever, with v18 a close second   ;)

Anyway, for CNC purposes, I would try to draw a parallel to your curve, offset by a minuscule distance, which effectively converts it to a multi-segment line.  

The number of points you end up with may depend on your current zoom factor, so try it at different zooms til you get one that looks smooth enough. When happy - save as new file, and delete the original curve.  DCAD curves just do not dxf very well.

Your cutting path will be a number of straight segments, but if you have enough of them, it should be not discernible.
User since forever

davidorth

Rob, thanks, that just might work.  The new object it generated has many points, but it's not faceted, it's still a curve.  I've put it through several export/import dxf generations and it still looks fine.  Are you surprised that it's still a curve?  If it was segmented, then I'd have to add more points since its a pretty large glass table top and at my scale facets would show.  So I'm going to send it to them like this and tell them to make sure it still looks smooth.

If there's a start end point I sure can't detect it - even after the export/imports.  Do you think it's just a matter of increasing the points from 13 to 145? Or is it a different kind of entity?  Either way, I think this will work.

I'll look forward to updating my DesignCAD. 

David Orth
www.OrthFurniture.com

Bob P

Another alternative that I've used is to overlay real 3-poiint arcs over short segments of the curve.  With a little care, you can get a very good match.

Adrian 2.0

I do a lot of CNC work from curves, arcs & lines & I do fiddle about a bit to get the density of vector lines OK to create a smooth cut.
I use 'vector convert', 'curve to line', 'line to curve' & 'smooth line by...' in various combinations 'till I'm happy.
(all to be found in Edit/selection edit/convert)

Vector convert on a curve usually produces way too many points (which can really slow down some CNC work), so then I use 'smooth line by point reduction' (play with the number of points to remove 'till it looks good) but remember this command also converts the line back to a curve, so then I use 'curve to line' which will change it back to combined vector lines.

I find with flattish arcs that the vector convert command produces too few points, & often trace over the arc with a curve & convert that as above.

Lar

Quote from: adriank on March 23, 2010, 05:15:36 AM
... but remember this command also converts the line back to a curve, so then I use 'curve to line' which will change it back to combined vector lines.
...

If you uncheck 'Convert to curve for line smoothing' near the bottom of the 'Smooth Line by Point Reduction' dialog box the vector conversion will not be turned back into a curve.

Lar

Adrian 2.0

Wow, Lar - I had never noticed that check box.
This program never stops surprising me, thanks.

davidorth

#7
Thanks for these suggestions, but should I turn these beautiful free form curves into arcs and vectors, if I can get the curves to work well with the exporting?  Have I wrongly assumed that CNC and CadCam machines would support splines and curves - not just arcs and vectors?  I WANT to keep the curves, so I'm not too thrilled about turning them into vectors or arcs.  But are you all saying that these CNC and CadCam machines don't handle anything but vectors and arcs?

Rob's reply #1 seems to work somehow, without converting it to vectors or arcs.  I get what looks like spline through a lot more points and it seems to get rid of the start/end point behavior I didn't like.

I really appreciate your comments on a transition I don't quite understand.  Please comment on the CNC question about splines vs vectors & arcs.

Thanks,
David Orth
www.OrthFurniture.com

Bob P

#8
Whether a spline curve works probably depends on the CAD/CAM system.  My recollection is that I had problems with the Trumpf laser conversion.  Even converting to short vectors overloaded the line count.  Things might be different now, since I haven't tried it in 5+ years.

Adrian 2.0

My files are sent to cutting machines - lasers, waterjet, plasma etc. I'm not the operator so I'm not exactly sure but..
15 years ago my files were converted to a dedicated CNC program (don't know the name of it) & it could only follow straight lines. The laser also used to hesitate at each point it reached, leaving marks.
When the laser's computer died, our inhouse technician re-programmed it with new software & I think it now cuts directly off DesignCad files - I'll check tomorrow (night-time here now)
I know that numbers of points don't bother the machine anymore & it makes smooth cuts, it also follows radii now but as far as I know it can't follow curves.
We have no trouble getting smooth flowing curves with an appropriate number of points on the line.

davidorth

Thanks, Rob, Lar, Adriank, and Bob,

It sounds like I should be in touch with the software engineer on the other end, to make sure we are in sync - and that it could go either way.  I appreciate the help.  It's making sense now.

David

Dr PR

David,

Often there is a fairly simple solution to this problem. The break in the exported curve occurs at the start/end point of your curved line. If possible, move the start/end to a portion of straight line (if any exists) or to a place on the curve of greatest radius.

So, how do you do that? Create a new curve by tracing over the original. In many cases this is much faster and easier than trying to force the existing curve into a new shape.

I frequently just switch to another layer and draw a new curve using the original as a template. You can work in "Point Select" mode (CTRL 1) and select the existing curve before you start. This will show all the points on the existing curve. Then draw the new curve by snapping to existing points, but starting at a new place on the curve. You can also snap (K) to the existing curve to set points on the new curve that do not exist on the old curve.

When "tracing" the new curve over the old curve you should set more points closer together on sharply curved sections, and fewer points spaced widely on straighter sections. Also, always set a point at the point of inflection between sections where the curve changes from one direction to another.

Where the two end points come together set many points close together on either side of the junction to force the new curve to follow the curvature of the old curve exactly. Finish by snaping the last point to the first point of the new curve. If necessary, force the new curve to follow the old curve more precisely by selecting the new curve, add new points and snap (K) them to the existing curve.

Another trick for "reorganizing" points in a curve is to use the "Draw/Tickmark" function to place a specific number of "tic" lines around the existing curve (use a separate layer for the ticmarks) and then redrawing the curve by snapping to the ticmarks. Then erase the ticmarks and the original curve. This can result in a slightly different curve if you don't set enough points.

You can always delete points in Point Select mode if you want to reduce the number of points in a relatively straight section of a curve.
DesignCAD user since 1987