Hi Ferdinand,
Yeah, I'll need to do dirty checking for sure. Not because I am shipping this to any customers (unless I can find a good licensing framework 😉 ), but because the nature of my plugin is to create quite a few objects; We could easily reach 100s or even 1000s of objects, depending on the situation.
So I implemented primitive dirty checking from one of the links you provided, and this helps a LOT with the performance - as you're mentioning, just ignoring the cache and recreating everything every time GetVirtualObjects is called would effectively kill Cinema 4D. Especially when fiddling with parameters, as the algorithm to layout all the objects I am creating is quite intensive.
So I'm using your code from this topic https://developers.maxon.net/forum/topic/14936/difficulties-to-dedect-the-right-message-data/2 to make sure I do proper dirty checking for my own generator and all linked objects before I decide to return the cache or generate all objects again. I'm not done yet, but early tests seem pretty promosing.
Now if only there was a simple way to split the large python file into multiple files, then bundle them all together for one giant python file so I wouldn't have to mess with module paths. 1000 line code files get old real fast. 😄
Thanks again!