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
    • Recent
    • Tags
    • Users
    • Login

    Update Generator when children changed?

    Scheduled Pinned Locked Moved SDK Help
    3 Posts 0 Posters 334 Views
    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 Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 01/01/2011 at 23:10, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   R10-R12 
      Platform:   Windows  ;   Mac OSX  ; 
      Language(s) :     C++  ;

      ---------
      I've noticed that when, say, a procedural Sphere's Segment is changed when under my generator object plugin, no update occurs in the generator.  Is there a way to notice such changes (a message, perhaps).

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

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 02/01/2011 at 03:56, xxxxxxxx wrote:

        works fine here. DIRTY_DATA is triggered for the child then.

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

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 02/01/2011 at 15:04, xxxxxxxx wrote:

          Here is what I have up to where actual generation begins in the GetVirtualObjects() method.  Let me know if you see any changes that can be made.  Thanks! 🙂

          // ObjectData.GetVirtualObjects  
          //*---------------------------------------------------------------------------*  
          BaseObject* GreeblerObj::GetVirtualObjects(PluginObject* op, HierarchyHelp* hh)  
          //*---------------------------------------------------------------------------*  
          {  
            // Get first input object  
            BaseObject*        child =    op->GetDown();  
            if (!child)                return NULL;  
            
            // Generate polygonalized clones of input objects  
            // NOTE: 'mainop' is the polygonized original returned with greebler-generated objects  
          #ifndef    C4D_R12  
            hh->AddVFlags(VFLAG_POLYGONAL);  
          #endif  
            Bool            dirty = op->CheckCache(hh) || op->IsDirty(DIRTYFLAGS_DATA);  
            if (!dirty)                return op->GetCache(hh);  
            mainop =                op->GetAndCheckHierarchyClone(hh, child, HIERARCHYCLONEFLAGS_ASPOLY, &dirty, NULL, TRUE);  
            // - if !dirty object is already cached and doesn't need to be rebuilt  
            if (!dirty)                return mainop;  
            if (!mainop)            return NULL;  
            
            // GreeblerObj BaseContainer  
            BaseContainer*    obc =    op->GetDataInstance();  
            if (!obc)                return mainop;  
            
            // Progress Bar - Begin  
            StatusSetText("Greebler Updating...");  
            StatusSetSpin();  
            
          ...  
          }  
          
          1 Reply Last reply Reply Quote 0
          • First post
            Last post