DXF Splines => AutoCad => DXF

Next
 From:  archetype (FABIENF)
8606.1 
I'm having a weird issue that pops up during the following workflow:

1. 2D pattern with splines in MoI is saved as DXF, using the 'Write curves as: Splines' option
2. The DXF is imported into AutoCad LT Mac, and all seems well, the splines were correctly imported
3. The pattern is annotated with text, any of the imported curves remain unchanged
4. The completed drawing (now in DWG format) is finally saved into DXF R12 for the cutting machine

I am aware of the fact that R12 has no support for actual splines, so all splines will be converted into Polylines during export. In AutoCad there's apparently no option to specify the degree of tesselation during export, but here's what's puzzling me:

Any splines drawn in AutoCad directly are finely tesselated to the point where the curve is smoothly preserved in a way that it's suitable for cutting. However, most imported splines are severely facetted, to the point where a semi-circular arc is made up from 4 polygonal segments. Oddly enough, it's not happening to all of the imported splines as severely (within the same file), there's clearly a per-object difference in how they are converted into polylines. It seems to be more prevalent with any curves offset in MoI before, but the various results are not conclusive: some are output as expected, while others are hardly recognizable.

In order to find out more, I used QCad to check the output, as well as perform the same conversion from AutoCad's DWG (splines) to DXF R12 (polylines). The results are more or less the same as AutoCad: a semi-circle simply became a triangular angle. While there are various workarounds for this issue (in AutoCAD: convert to Polylines with a certain precision - in QCad: Explode, which converts curves into moderately sized arc primitives, and contrary to what you expect, keeps all lines joined).

It appears that a spline has some kind of 'hidden' parameter to control how it's being tesselated on export, yet I cannot find any UI control or command to adjust its fidelity.

Does anyone have an idea why MoI's DXF splines are being treated differently when saving back into DXF from AutoCad?







EDITED: 29 Sep by FABIENF


  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
8606.2 In reply to 8606.1 
Hi Fabien, maybe the AutoCAD LT spline to polyline conversion mechanism is sensitive to things like the parameterization of the spline.

It looks like there is a command in AutoCAD for converting a spline to a polyline, see here:
https://knowledge.autodesk.com/support/autocad/learn-explore/caas/sfdcarticles/sfdcarticles/How-to-convert-splines-to-polylines-in-AutoCAD.html

If that's available in LT could you try using it on your original imported spline and see if you can repeat the odd behavior? If so that would probably pinpoint the problem being AutoCAD's conversion mechanism.

A couple of possible solutions:

Try using Edit > Separate on your curves in MoI before exporting them to AutoCAD. That way AutoCAD will treat each one as an individual object and that might avoid the problem if it's the AutoCAD uses some kind of parameter space tolerance for the conversion which could make it think the arc is small if it has a small parameter space compared to the other segments.

The other thing is you could export from MoI using polylines at that point rather than relying on AutoCAD to do the polyline conversion.

Please let me know if those don't help.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  archetype (FABIENF)
8606.3 
Hi Michael,

Thanks for your prompt reply! I tried AutoCAD's 'convert to polyline' before, and it does work as expected - although even straight lines will get some subdivision.

However, I'm happy to report that your hunch regarding 'parameter space tolerance' was spot on! When I imported the separated curves from MoI it even brought in arcs correctly (not as splines), which already made a huge difference for these files. In addition, any free-form splines were now correctly handled as well.

I was able to join the (now) separate segments in AutoCAD and still export them to DXF R12 polyline format without any issues. The exported curves were either pure arcs/circles or finely segmented polylines.

One thing I noticed in AutoCAD is that I wasn't able to 'join' back all the lines without issues. Some parts refused to connect, whereas the same operation was performed without a hitch in QCad.

AutoCAD might be the standard in CAD, but it's those glitches (in addition the odd behavior I was seeing with the imported files) that will prevent me from ever becoming an actual user, I'm afraid. I'm currently using the trial to mimic the behavior my cutting provider was seeing, but looks like our ways will part forever in about 30 days from now ;)

Another solution that worked for me is using Rhino's DXF export using the 'CAM Metric' scheme. It automatically handled arcs/circles, while having control over parametrization of the free-form splines. I prefer this over having MoI handling the conversion, because I can take a completely annotated DWG into Rhino and then export it to DXF at once. That way, the splines and arcs are preserved as long as possible, so any edits can still be done and at the same time, the file size is kept low.

Thanks again for your help!

- Fabien

EDITED: 30 Sep by FABIENF

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Frenchy Pilou (PILOU)
8606.4 In reply to 8606.3 
You can try Fusion 360 as converter format files! ;)
---
Pilou
Is beautiful that please without concept!
My Gallery
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  AlexPolo
8606.5 
Hi all,

I send files to a laser cutter that can cant use splines I use the RHINO convert to ARCS you can specify the resolution much better than converting to polylines so you dont get stepping - not sure is this command exists in AUTOCAD offerings.

A Spline to ARC converter in MOI would be a fantastic addon.




Attachments:

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All