SceneDraw()

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

On 09/03/2011 at 03:19, xxxxxxxx wrote:

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

---------
When is SceneDraw() called for a GvOperatorData plugin?

I have the following in my GvOperatorData plugin and it never seems to get called..  I never see "SCENE DRAW"  in the console.  😞

  
  
   
Bool NParticle::SceneDraw(GvNode* bn, BaseDraw* bd, BaseDrawHelp* bh, BaseThread* bt, LONG flags, void* data, ULONG counter){  
    
  GePrint("SCENE DRAW");  
  
  return TRUE;  
}  
  
  

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

On 09/03/2011 at 05:18, xxxxxxxx wrote:

have a look at the GvNodeMaster class. It has a function AddToDrawList which is described as follows:

Bool AddToDrawList(GvNode* bn, void** data = NULL, LONG data_size = 0);

Adds a node the an internal list of nodes that want to have GvOperatorData::SceneDraw() called during the next internal draw.

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

On 09/03/2011 at 05:49, xxxxxxxx wrote:

Awesome.. Thanks Satara,  I will check it out when I get home. 
 
🙂
 
Shawn

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

On 09/03/2011 at 17:11, xxxxxxxx wrote:

Hey Satara any idea how I would use this function..  I am not finding a lot about it in the forums.

Thanks,

Shawn

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

On 09/03/2011 at 17:40, xxxxxxxx wrote:

Well I think I have it figured out.  In the InitCalculation() I put...

  
bn->GetNodeMaster()->AddToDrawList(bn, NULL, 0);  

and now SceneDraw is called.. Thanks for the tip.  😉

~Shawn