op->GetTag(Tplugin, 0) no longer works?



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

    On 08/11/2006 at 21:28, xxxxxxxx wrote:

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

    ---------
    Anyone know why the following code stopped working in 9.6 SDk ?

        
        
         ptagi = 0;  
         while( ptag = (PluginTag* )(op->GetTag(Tplugin, ptagi++)) )  
         {
        
        
        
        
        GePrint("Hello?  Anyone there?"); //--- this is never called
        
        
        
        
          
          if( ptag->GetType() == GTAG_PLUGID )  
          {  
           groups = ptag->GetData();  
           gCnt = groups.GetLong(GROUP_COUNT);  
           break;  
          }  
         }  
        
    

    ...the mesh in question DOES have a plugin tag on it (of type GTAG_PLUGID), but op->GetTag() is failing now.  I was using this code all over the place in previous versions, but for some reason it no longer works with the 9.6 SDK.
    Do I need to start counting from 1 now or something?  ~baffled~
    Keith



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

    On 08/11/2006 at 21:37, xxxxxxxx wrote:

    I take that back... that code still works with a 9.6 SDk compiled plugin in the R9.6 demo, but it does not work in the R10 demo... so the question still stands, but has now changed to why or how did that change in R10?
    Thanks,
    Keith



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

    On 09/11/2006 at 02:22, xxxxxxxx wrote:

    I think you made a mistake. You pass the PluginID to GetTag() like this:

      
    LONG ptagi = 0;  
    while( op->GetTag(GTAG_PLUGID, ptagi++) )  
    {  
    GePrint("Hello? Anyone there?"); //--- this is never called  
    }  
    [CODE]  
      
    Admittely this is not very clear in the docs.  
      
    cheers,  
    Matthias  
    


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

    On 09/11/2006 at 02:39, xxxxxxxx wrote:

    Seriously? Hmm... I wonder why the way I was using it (with the Tplugin type, as per the docs :) ) was working from 7.3 on up through 9.6?
    This definately sounds like a change.  Of course the R10 SDK docs may have been updated to reflect this, but I hadn't seen those docs available yet.
    Anyway, I'll give that a try - thanks much!
    Keith



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

    On 09/11/2006 at 02:47, xxxxxxxx wrote:

    Hmm... that does seem to work - and as a bonus, it works either way in 9.6, so I can use the same plugin for 9.6 and 10 - thanks!


Log in to reply