Grasshopper

algorithmic modeling for Rhino

I have a curve in 3D, and I want to make it planar but maintain its length, sort of like pressing a bent wire onto a tabletop.

I can't directly project onto a plane, of course, because the length will change.

I'm currently experimenting with getting the curvature frames at several points along the curve, and then...well, I haven't figured that part out yet. Perhaps project each short segment onto the local curvature frame, then reassemble those projections somehow?

Any ideas are welcome, thanks!

Views: 2563

Replies to This Discussion

If you're going to arbitrarily unbend a curve in 3-D then the only thing that makes sense is to unbend it into a straight line so just use the curve length component to create a straight line.  Otherwise you have to chose an unbending direction and hence a plane that you will unbend onto.

Which way are you thinking about this?

Chris

I should have said this earlier: the curves I'm working with are basically "C" shapes that are not *too* far off planar, maybe a bit helical. So it's not the general case I'm trying to solve.

 

I do want to pick a direction to unbend it: the direction that requires the least unbending. I hope that made some sense. Basically the average plane of the original curve.

 

My current strategy is:

-shatter the curve into some number of segments

-get the curvature plane at the center of each segment

-project the segment onto that plane to get a planar segment that's close to the original

-connect the segments up again, rotated and translated so they join (this part isn't done yet, and may prove unworkable, and/or require scripting)

 

This way, I can increase the number of segments to increase accuracy, up to what I can live with.

 

There might be much easier ways to do this, but it's all I've thought of so far. Again, any thoughts on this are welcome!

You can have fun with this Kangaroo definition, even if it doesnt keep exactly the same curve length.
Attachments:

Thanks! That WAS fun! And it shows beautifully what I was trying to do.

 

I got my version working late yesterday, with a smidge of scripting and a lot of grasshopperiness. So I'm all good.

I've just been having this same issue, the workaround I've managed is fairly easy and straight forward.

 

1) control point of curve

2) fit plane through points

3) project curve onto plane

 

4)BINGO! (hopefully)

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service