Hi all, i'm trying to get the Bounding box of a prexisting mesh. but i'm not sure if i'm aproching it the right way. has anyone dont this before? i see some samples of setting a BBox but none for setting.
i'm new to api so i could be doing the wrong thing here eaither way it doesnt work. any help would be great. i need to call this so i can plug height, width, depth into another function. cheers john ################ import maya.OpenMaya as OpenMaya def boundingBox(): selection = OpenMaya.MSelectionList() OpenMaya.MGlobal.getActiveSelectionList( selection ) dagPath = OpenMaya.MDagPath() mObj = OpenMaya.MObject() Bbox=OpenMaya.MBoundingBox(mObj) print Bbox.width() print Bbox.height() boundingBox() ##################### --~--~---------~--~----~------------~-------~--~----~ http://groups.google.com/group/python_inside_maya -~----------~----~----~----~------~----~------~--~---