Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python 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

    Detecting changes in hierarchy structure [SOLVED]

    SDK Help
    0
    2
    273
    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.
    • H
      Helper
      last edited by

      On 14/07/2017 at 03:25, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   12 - 18 
      Platform:   Windows  ; Mac  ;  
      Language(s) :     C++  ;

      ---------
      Hi all,

      from the GetVirtualObjects() of my generator, I need to detect if changes to the hierarchical structure of its children have occurred.

      For example, the childrens' hierarchy looks like this:

      And the user changes it like this:

      After changing the hierarchy like shown above, none of the objects becomes dirty. And checking the generator's dirtyness with DIRTYFLAGS_CHILDREN also doesn't help.

      GetAndCheckHierarchyClone() notices the change. But I don't always want a hierarchy clone to be created (since I'm only drawing a simplified representation of my generator's results in most cases). I just need to know if the hierarchy of my generator's children has changed. Is there any way to do that?

      Thanks & greetings,
      Frank

      1 Reply Last reply Reply Quote 0
      • H
        Helper
        last edited by

        On 14/07/2017 at 05:37, xxxxxxxx wrote:

        Ha, solved!

        calling op- >GetHDirty(HDIRTYFLAGS_OBJECT_HIERARCHY) and comparing the result to the previous result does the trick. Totally didn't have HDirty on my radar anymore...

        Greetings,
        Frank

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