Grasshopper

algorithmic modeling for Rhino

Hi, I am trying to project a curve onto multiple surfaces (preferably only ones that are within range) and achieve ONE curve. I am having trouble obviously. The curve projected using the pull and push methods seems to "ride" along the edge after it has reached the edge of the surface. As if it has to finish its length. I have tried setting up a project curve on breps method, but i keep getting the same error as Dirk. I am not sure which method is better nor how to resolve these errors. Can anyone comment on this? Definition and Rhino file attached.


Views: 4354

Replies to This Discussion

There are several issues here, the first being that there is a distinct difference between Pulling and Projecting a curve to a surface/brep. Pulling essentially finds the closest point to the surface at each point along the curve, thus recreating a curve on the surface that is the closest it can get to the original curve. Projecting simply extrudes the curve along a given direction (which is specified) and retrieves the intersection. Projecting will "respect" when a curve "hits" the edge. With pulling, however, after the curve reaches the edge, the remainder of the curve will still be pulled back to the surface. This is why the pulled curve seams to "ride" along the edge.

Its unclear to me as to whether you're more interested in pulling or projecting. Personally, I would stick with projecting if at all possible. Its a much more "reliable" operation that will give more predictable results. Pulling curves is a much more contextual operation, and you may get errors that might make it hard to deal with the resulting curves. This isn't necessarily a bad thing, but it will likely be more work. Also, resolving the "riding along the edge" issue is probably something that's going to take some sort of effort from you to resolve, since Rhino won't resolve it as you want it too within this condition.

As to the projection issue you're having, this is simply because the brep and curves aren't put into an array before they are passed to the project function. Also, there is no need to extract each surface from the brep. I've made some modifications to that component, so take a look at it in the attached definition.

Lastly, about achieving one curve across multiple breps. This is possible, but will require you to either A) join the resulting projections or B) use the resulting curves to recreate your own curve manually (so that its continuous and not pieces of smaller curves). The first option is easy, you can use the ON_JoinCurves function found in the OnUtil class. The second might be a little harder, and you may not be guaranteed for the curve to lie continuously on the surface anymore.

HTH
Attachments:

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service