curved folding assmt1.gh (88.5 KB)
I have downloaded a gh script for one surface to be folded with a curve hinge, and it works, but when it comes with more than one, and the surface topology changed from rectangle to diamond, the data tree seems crashed as the results says almost all of my mesh are invalid. May I have someone to help me for that? Thank you so much.
The Hinge and PlasticHinge goals work on sets of 4 points like this:
In your definition there are different numbers of points going into these inputs, so they aren’t in matching sets of 4.
Generally I would not recommend trying to find these points manually by shifting lists and so on as is happening in your definition, since you can’t usually rely on the ordering of the vertices.
Instead, use the
component (found under the Kangaroo Mesh tab). This extracts this set of 4 points for every internal edge in your mesh.
Thank you for replying! but the hingepoints extract them in a messy way which all the tips and foldstarts/foldends are in the 4 outputs. And after I connect to hingepoints, I found that there are many empty branches in the data tree as well…I’m so sorry but could you please help me out with this? Thank you so much
Yes, it looks like something is wrong with the data tree structure. I’m guessing this means it isn’t actually joined into a single mesh either, but is a big collection of single faces.
I’m not going to fix your data structure for you. The overall structure of this whole definition looks overly complex and confused.
Also all this lofting and splitting of surfaces, only to create a mesh of triangles in the end is not a good way I think. If what you want is a mesh, better to create the mesh to begin with, rather than going via surfaces.
I’d recommend stepping back a bit - maybe following some tutorials or videos on data trees, then starting again from scratch. Downloading definitions from others can be a great way to learn, but make sure you understand each of the parts of the definition before trying to combine them into a more complex whole.