On 09/03/2015 at 13:41, xxxxxxxx wrote:
Cinema 4D Version: 14,15,16
Language(s) : C++ ;
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.
const Vector *pPoints = ToPoint(op)->GetPointR();
LONG i, numPoints = ToPoint(op)->GetPointCount();
for(i=0; i<numPoints; i++)
Now how do I make use of mm to update the bounding box of my polygonal object?
On 09/03/2015 at 13:53, xxxxxxxx wrote:
Regarding the unselectability, you should send MSG_UPDATE after you
are done making changes to the object via its Message() method.
On 09/03/2015 at 14:14, xxxxxxxx wrote:
Thanks Niklas. That did the trick, and updated the bounding box as well.