Exemplo n.º 1
0
void Skeleton::updateSkeleton(GraphicsObject *node, FrameBucket* pResult) 
{
   // --------- Do pose stuff here -----------------------
   this->setBonePose(node, pResult);
   
   
   // iterate through all of the active children - copied from GOM, will it work here???
   GraphicsObject *child = 0;

   if (node->getChild() != 0)
	{  
	   child =	(GraphicsObject *)node->getChild();
	   // make sure that allocation is not a child node 
	   while (child != 0)
	   {
          updateSkeleton( child, pResult );
         // goto next sibling - node's child, but now we are iterating SIBLINGS
         child = (GraphicsObject *)child->getSibling();
	   }
   }
   else
	{
      // bye bye exit condition
	}
}
Exemplo n.º 2
0
void GraphicsObjectManager::privDrawObjectsDepthFirst( GraphicsObject *node ) const
{
   GraphicsObject *child = 0;

   // --------- Do draw stuff here -----------------------
   
    //  node->print();
       node->transform();
	   node->setRenderState();
	   node->draw();
   
   // --------- Do draw stuff here -----------------------


   // iterate through all of the active children 
   if (node->getChild() != 0)
	{  
	   child =	(GraphicsObject *)node->getChild();
	   // make sure that allocation is not a child node 
	   while (child != 0)
	   {
         privDrawObjectsDepthFirst( child );
         // goto next sibling
         child = (GraphicsObject *)child->getSibling();
	   }
   }
   else
	{
      // bye bye exit condition
	}

}