Hi,
ignoring the fact, that you are using the term "bottom" in your diagram - which would hint at a much harder and not yet properly solved problem: giving computers a sense of human shape recognition -, I assume you are just after the minima and maxima of the vertex positions of an object in a reference frame. First of all: Note, that there is the slightly confusingly named BaseObject.GetRad()
, which will give you the bounding box vector for an object.
If you are after the bounding box of an object in a reference frame, that is not the associated frame (local matrix) of that object, you simply have have to iterate through all points in that frame and figure out the minima and maxima, i.e. compute its bounding box in that frame. In pseudo code for just the minimum y-axis case of your example:
min_y = None
for p in my_objects.GetAllPoints():
_p = p * my_transform_matrix
min_y = _p.y if not min_y else min(_p.y, min_y)
If you are unsure on how matrix transforms work, this thread might help you out.
Cheers
zipit