Grasshopper

algorithmic modeling for Rhino

Hi guys!

This is my first post; I shall aim to be as specific as I can be.

I have created the Cairo tiling pattern, which can Tessellate using a "point on curve" component. Using these lines I want to split a surface. I can do it in grasshopper but it takes over a minute depending upon the intensity of the  pattern. Thus I want to do it on python or C# script with the following steps:

(I) Bake the Tiling Lines

(II) Bake the Surface

(III) Split the Surface  with curves in Rhino( it is almost realtime in the software)

(IV) Retrieve the surface back

(V) Delete the previous baked surface and bake the new one if I move the slider.

I tried doing it with Python( I a complete rookie when it comes to coding language) and facing a lot of problems with Attributes and Guids. I would appreciate it to the core,If someone could enlighten me on how to go about the this.

Thanks in Advance guys!

Views: 1679

Attachments:

Replies to This Discussion

Hi Aditya,

Check the attached file and enable python component.

Attachments:

Hi DJ!

It works like a charm! Is there a quick guide to coding with python. I just feel clogged in some situations especially when it comes to looping and adding conditions, that can be achieved in Grasshopper with too many parameters in play.

I really appreciate the help. Thanks!

There is, but it's not generally related with grasshopper, but Rhino Python instead.
Also above attached component uses a bit of macros, and document targeting.

Hi DJ

I Just encountered an error with the script...whenever (the marked slider, refer image) goes above 25, the polylines get baked and not the surface, Furthermore , when the same slider goes beyond 29 the surface split returns and gives weird splits.

Also, If you move "MOTION MAKER" below 1/3 and above 3/4 I get weird splits again.

Don't know why this is happening....I'm attaching my complete definition.

Attachments:

Here are the other images

Attachments:

Hi Aditya,

I couldn't replicate the baking issue you are having. My assumption is that sometimes grasshopper gets confused when switching documents, so this may be the case. Restarting Rhino will fix this.
As for the weird splits - this is also not the issue with the ghpython component, but with the cutting curves you generated - they overlap, and do not "go" from one intersection to the other. Try baking your cutting curves and the underlying surface, and then run the "Split" command in Rhino manually. You will see that weird splits will also appear, and this is all due to the way your cutting curves were created. You may not get exactly the same weird shapes pattern in Rhino as if you would get in grasshopper (because the patter n depends on the order by which your curves have been selected), but you will still get weird splits.

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