Jump to content
You must now use your email address to sign in [click for more info] ×

How to join all curves in a DXF import?


Recommended Posts

Fantastic to finally have DXF import, but that means that all curves are split or separated. So, how do you join thousands of curve segments automatically in Affinity, where the start point on one curve is exactly on the end point of another?

Geometry - merge curves does not work, because all curves become a single object, rather than one object per continuous curve. Also, that option doesn't seem to merge anything at all, because when you do separate afterwards, they split into the exact same segments rather than continuous curves...

Next question is, can you simplify (reduce points) on these curves without loosing too much detail?

Link to comment
Share on other sites

  • Staff

Hi @eobet,

12 hours ago, eobet said:

Fantastic to finally have DXF import, but that means that all curves are split or separated. So, how do you join thousands of curve segments automatically in Affinity, where the start point on one curve is exactly on the end point of another?

Geometry - merge curves does not work, because all curves become a single object, rather than one object per continuous curve. Also, that option doesn't seem to merge anything at all, because when you do separate afterwards, they split into the exact same segments rather than continuous curves...

Are you able to provide a sample DXF/.afdesign file so I can provide specific advice here?

Can I also ask what you are hoping to achieve when separating the curves after editing? As I can confirm that I believe it's expected behaviour for multiple Curve objects to be merged into a singular Curveobject - then when using Separate Curves, the original Curve objects will be retained, where possible.

12 hours ago, eobet said:

Next question is, can you simplify (reduce points) on these curves without loosing too much detail?

Unfortunately there's not automatic 'simplify' feature in Affinity currently - though you can delete existing nodes using ALT + Backspace and the Affinity app will attempt to retain the curves shape whilst removing this node. :)

Please note -

I am currently out of the office for a short while whilst recovering from surgery (nothing serious!), therefore will not be available on the Forums during this time.

Should you require a response from the team in a thread I have previously replied in - please Create a New Thread and our team will be sure to reply as soon as possible.

Many thanks!

Link to comment
Share on other sites

  • Staff

Hi @eobet,
Regarding your first question, I believe there's no easy way to do this automatically. The Join Curves command (Node Tool) does connect lines that "enclose" a shape assuming the end nodes of them do overlap (alternatively the Shape Builder Tool can also generate shapes from lines), but applying it to several objects at once each with multiple lines may lead to unpredictable results, connecting lines from different objects or complicating the process if there's shapes containing other shapes visually - you will have a bit more work (Shape Builder Tool). Merge Curves just adds all lines ("groups") to a single object, does not connect them.

The point is why do you need the lines connected? If it's for filling them you can use the Vector Flood Fill Tool without the need to close the shapes (it generates them from you), if it's for 3D geometry purposes (to import in 3D apps for later editing) then all I'm aware of is the processes described above.

Link to comment
Share on other sites

  • 2 weeks later...

That flood fill doesn't give very good results out of the box either.

image.thumb.png.b183ad5d65300127aaa805c7032f4547.png

 

A mass join of line ends by end point proximity would be a very welcome feature here. It's pretty common in both the CAD world (where this file originates from), and the mesh world...

(I actually prefer to use Rhino for accurate linework like font and logo creation... it has much more streamlined precise tools for snapping, copying, movement, mirroring, patterns, tangency matching, smooth blending etc etc...)

Link to comment
Share on other sites

7 hours ago, eobet said:

That flood fill doesn't give very good results out of the box either.

‘Fill to Visible Boundaries’ is disabled in the default (‘out of the box’) settings for the Vector Flood Fill tool, which does seem a curious choice. If you enable it you’ll get the result that you and I would expect.

Alfred spacer.png
Affinity Designer/Photo/Publisher 2 for Windows • Windows 10 Home/Pro
Affinity Designer/Photo/Publisher 2 for iPad • iPadOS 17.4.1 (iPad 7th gen)

Link to comment
Share on other sites

I tried most options and combination of options. Nothing seems to be intuitive or work well.

And again, flood fill only works in the case of enclosed separated curves. If you have open shapes imported via DXF, you're still screwed.

Link to comment
Share on other sites

2 hours ago, eobet said:

And again, flood fill only works in the case of enclosed separated curves. If you have open shapes imported via DXF, you're still screwed.

Select all, choose the Node Tool and click on ‘Close Curve’ (on the Context toolbar) to close them all in one fell swoop.

Alfred spacer.png
Affinity Designer/Photo/Publisher 2 for Windows • Windows 10 Home/Pro
Affinity Designer/Photo/Publisher 2 for iPad • iPadOS 17.4.1 (iPad 7th gen)

Link to comment
Share on other sites

11 hours ago, Alfred said:

Select all, choose the Node Tool and click on ‘Close Curve’ (on the Context toolbar) to close them all in one fell swoop.

Nope.

Screenshot2024-03-17230947.jpg.70ddda9367a5ea27e287bd702d053375.jpg

 

However, I noticed that flood fill does work as expected after you selected something.

Still, tedious work.

A join all which actually joined all continuous would be welcome (again, especially for open curves)!

(EDIT: Though I guess doing booleans is about as many clicks as flood fill... but the case for open curve still stands.)

Link to comment
Share on other sites

18 minutes ago, eobet said:

Nope.

Your screenshot shows that you succeeded in closing the curves at the top of the A and the right-hand side of the the B. Did you perhaps mean joining those curved segments to the adjacent straight segments? :/

22 minutes ago, eobet said:

Still, tedious work.

A join all which actually joined all continuous would be welcome (again, especially for open curves)!

Agreed. And ditto!

Alfred spacer.png
Affinity Designer/Photo/Publisher 2 for Windows • Windows 10 Home/Pro
Affinity Designer/Photo/Publisher 2 for iPad • iPadOS 17.4.1 (iPad 7th gen)

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.