Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

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

    Cinema 4D SDK
    c++ classic api
    2
    4
    731
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • fwilleke80F
      fwilleke80
      last edited by fwilleke80

      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

      www.frankwilleke.de
      Only asking personal code questions here.

      1 Reply Last reply Reply Quote 0
      • ManuelM
        Manuel
        last edited by

        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

        MAXON SDK Specialist

        MAXON Registered Developer

        1 Reply Last reply Reply Quote 0
        • fwilleke80F
          fwilleke80
          last edited by fwilleke80

          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.

          www.frankwilleke.de
          Only asking personal code questions here.

          1 Reply Last reply Reply Quote 0
          • ManuelM
            Manuel
            last edited by

            hi,

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

            Cheers,
            Manuel

            MAXON SDK Specialist

            MAXON Registered Developer

            1 Reply Last reply Reply Quote 0
            • First post
              Last post