Remove close lines from .dwg import

I’ve imported a .dwg model from an Adobe Illustrator export. My plan is to make it 3d, but need to create faces on it first.

The curves always have multiple lines which makes it hard to get separate, selectable faces. They look like woven lines instead of curves. I haven’t been able to find a plugin that will remove these extra lines. So far I’ve had to go through and remove the extra lines by hand, but there are too many. My goal is to have separate faces inside each curve stripe.

sketchup forum question.skp (305.8 KB)

Thank you!

post the .dwg it may be an import, it may be possible to either export or import it using different settings…

john

Thanks John, here’s the .dwg.

EDIT: updated test file
curve-export-test.dwg (14.1 KB)

Your file seems unusual, in that the geometry is inside a component that is inside another component. Usually I would expect there to be only one group or component. You could select all, right-click, explode a couple of times to get the geometry up to the top.

You can create a face by redrawing one of the lines, and once a face is there it becomes easier to select and delete the rogue extra lines.

Could you post the Illustrator file, so I can try the same export test?

I was hopeful it had a layer for each line, but no…

what are your line export settings in illustrator?

it should be easier than this…

john

You’ll save a lot of time and frustration by simply building the model in SketchUp.
A plugin will not relieve you of learning SU’s native tools.

• Concentric circles created by drawing one and then offsetting thereafter.
• A rectangle drawn on top.
• Then erase what you don’t need.
• 3D Text (unfilled)


3 Likes

Thank you @Geo. I was able to recreate the model in sketchup using your technique. Thank you for those good directions. This takes time but is a lot quicker than removing all the extra lines by hand.

@john_drivenupthewall and @colin, I will post the Illustrator file as soon as I get it.

@colin and @john_drivenupthewall, here is the illustrator file that does not export with single line curves. Thank you!

rectangular_archesBottom_troubleshooting.ai (1.5 MB)

Keep in mind, though, that an offsetted circle uses the (perpendicular) distance between the segments, not the (true) offset of the radii!

I get the same results as you. One good thing to note is that other DWG viewers see the same issue, so it’s not a SketchUp import issue, but an Illustrator export one.

As a work around you can export SVG from Illustrator, then use a converter such as this one:

https://cloudconvert.com/svg-to-dxf

to make a DXF. That worked well.

I’m involved with Adobe forums too, if you don’t mind I’ll ask my friends over there if anyone has an idea on exporting dxf or dwg correctly.

I’ll attach the converted file I was given.

rectangular_archesBottom_troubleshooting-2.dxf (23.2 KB)

1 Like

I really appreciate it Colin! :smile: And it would be great to know a simpler process if you have the time. I’ll adopt this workflow for now. Thanks again!

I didn’t ask anyone yet, but I think I have an acceptable workflow. There are a lot of posts that are on the right lines, but almost none that have good solutions. But there is this one:

https://forums.adobe.com/thread/911561

If you read the proposed solution it will get you on the right lines. The basic problem is that CAD wants arcs and Illustrator wants splines, and the work around is to make the curves more detailed, then change them to be straight lines. That then exports fine.

My steps would be:

Select All
Object/Path/Add Anchor Points, several times
Object/Path/Simplify, check the Straight Lines box (also Preview, so you don’t have to commit to the change yet)
If the curves become too straight, add more anchor points. Once it looks good enough, commit to the straight lines change.

Then export either DWG or DXF.

SU 2018 is in fact better at importing splines than older versions, but still far from perfect. The link to the DWG is gone (?) and the AI is from a newer version incompatible with my CS5 so I can only guess. Do the paths have a width, however small, in Illustrator? The double lines might be the result of the exporter trying to draw a line around the arcs instead of through the middle line of the path, and the SU importer does the rest of the messing up. I am not sure as most of the things I have imported have been logos and the like where the artworks consist mainly of filled regions.

Thanks for checking it out @Anssi. Sorry about the file, here it is. I’m also attaching an .ai file that should work with CS5.

curve-export-test.dwg (14.1 KB)

curve-export-test-cs5.ai (1.3 MB)

Hi @colin. Your solution makes good sense to me. Unfortunately when I simplify then export Sketchup adds curves on top of the straight lines.

To make sure I was seeing it right, I tested to the extreme, with a large simplification.

I took this simplified .ai with straight lines (CS5 for wider testing)…
curve-export-test2.ai (1.3 MB)

and exported to this .dwg.
curve-export-test2.dwg (14.8 KB)

When importing into sketchup I get the straight lines, but then lines that look like smoother curves too?

As far as I understand as a not very proficient Illustrator user, the double lines are caused by the fact that you indeed have two series of superimposed paths. When I ungroup your drawing, there are white filled paths directly underneath the red ones. I deleted the white paths and released the red compound path. Then it started to behave, in my opinion. I didn’t do anything to the splines. I used a larger than life import unit (exported in millimeters ans imported in centimeters).
curve-export-test.skp (113.3 KB)
curve-export-test-cs5.dwg (10.8 KB)

Did you do the Select All, Object/Path/Add Anchor Points a few times too? What you showed just now is exactly what I get if I don’t add the anchor points. But even then if I do my own export I don’t get the double lines you’re seeing. Here’s my Illustrator export settings:

@Anssi I ungrouped in illustrator and found those extra paths in the layers panel. After I removed those and re-exported all seems to work just fine!

@Colin Yes, I was doing something wrong and it seems independent of export settings. You’re solution also works. I’m glad to know it!

Thanks everyone for their quick responses and helpfulness. I’m glad I finally asked about this issue and grateful to this community.