TagData: Dynamically creating AM?



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

    On 13/04/2004 at 05:42, xxxxxxxx wrote:

    User Information:
    Cinema 4D Version:   8.206 
    Platform:      
    Language(s) :     C++  ;

    ---------
    Hi,
    I have an idea for a TagData plugin and it envolves dynamically creating controls for the AM.
    I need to AM to be completely generated through code. With a dialog plugin, its easy because I have access to CreateLayout, but there doesnt seem to be a tagdata equivalent.
    Is this even possible?



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

    On 13/04/2004 at 15:37, xxxxxxxx wrote:

    See NodeData::GetDDescription(). (Note that you'll still get the same layout limitations as with a description resource file, i.e. it won't be the same as CreateLayout().)



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

    On 05/06/2004 at 14:40, xxxxxxxx wrote:

    Bringing alive old thread, but its revelant.
     
    For the life of me I can't dynamically add widgets into a AM field.
     
    This is my code, almost an cut andpaste from the forum

        
        
        
        
        Bool MyTagPlugin::GetDDescription(GeListNode *node, Description *description, LONG &flags)  
        {
        
        
        
        
         
        
        
        
        
            LONG dtype = DA_LONG;  
            BaseContainer descbc = GetCustomDataTypeDefault(dtype);  
            String name = "my param name";  
            descbc.SetString(DESC_NAME, name);  
            descbc.SetString(DESC_SHORT_NAME, name);  
                                   
            // etc for DESC_MIN, DESC_MAX, DESC_MINSLIDER, DESC_MAXSLIDER                 
            descbc.SetLong(DESC_CUSTOMGUI, CUSTOMGUI_LONGSLIDER);  
            DescID descid(DescLevel(33333, dtype, MY_PLUGIN_ID));  
            if (!description->SetParameter(descid, descbc, DescLevel(ID_TAGPROPERTIES)))  
          return false;  
         
        
        
        
        
         
        
        
        
        
           
         flags |= DESCFLAGS_DESC_LOADED;
        
        
        
        
         
        
        
        
        
         return TagData::GetDDescription(node,description,flags);  
        }
        
        
        
    

    When I look at my AM, it is just completely blank.
    Why?



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

    On 08/06/2004 at 04:38, xxxxxxxx wrote:

    You have to add

        
        
        if (!description->LoadDescription(node->GetType())) return FALSE;
    

    as the first line of the function. The reason is that otherwise the basic Tbase description isn't loaded, and without it ID_TAGPROPERTIES isn't a valid groupid.


Log in to reply