Sweep Problem

Next
 From:  armin
3564.1 
Hi,

The gray blue surface shown at the screen shot does for some reason not exactly follow the
profile curve (cyan), it remains a gap. First I thought it might be a display problem, but
looking at it straight from the side, clearly shows an identation. And I was able to create
the same surface a different way, which didn't give me the gap.

In order to create this surface I used the sweep command. I picked the two profile curves
on either end and used the "center curve" as rail. The options were set to Freeform/Exact.
Maybe I am doing something wrong?

BTW, and I probably should create another thread for this, but is there a way to check if a
curve is completely planar, without showing the points and snaping the mouse pointer to each
one of them comparing the coordinate values?

Thanks in adavance
Attachments:

Image Attachments:
Size: 28.7 KB, Downloaded: 20 times, Dimensions: 622x764px
  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
3564.2 In reply to 3564.1 
Hi armin, sorry it's not very clear to me which parts you are sweeping.

The profile curves at the ends of the gray blue surface seem to be larger than it, did you sweep using the edge curves of the other pieces as the profiles, or cut the sweep afterwards or something?

Could you please post a simplified example that only contains the rails and profiles for the sweep and the sweep surface? That would make it easier for me to understand what you are doing.


> BTW, and I probably should create another thread for this, but is there
> a way to check if a curve is completely planar, without showing the
> points and snaping the mouse pointer to each one of them comparing
> the coordinate values?

You could go to a side view and use the edit frame - if you can't get a "flat" snap then it means you already have a planar shape.

In the future I want to have a kind of extended properties dialog that you could bring up to get more details on a shape, possibly whether it is planar or not could be there.

- 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:  Michael Gibson
3564.3 In reply to 3564.1 
Hi armin, I looked at your attached image, and nothing really seems to be wrong there.

Is the thing that you are concerned about the spot where the shaded surface part of the display has a little visible gap from the display of the edge here:




That's just a display artifact - the shaded part of the display is done by breaking the surface down into triangles. That's just an area that did not get a lot of triangles in the display mesh.

Currently the display mesh breaks things down by comparing angle values only, and if you have only a small shallow amount of curvature in an area, you get a bit too rough of a display mesh there.

It is not really anything to worry about, your actual surface is totally fine there.

The edge curve display is done to a higher accuracy than the shaded surface display - edges and curves are broken down on each screen redraw so that the display on the screen is only about 1 pixel off of the true curve. It's too calculation intensive to do that with the shaded surface display so the surface display can be somewhat rougher.

When you see that your edge looks fine, you can use that as more of a judge of things in this kind of situation. Just ignore little straight-ish deviations like this in the display mesh.

When you go to export to a polygon mesh format, you can make the exported mesh broken down by distances instead of only angle, so you can refine those areas further when exporting, like this:




- 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:  Michael Gibson
3564.4 In reply to 3564.1 
Hi armin, also you wrote:

> And I was able to create the same surface a different way,
> which didn't give me the gap.

That doesn't really mean that one surface was better than the other.

In fact, the one with the display artifact could very well be better actually - the other one probably has a denser amount of control points in the surface. That will also cause the initial display mesh to be denser as well.

If you can show me the 2 surfaces that you were referring to in this case, I could give you some more detailed information on this part.


In the future I do want to add a different kind of "chord height" metric to the display mesher to make it refine these areas with shallow curvature a bit more.


- 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:  armin
3564.5 In reply to 3564.4 
Hi Michael,

Sorry for my bad explanation. Your assumption was correct, that was exactly the area I was concerned about.
After further investigation, I'm not so sure about the display problem and I attached another file, hopefully
this explains it better.

If you go into FRONT view and than look at the surface on the right hand side, you can see it looks much cleaner.
In this case I actually took the longer "C" shaped curves and used the two shorter curves as rail, versus sweeping
the two shorter curves using the longer "C" shape as rail. But I maybe wrong on this. Anyway, I discovered some
other oddities in my curves, which are most likely the problem in the first place. So, I will go back and rebuild the
whole thing, haven't yet done it though.

If you look and the center model, there are quite some bumps on the left hand side at the transition to the straight
shot. the same on the right hand side, though not quite as bad. The screen shots don't really show it too well. And
don't ask me how they got there :), because when I started building the curves I had some clean 3 point arcs. And
I rebuild the the whole thing so many times in different ways, because I couldn't apply fillets in further steps.

Another question, which is not really related to my sweep problem, is there a way to temporarily switch the snaps
to only "endpoint" for example, without going to the settings dialog at the bottom of the screen. I was thinking more
of a keyboard shortcut that sets the snap for this one time to a certain entity and the switches right back to the
"regular" settings. This way I could deactivate some lesser used snaps which would help, especially if you get into
areas where you have a lot of geometry coming together. I think this is my main problem, because I think my line or
whatever snaps to a certain entity while it actually snaps to something else.

Sorry for getting so lengthy with my post.

Thank you anyways.
Attachments:

Image Attachments:
Size: 9.3 KB, Downloaded: 7 times, Dimensions: 455x395px
Size: 27.7 KB, Downloaded: 4 times, Dimensions: 879x693px
Size: 16.7 KB, Downloaded: 3 times, Dimensions: 606x664px
  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
3564.6 In reply to 3564.5 
Hi armin, I'm sorry it's kind of difficult for me to follow your post,

For example, you write:

> If you go into FRONT view and than look at the surface on
> the right hand side, you can see it looks much cleaner.

I went to the Front view, but I'm not exactly sure what I am supposed to be comparing.

In the front view I see a bunch of things, you have a solid and some surfaces and they are all kind of stacked up together from that view so it is not exactly clear to me what you are referring to.

But you seem to be referring to that same surface that I wrote about earlier here:
http://moi3d.com/forum/index.php?webtag=MOI&msg=3564.3

That surface did not get very many triangles in its display mesh, so it ends up being displayed in a coarse manner.

That's only a display artifact, not actually a problem in your surface.

Having a small number of triangles leads to some flat areas in the display, that's what the artifact is.

That makes an appearance like this:



And as you noticed from the side view a too coarse display mesh can look like this:




That's just another view of the same display mesh problem - the display mesh has areas with not enough triangles in it, some pieces got enough and some areas did not, making a slightly inconsistent profile view there.

That is just part of the same display artifact that I described earlier.

If you export to a polygon mesh format, ensuring that you get enough polygons, this is what that exact same surface looks like:




So again, it's just the same advice I wrote previously - that part that you are worried about there is just a display artifact where not enough triangles were made in that particular area to make a nice looking realtime view of the surface.

The actual surface itself is not jaggedy or broken like that, it's just the display mesh that is jaggedy.

This display artifact can happen in areas where there is only a shallow amount of curvature in the surface.

- 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:  Michael Gibson
3564.7 In reply to 3564.5 
Hi armin, I'm trying to split up my answer into some different parts.

You also wrote:

> If you look and the center model, there are quite some bumps
> on the left hand side at the transition to the straight
> shot. the same on the right hand side, though not quite as bad.
> The screen shots don't really show it too well.

Looks like some kind of wiggle in the surface interpolation where there is a sudden shift between your curved arc piece and the straight line segment which has no curvature.

One way to avoid it is by applying sweep a few different times, instead of doing the sweep all in one pass.

So for example, build this sweep first:



Then select this edge at the end:



And do another sweep using that:



And so on, that's how I made the attached version which seems to be a bit better than your original.


Also though your line is not exactly tangent to those 2 arc pieces, it is off by almost 1 degree on one side and about 0.5 degrees on the other side, that is probably not helping things out either.

- 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:  Michael Gibson
3564.8 In reply to 3564.5 
Hi armin,

> Another question, which is not really related to my sweep
> problem, is there a way to temporarily switch the snaps
> to only "endpoint" for example, without going to the settings
> dialog at the bottom of the screen.

Well, one thing is when you go to that menu (the one that pops up from the Object Snap button on the bottom toolbar when you click the arrow above it), you can right-click on one of the snaps which will turn off all of the other ones and only keep it on.

Then later on you can right-click on that same one again to re-enable all the others.

You can also set up the following on a keyboard shortcut to make that menu open up with a keystroke instead of going to the button to launch it:

script: /* Pop up the object snap menu */ var cb = moi.ui.getUIPanel('moi://ui/CommandBar.htm'); moi.ui.showMenu( 'ObjectSnapMenu.htm', cb.document.body.lastChild.lastChild, 2, 0 );


Or this variation which shows it in the center of the screen:

script: /* Show object snap dialog */ moi.ui.createDialog( 'moi://ui/ObjectSnapMenu.htm' );


That's probably better than something that is only hard-coded to just set "End" only, because by showing the menu and using the right-click as described above you can set any particular snap as the only active one instead of only end.


- 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:  Michael Gibson
3564.9 In reply to 3564.5 
Hi armin, also probably a better way to get rid of those little lumps is to use the Rebuild command on your joined rail curve.

To do that, select it, then type Tab, then "Rebuild", then push Enter.

I did that in the attached model.

That helps to smooth out the small tangent deviations between the different segments in your original.

I used a tolerance of 0.001 units for the rebuild in this case.

- 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:  armin
3564.10 In reply to 3564.9 
Hi Michael,

Thanks a lot for your quick reply. The script for the snaps that works for me. And I will try to build
the surfaces in smaller segments, makes sense. I'm just not used into building my objects from
nurbs surfaces, so it's a little bit relearning.

I played a little bit more with that file and I've noticed the snaps are really my problem - attached
is a screen shot and the 3dm file. I get a lot of those not really connected points. You don't really
see it until you zoom in very, very close. The spot on the screen shot is marked with a red circle
on the model. And I have those spots all over the place. The distance is very small and I guess in
most cases it doesn't matter. You don't really notice it until you zoom in that close, which in most
cases I don't do. I assume the best way avoiding those "gaps" is probably making heavy use of
turning certain snaps on or off?
Attachments:

Image Attachments:
Size: 9.3 KB, Downloaded: 0 times, Dimensions: 509x454px
  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
3564.11 In reply to 3564.10 
Hi armin,

> I assume the best way avoiding those "gaps" is
> probably making heavy use of turning certain
> snaps on or off?

You don't necessarily have to turn them off, although you can if you want.

The main way is to just pay attention to what the little tags on the snapped point say, it will actually have the text saying "End" in that little tag if that point is on an end snap, like this:




If you get a snap that does not have "End" listed in it, like if it only says "Perp" or something like that, then that's a sign that you are not quite at the right spot.

It can also help a lot if you zoom in a little bit when you want to snap on to a particular thing, try to get in the habit of using the mouse scroll wheel more often to make the local area that you are trying to target larger on the screen rather than staying far away when there are several things in the same area.

- Michael
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

Previous
Next
 From:  Michael Gibson
3564.12 In reply to 3564.10 
Hi armin,

> And I will try to build
> the surfaces in smaller segments, makes sense.

I'll also be looking into some more tune ups for 1-rail sweep in v3, it would probably help if sweep automatically did a rebuild of the rail.

That does happen for 2-rail sweep but not 1-rail sweep currently.

- 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:  armin
3564.13 In reply to 3564.12 
Hi Michael,

Man you're fast with your answers, one of those days you gonna get a speeding ticket :).
That's not a complaint, don't get me wrong.

Yeah, I saw those little snapping hints, sometimes I just have too much geometry concentrated
at one spot, and than you move your mouse pointer around and don't find the right one, or you
(in this case I mean myself) think you got the right one, but you don't. But I guess if I'm more
careful from the beginning, I shouldn't run into those situations.

Thanks again

-Armin
  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:  Michael Gibson
3564.14 In reply to 3564.13 
Hi Armin,

> sometimes I just have too much geometry
> concentrated at one spot

That's when you've got to zoom in so that all that geometry is on a larger area of the screen rather than all condensed together.

You want to make it almost a reflex to zoom in and then back out or sometimes hit the Reset button to go all the way out to frame the whole object again.'

- 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
 

Reply to All Reply to All