I’m trying to create a simple script to model a shape from a rail and two (or more) different profile curves. This is why I want to use sweep, to blend between the different profile curves.
In Rhino this command works fine, by marking the “untrimmed miters”.
But when I try to do this in GH, it seems that the the kinks of the polyline is making GH fail on the sweep command.
I had a look into this and it is a bit of a puzzler. I think you could code this particular application but it wouldn’t be a generic solution. I tried digging through the RhinoCommon documentation but it doesn’t have anything for the ‘untrimmed miters’ option that you need.
Not a great solution but I’d suggest generating profile curves at each kink point in your rail by tweening between your end curves, then lofting through those.
Also FYI one of your Grasshopper profiles doesn’t have its kink point line up with the rail curve, this can easily be fixed:
Within Grasshopper via right klick on “M” of rail function, it is possible to change the miter. However, it did not solve the problem when I tried changing it.
Yeah I did find that miter option, however it didn’t seem to make any difference however it was set! Is that a problem with the code or with the geometry in this instance?
Thank you so much for your effort and for getting back to me this quick,
Its wierd to me, that you can’t make the code from Rhinocommon do the same as rhino itself with the untrimmed miters. This woudl have been a nice way to get GH to do this… But thank you for trying Matthew.
Anyone who thinks this is possible?
I’d suggest generating profile curves at each kink point in your rail by tweening between your end curves, then lofting through those
I’m not sure how to do this. I can get the perp planes for each kink, but I need more than one plane for the two kinks in the middle of the "rail"curve, in order for the loft to be perp to the rail-direction, everytime the curve is turning.
I tried to do the tweening bwtween the two curves, and put the profile curves in the right order(right now in a very clumsy way, using list item. I’m not even sure the order is correct). How can I make sure the profile curves are used in the right order?
Also FYI one of your Grasshopper profiles doesn’t have its kink point line up with the rail curve, this can easily be fixed:
Could you perhaps show the name of the components you use. I’m having a hard time finding the same ones Either with bifocals or maybe without the “icons” displayed. Sorru for this, but it would make it easier for me…
Thank you,
According to the order, I would love to be able to check the order of the profile curves (input curves to the orient component). So that I know which profile curve is used at what kink. Does this makes any sense? …
E.g.:
Start point: Profile curve 1
Second kink on rail curve: tween profile curve A
Thirds kink on rail curve: tween profile curve B
End pot on rail curve. profile curve 2
The tween is happening between profile curve 1 and 2.
Toh - check out the definition attached - should do what you’re after by using the tween between curves method. Also FYI the referenced profile curves you have in your definition don’t match the edge profiles of your ‘PRSF create by sweep1 in Rhino’. So even when I had the method worked out, the created surface didnt match the Rhino one. I’ve rebuilt the profile curves from the rhino surface to get a closer match.
Can you post your definition? Keen to see what you’ve done here. What curves are you lofting between?
Yeah that would be great, cause the result looks good
And thank you so much Matt, for posting a definition fixing both the “origin” point of my assymetric profile curve, and finding the plane of the curve. It looks great, but I get this message when opening, and the treesloth only works for R4-R5. Can you fix this without using the treesloth, or is it available for R6?
I’ve revised the definition to avoid using treesloth (which does work for Rhino 6 FYI, its just a series of components to make list and tree handling a little easier. Nothing overly essential, just nice to have). The component I used went between the stream filter and tween components. The edge curves taken from Rhino isn’t working as I forgot to internalize the geometry before saving
Wauw thank you so much! This was way more complex than what I could have done myself.
But now its working very well. Impressive!
But its an important fact, how GH acts very different depending on if its a polyline or a curve.
The sweep in GH works very well if its a curve, but if its a polyline we need your definition.