Hi Fellas,
I have to create a bunch of surfaces normal like the example file and image attached.
My problem is that I have to make over 700 of them !
Is there any way out of having to do it manually?
Automate ArrayCrvOnSrf Sweep1.3dm (4.8 MB)
Hi Fellas,
I have to create a bunch of surfaces normal like the example file and image attached.
My problem is that I have to make over 700 of them !
Is there any way out of having to do it manually?
Automate ArrayCrvOnSrf Sweep1.3dm (4.8 MB)
Hi Yianni - it seems unlikely that it can be automated - possibly with Grasshopper… but I need to know moe - what is the input? do you have some curves someplace that are the inputs to the 700? Are they all different? Are the target surfaces all the same
-Pascal
Hi Pascal,
The inputs are the green-ish curve to the right and the red curve on the surface.
The target surface is a single one.
Hi Yianni - right, but what are you starting with 700 times? Are all of the red curves already on the surface and you just need to set that one section curve to sweep on them, or do you need to place 700 path curves, or?
-Pascal
Sorry for not being clear
Red curves are in place, I just need to make the sweeps.
OK, well, here’s one thing you can try, I don’t know if it will be good enough -
Automate ArrayCrvOnSrf_PG .3dm (4.3 MB)
A.
Extrude
the profile curveB.
CreateUVCrv
from the 3d surface and target curves.Flow
, Copy=Yes from the extrusion axis in A to each of the curves - this will be the hard/time consuming part and maybe a little script will help.FlowAlongSrf
back to the 3d surface@Yianni_VJ here’s a quick and dirty python that, assuming my process above gets you something useful, will do all of the Flows at once- http://screencast.com/t/Gm8heU2zso
`import Rhino
import rhinoscriptsyntax as rs
import scriptcontext as sc
def test():
Id1 = rs.GetObject("Select object to flow", filter = 8+16)
obj = sc.doc.Objects.Find(Id1)
if obj.ObjectType == Rhino.DocObjects.ObjectType.Extrusion:
brep = sc.doc.Objects.Find(Id1).Geometry.ToBrep()
else:
brep = obj.Geometry
Id2 = rs.GetObject("Select base curve", filter=4)
crv1 = sc.doc.Objects.Find(Id2).Geometry
Ids = rs.GetObjects("Select target curves",filter=4)
for Id in Ids:
morph = Rhino.Geometry.Morphs.FlowSpaceMorph(crv1, sc.doc.Objects.Find(Id).Geometry, False)
x = brep.Duplicate()
rc = morph.Morph(x)
if rc:sc.doc.Objects.AddBrep(x)
pass
sc.doc.Views.Redraw()
test()`
-Pascal
Your procedure is working !
But I cant get the script to load, can you please see what i did wrong?
pascal.py (727 Bytes)
pascal.py (742 Bytes)
Try this one - there was no indent and an extra mark from the Discourse formatting.
-Pascal
Pascal this was excellent !
You really saved me hours of work !
Thanks a billion !