Grasshopper

algorithmic modeling for Rhino

I have a not-quite-developable surface, and I want to squash it flat to make a fabric pattern.  I thought the way to do this would be to use a strong CoPlanar constraint to make it flat, and springs on each mesh edge to pull them close to their correct lengths.

When I try this, it doesn't seem to do anything; the output of the solver is a null point for each of the vertices in the original mesh (screenshot attached).

I notice that the output of the CoPlanar component is a single Goal object, while the Length component gives me a list of separate Goals for each edge; is it something to do with that?  I am guessing this is something to do with my lack of Kangaroo experience...

Views: 3291

Attachments:

Replies to This Discussion

Could you post an example of the kind of mesh you are applying this to?

Sure, I've attached the mesh I was using.  The meshes will always be fully triangulated and welded, and capable of being projected onto a plane without overlapping themselves.

Attachments:

It looks like the main problem is that some mesh edges are shorter than the default tolerance, so their ends are getting combined.

One simple way to fix this is just to lower the tolerance (to say 0.0001).

However, I think better results will be achieved by remeshing the surface first, so that the edge lengths vary less. The remesher component from Kangaroo 0.099 can be used for this (I'm also working on an update for this soon).

Also, since in this case there is no need for the fitting plane to vary during the simulation, it would be more efficient to find a best fit plane to the points once at the start and use this as the input to an OnPlane goal instead of using CoPlanar (which finds the best fit plane at every iteration).

Finally, for this sort of flattening, some smoothing is often useful to stop the mesh from crumpling or folding over itself.

Attachments:

Thanks!  That's very helpful.

Looking into this, I also just discovered the facility to make custom goals in Kangaroo2-- I might even try to model anisotropic fabric stretching...

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service