Hey I have a question regarding GetObject for Rhinocommons custom Objects.
I’m writing a plugin where I’m adding custom objects to the doc. I want the user to be able to run commands on those objects so I need to build a GetObject function.
My approach for my CustomCurveObject class is using getObject with geometryfilter set to curve extracting the guids of the selected objects and then iterating over the result of document.objects.GetObjectsByType comparing the guids.
This is inefficient and feels more like a hack then a true solution. Can I setup a custom geometryfilter to allow only certain types to be selected?
Also part of the reason for my approach is that I want to run class Methods of MyCustomCurveObject so the result of getObject needs to be of type MyCustomCurveObject.
Any hints on how to do this the right way would be greatly appreciated as my ‘solution’ can’t be the recommended way. Thanks in advance