Reducing broken lines in DWG export

I am having a hard time finding an answer to this question despite googling and looking at the forum. Are there any addons or options that would fuse lines together when exporting to CAD?

For example in this image the one horizontal line is in 6 segments. This makes it hard to work with in CAD and if complex enough makes it so we have to redo work that was done in SKU. I know curves would not easily be fixed but I feel like this should be something that is doable with an addon or setting.

AutoCad has the Overkill command to deal with this kind of things.

1 Like

Have you tried the Weld command available since SU 2020. There is an extension available for older versions.

Weld will keep the line segments. Result is a polyline in AutoCad.

1 Like

Are those edges broken in the SketchUp model?

Yes they are.

How did they get broken in the SketchUp model? I see this all the time with CAD files imported into SketchUp. They are a PIA. I would consider not leaving broken edges like that in SU.

They are broken because that is where lines meet.

I was wondering, that there is a Ruby trick… But apparently does not work as I thought. Because it will still break the edges where they meet with the end, and will not break only if they are crossing.

Nevertheless, I will share, jut for fun :slight_smile: :

The break_edges= method can be used to disable or enable the break edges feature. Break edges is the SketchUp 7 feature that automatically splits edges that the user draws which cross over one another.
This feature is always on by default and cannot be disabled by the user via the user interface, but you can call this method to disable it. Be cautious in doing so, however, as the resulting model could then be altered when the user later draws lines into it with the break edges feature reactivated.

So, if you copy-paste this to Ruby Console

Sketchup.break_edges = false

You can get this:


.

Dont forget to set it back after:

Sketchup.break_edges = true
1 Like

We have an older CAD and I was worried this did not work on it but it does and it is a great solution. It would be nice if it was an option in SKU export but it is a great work around. :slight_smile:

E: I am messing with this more and more and this is exciting. It takes into account layers too. This could make my life much easier. Thank you so much.

The “problem” here is that SketchUp handles everything you create as part of a framework of a 3D model. So the breaking of edges at intersections is a fundamental part of the SketchUp philosophy, and 2D drawing is seen as secondary.

Creating groups or components would prevent the splitting from happening, but it would probably result in new, different problems at the CAD end.

1 Like