On 09/03/2015 at 13:41, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 14,15,16
Platform:
Language(s) : C++ ;
---------
Hi,
Let's say that I have a polygonal object and I scaled its points without changing the object matrix. As a result, the bounding box is not affected by the scaling, and the object is unselectable outside the original bounding box (before the scaling).
My question is how do I update the bounding box after the point scaling. I cannot scale the object matrix because I am doing some intricate point manipulation and not just scaling.
I figured I would use MinMax, but I don't know how to apply it to the object.
MinMax mm;
const Vector *pPoints = ToPoint(op)->GetPointR();
LONG i, numPoints = ToPoint(op)->GetPointCount();
mm.Init();
for(i=0; i<numPoints; i++)
{
mm.AddPoint(*pPoints);
pPoints++;
}
Now how do I make use of mm to update the bounding box of my polygonal object?
Thanks