Making Lines co-planar

The ideal place for beginners to get help using SketchUp

Making Lines co-planar

Postby JPMays » Tue Feb 22, 2011 6:52 pm

Hi all,

I am somewhat of a newcomer to this forum, I only use it sporadically as my job requires (I don't always do SU work). Yes, I did search before I posted this, but still need some help.

My question is related to to 2D contours, imported from AutoCAD. They always come in without faces, and so I found the plugin Make Faces, and used that. That helped, but I still have many unclosed objects (that appear that they should be faces). I'm wondering if my lines are not co-planar somehow. Is there a good script to make all lines have a n equal z-value (all flat on the base plane)? Or some other way to create faces where there should be faces?

0
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.

JPMays 
 

Re: Making Lines co-planar

Postby Dave R » Tue Feb 22, 2011 7:26 pm

It could be that your edges are not co-planar but I would suspect also that there are tiny gaps in some of the edges. If you zoom in very close, you'll likely find some of them. There are several plugins which can find those gaps and fill them in. Close Opens from Smustard comes to mind.
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: Making Lines co-planar

Postby Anssi » Tue Feb 22, 2011 7:35 pm

A simple way to "flatten" a model in SU Pro without a script or other special tools is to select plan view, turn on parallel projection, and export a 2D DWG file to full scale, and re-import that.

Anssi
0
securi adversus homines, securi adversus deos rem difficillimam adsecuti sunt, ut illis ne voto quidem opus esset
User avatar
Anssi 
 

Re: Making Lines co-planar

Postby JPMays » Tue Feb 22, 2011 7:56 pm

Dave R - that's a good suggestion, but I can't drop $20 for a plugin that may or may not solve my problem. Any other options?

Anssi - I exported as you suggested, and re-imported that new file. It had the same problem, no faces, but I am re-running Make Faces. Will see what happens.

Thanks to you both.
0
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.

JPMays 
 

Re: Making Lines co-planar

Postby JPMays » Tue Feb 22, 2011 8:05 pm

Anssi - Ok, tried your fix: same result. I'm at a loss here.
0
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.

JPMays 
 

Re: Making Lines co-planar

Postby Dave R » Tue Feb 22, 2011 8:07 pm

Well, if the problem is gaps, you'll still have to fix them to get faces. there's no way around that. You can do it manually (free) by zooming in and drawing in lines to close the gaps. It might be that there aren't very many gaps to fix...if you're lucky.

I find these gaps in nearly every DXF or DWG file I import. AutoCAD doesn't care if lines actually meet. It's not creating faces. SketchUp requires them to do so in order to create the faces
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: Making Lines co-planar

Postby JPMays » Tue Feb 22, 2011 8:14 pm

I downloaded and installed Stray Lines (from Smustard, to label, select, delete or show all the open-ended line segments in a drawing), but so far it is just crashing. I can't do it manually, this drawing is way too large and I don't have that kind of time or patience.
0
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.

JPMays 
 

Re: Making Lines co-planar

Postby Dave R » Tue Feb 22, 2011 8:22 pm

Is it the plugin or SketchUp that is crashing?

If it is gaps in the lines that is preventing the creation of faces, you have no alternative but to fix them somehow. You cannot have a face without a closed border.

You could narrow down where the gaps are by drawing lines between contour lines. If you create a closed loop, SketchUp will ad a face. Keep adding lines until you can't get a face and then look closely in the area where the face is missing to find the gap. You could probably draw lines across a number of contours at once to narrow down the locations of the gaps.
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: Making Lines co-planar

Postby ledisnomad » Tue Feb 22, 2011 8:36 pm

I'm quite familiar with this problem. My solution is certainly not unique or instantaneous, but it doesn't require a plugin and doesn't require zooming in and out madly:

1. Make as many continuous, joined polylines. This assures minimum gaps. A few things I've found helpful: With nothing selected, enter pedit command, then "m" for multiple (personally, I didn't know about this option until recently), select everything, convert to a polyline, then choose join. Then you can check what joined and what didn't. Anything that should be joined, use fillet with 0 radius to join. The more time you spend in AutoCAD, the easier it is in SketchUp.

2. After I import and use MakeFaces, I start connecting edges with diagonals. Anywhere that isn't a face that should be probably has a gap or there is a tiny extra line somewhere that SU has problems with. Connecting diagonals will often may a face on half of the problem area, the second diagonal will fill in half the remaining area, then you can keep narrowing it down to the problem spot. This is pretty quick, really.

That's the best method sans plugin that I know. Hope it helps. And if I've been unclear about anything, feel free to ask for clarifications.
0

ledisnomad 
 

Re: Making Lines co-planar

Postby ledisnomad » Tue Feb 22, 2011 8:37 pm

Oh look at that... Dave R beat me to the punch. Always so quick here at SketchUcation.
0

ledisnomad 
 

Re: Making Lines co-planar

Postby JPMays » Tue Feb 22, 2011 8:38 pm

I think it was the plugin. I need to play around with that a little more. I did determine another problem, which I fixed and I think will help a lot. many of my lines, even thought they overlapped, did not intersect, and I think that was what was preventing Make Faces from recognizing a face.



I selected all and Intersected with Model, which fixed that. Now I'm running Make Faces again, and it is taking a long time which is a good sign (it's recognizing a lot more faces than previously). Hopefully this will solve the majority of problems. I'll update later.
0
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.

JPMays 
 

Re: Making Lines co-planar

Postby JPMays » Tue Feb 22, 2011 8:45 pm

ledisnomad - I've used the same technique you described, and it usually works well. the problem is that my file is very large and I don't have the time or patience to do that for every single un-closed face. I have been hoping to find some kind of script to help me do this comprehensively. Make Faces seems to be the go-to one.

Update: after running Make Faces again (once I Intersected) I got a lot more faces. There are still some gaps, but a small enough amount to fix manually.

Thanks all for your help.
0
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.

JPMays 
 

Re: Making Lines co-planar

Postby mitcorb » Tue Feb 22, 2011 11:11 pm

Look at ThomThom's Edge Tools, which he recently updated. This may have application for what you describe. See this link:
viewtopic.php?f=323&t=24593
0
I take the slow, deliberate approach in my aimless wandering.
User avatar
mitcorb 
Top SketchUcator
 

Re: Making Lines co-planar

Postby mac1 » Wed Feb 23, 2011 12:57 am

Also ThomThoms clean up
0

mac1 
Top SketchUcator
 

Re: Making Lines co-planar

Postby JPMays » Wed Feb 23, 2011 3:45 pm

ThomThom's Edge Tools are awesome! This will help me out a lot. Thanks mitcorb for the link.
0
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.

JPMays 
 

Re: Making Lines co-planar

Postby bluetobits » Fri Jan 25, 2019 1:10 pm

Hi.

I use SU for 3D printing. I find that when working at small scale such as 1:87, some things that one would expect should work in SU, doesn't. if I enlarge everything at least 10 or 100 times, SU works a lot better. I then re shrink by the same factor before exporting to STL for printing. 1000x is a good value, as I can treat millimetres as metres.
It's nice to be able to suggest solutions than to be the one asking for them!
Steve
0

bluetobits 
 

Re: Making Lines co-planar

Postby Dave R » Fri Jan 25, 2019 5:46 pm

bluetobits wrote: if I enlarge everything at least 10 or 100 times, SU works a lot better. I then re shrink by the same factor before exporting to STL for printing. 1000x is a good value, as I can treat millimetres as metres.


That's a good way to work. Alternatively if you need the model to be at a certain small size you can start it at the small size, select the geometry and make a component. Then copy the component, scale it up by 100 or 1000 and do whatever needs doing. When you are finished, exit the edit mode for the component and delete the giant one. Zoom Extents to go back to the original one. I use this frequently when modeling detailed things like drawer pulls which have to be shown at the correct size. Working on the scaled up copy avoids the need to scale back down and the original is in place where it was originally started.

If you are going to export to STL for 3D printing, there's no need to scale down. Do your modeling with units set to Meters but think millimeters. Leave it at that size and export the STL. When you import the STL into your slicer program, tell it that the units are millimeters. STL files are unit-less so you have to tell it something.

Since you are modeling for HO scale, you could do your modeling in real world dimensions and work from there.

bluetobits wrote:It's nice to be able to suggest solutions than to be the one asking for them!
Steve


Please keep up the good work.
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: Making Lines co-planar (Anssi's Solution)

Postby tmk40126 » Thu Mar 07, 2019 9:12 pm

Anssi... you are the GOD of non-coplanar fixes. Thank you my friend!
0

tmk40126 
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 



 

Return to Newbie Forum

Who is online

Users browsing this forum: No registered users and 2 guests

Visit our sponsors: