Grasshopper

algorithmic modeling for Rhino

Dear All,

 

I have a problem with adjusting a script I have written. The original script selects random points on a surface and moves them in a random domain in Z direction and later on in X and Y directions. Later these points are rearranged in appropriate order to create curves. These curves are interpolated and lofted to generate a surface.

The problem with the generated surface is that the edges of the surface are not staying on my C plane. In other words, I would like to create a surface that maintains an outer frame connected to the ground. Therefore, I would like to generate a further selection process that selects random points in specific boundary on the surface. Creating a smaller surface would not help as the edges of the surface would still float in the air.

For that, I deconstructed the edges of my surface, connected them and offset them to create a boundary for the random points selection. I used points in curve selection to restrict the selection through a cull pattern.

Unfortunately, the script is not working anymore, and I’ve struggled for some time trying to fix it.

I’ve attached the original script, my attempt to adjust the script and a rhino file with an example of a surface resulted from the original script.

 

Thanks very much in advance!

Best, Yoav.

P.S.

Sorry for the long description!

 

Views: 1941

Replies to This Discussion

Although you gave a very thorough description of your problem, and uploaded your files (great!) it is always super helpful to those commenting on the forums if you are able to make a sketch/take a screenshot of your file (where you can label the geometries so we know which ones you are talking about in your description) and then show us a sketch/screenshot of what you want your end goal to be. 

I'm not sure if this is exactly what you are after, but here are two possible solutions.

1. Similar to what Joseph said, take the end points of your interpolated curves, and pull them down to the ground before you loft the curves. If you need all 4 edges on the ground, you could add a flat, straight curve on either side of your set of curves before you loft them all.

2. Another option is to just take the existing edge of your lofted surface, and loft that to a flat offset curve that borders your surface on the ground. 

Another option altogether is to consider an alternative to the loft component. Like maybe the Patch component, or surface from points.

Attachments:

I'm a little puzzled by your methods...  In particular, the diverging data trees that result from 'Flatten' and the gaps in columns/rows of points?  Makes it difficult for me to modify your code without changing a lot more than I care to.  In general though, you want to damp the effect of your 'Z' value based on each point's distance from the nearest edge.  So at or near the edges, the 'Z' values become zero.

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