Grasshopper

algorithmic modeling for Rhino

Optimal Option to Animate Brep with Python Component by Using Transformation Matrices

how to animate a brep from the GHPython Comp. by using transformation matrices? I know how to do it by redrawing the object every iteration but I'm having some troubles with creating the object just once and then apply transformations to update its position.

Any Hint?

Views: 558

Replies to This Discussion

Hi Giulio, thanks a lot for your quick response.

It seems (as far as I understand) that in all the examples they update the 3dPoints pos inside the component and afterwards the points are used outside to rebuild the geometry after every iteration. (For example if they use a Mesh like they did in the ShapeOp by using the Construct Mesh Component)

My question has to do with this old post where I need to create just once a Mesh from inside a component Python (let say with Rhino Common) and after every iteration access the Guid and update its position/orientation by using a 4x4 matrix.

http://www.grasshopper3d.com/forum/topics/where-is-the-boundary

Here I attach a similar example with a circle and with a translation:

Thanks again for your feedback

Attachments:

Hi Augusto

see this example about creating a mesh if the 'new_g' is not defined, and then iteratively modifying it.

The add and delete are just to keep track of the object in the Grasshopper object across two different solutions. In fact, otherwise, normally the Grasshopper document is cleared after each solution ends.

Giulio
--
Giulio Piacentino
for Robert McNeel & Associates
giulio@mcneel.com

Attachments:

Thanks Giulio, very clear example.

-Augusto

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service