algorithmic modeling for Rhino
Hello. Is it possible to automatically recalculate python component when geometry in rhino document was moved or changed? Also I need to know an id of the object that was moved.
Good question. Every time I've bumped in to this problem I have solved it with a timer, as you have done above. Would be interesting to know if anyone has found a better solution. Feels like it should be possible to track down the event handler of the specific object if you know the Id..
Here's a solution that appears to work. The key idea is to attach a callback function to the AddRhinoObject event.
Thank you! It's working and it's great!
As I understood function will be removed from event when you are closing Rhino. Is it right?
Can't you just assign the object to a brep and input that to your Python script with a wire and let Grasshopper issue a recalculation when it changes in the Rhino doc?