How to report plugin object's memory usage in "Object Information"



  • Hi,

    since I can remember we've been able to call up the "Object Information" dialog on any object in the Object Manager. The dialog will show the memory usage of that object.

    How can I tell Cinema how much memory my object is using? Sure, it generates a geometry whose memory consumption can easily be computed, but what about all the other data I'm caching internally? Is there a way to report that memory to Cinema? Where does the "Object Information" dialog get it's data from?

    Cheers,
    Frank



  • hello,

    for the memory the function does :

    • for each tag it add sizeof(*tag) and if it's a variable tag (Tvariable), the datacount * datasize. (points and polygons are on tags)
    • calculate the animation' size (size of track, curve and keys)

    If you want to support that features, you have to store your data in a VariableTag.

    Cheers,
    Manuel



  • Ah, thanks. Hm, that wouldn't make sense in this case. I might just add a STATICTEXT to my objects and display memory usage myself.

    Thanks!

    Greetings,
    Frank

    PS: Would be cool if NodeData would get something like virtual UInt GetMemoryUsage() const, so plugin developers could override it.



  • hi,

    I think you have access to the beta and BL so you can create a suggestion :)

    Cheers,
    Manuel