Dropping the axis

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

On 19/07/2011 at 12:15, xxxxxxxx wrote:

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

---------
Hey everyone.  I want to drop the axis of my object to the bottom of the bounding box.

I can accomplish this by moving the points of the object like so.....

  
//DROP AXIS  
  //=====================================//  
  if(bc->GetBool(PXG_DROP_AXIS) == TRUE)  
  {  
      for(int i = 0; i < pointCount; i++)  
      {  
          points[i].y += op->GetRad().y;  
      }  
  
      main = polyObj;  
        
  }  
  
  //=====================================//  
  

However, the bounding box itself does not move..    Anyone know how I get the bounding box to move with this change?

Thanks,

Shawn

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

On 19/07/2011 at 12:21, xxxxxxxx wrote:

To elaborate...  Here is how I set the bounding box...

  
  
//SET THE BOUNDING BOX  
//=====================================//  
void MyClass::GetDimension(BaseObject *op, Vector *mp, Vector *rad){  
  
  if(!main) return;  
  *rad =  main->GetRad();   
    
}  
  
  

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

On 19/07/2011 at 21:20, xxxxxxxx wrote:

In GetDimension(), you provide the bounding box information.  GetRad() and GetMp() use this for a plugin object.  It is up to you, my friend, to calculate the relevant information to return with that method.

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

On 20/07/2011 at 05:14, xxxxxxxx wrote:

Thanks Robert.  That was the issue, I was not filling the *mp value in GetDimension.

Thanks again,

Shawn