Somehow I cannot get the mesh normals right. Do you might know what I am doing wrong?
Thanks for your response.
problem get mesh normals 00.gh (162.1 KB)
Somehow I cannot get the mesh normals right. Do you might know what I am doing wrong?
Thanks for your response.
problem get mesh normals 00.gh (162.1 KB)
To me in this case, get Brep Normal is more reliable than Mesh Normal.
Hey
Now I was aiming for getting those ‘blocks’ more smooth along the mesh surface.
I am trying to get the curve-flips right, but I am not able to get it correct.
Do you might know a way? I have forms like these sometimes.
problem get mesh normals 01.gh (287.5 KB)
Hey @ForestOwl,
Could you explain a little better what goal you are after? What kind of geometry are you trying to get with the sweeping?
The section curves of your sweep produce the twist, since they don’t have the same direction. This can be easily remedied.
Furthermore, your rail curves are pretty messy polylines, which don’t favour sweeps. I’ve rebuild them to form interpolated curves, which seems work much better. A down side might be the loss of the polyline form, if it is important to you!
The sweep has been replaced with a loft, produced by tweened section curves (blue) along the rail curve (white).
It’s still a weird way to produce geometry, since its very unpredictable. Sharp turns and self intersections of rails will produce unfavourable forms.
problem get mesh normals 02.gh (249.1 KB)
I changed something to improve everything.
It are these kind of self-crossing forms caused by the curves that are not flipped the same/opposite(?) way.
problem get mesh normals 03.gh (254.7 KB)
Again, the direction of both section curves, at the start and end of the rail, must be equal. You can see in the script above, how I guaranteed that. If one of the section curves has an opposite direction, it is pretty logical that sweeps, tweens, and similar operations have to flip at the midsection of the rail.
Here’s a simple example, where dots show the location of the start points of each line.:
The above example depicts two section curves with the same direction. Thus the tween operation is clean.
The other one shows two section curves with opposite directions. Here the flip happens!
Yes, I know why it flips
I cannot get a way around to stop the flipping. Do you might know a direction for that?
Offset over surface? I cannot get it right…
Simply use the flip component like in my above example!
I was not satisfied with my result. I need to be more advanced in Grasshopper to get what I want.
Do you might know how to ‘cull intersecting and keep one’ like with the ‘cull duplicate points component?’
These chocolate squares are going to wild.
problem get mesh normals 04.gh (291.1 KB)
You’re as always welcome, but when you have two lines that must have the same direction, you should use the Flip
component and plug the first line into its C
input, and the second into its G
input. This way, the first line gets flipped, if it doesn’t match the direction of the second, referenced line.
The CullPt
component leaves one of two pretty much identical points. In your case, you have to come up with a rule that decides which of the intersecting geometries to keep, since they are not evaluated by equality, but by intersection!
You could do this in Python, if you like.
I am trying to get the chocolade pieces aligned by making the right plane, but I am not able to get it right.
The z-vectors are ruling; and then I need to align it with the x-vectors. Do you know what I need to get the chocolate pieces aligned?
problem get mesh normals 05.gh (121.7 KB)
EDIT: I did something wrong, I somehow managed it.