A3DMiscComputeBoundingBox

A3DStatus A3DMiscComputeBoundingBox(const A3DEntity *pEntity, A3DDouble const *pOptPlacement, A3DBoundingBoxData *pAABB)
A3DStatus A3DMiscComputeBoundingBox(const A3DEntity* pEntity, A3DDouble* pOptPlacement, A3DBoundingBoxData* pAABB)

Use the tessellation to compute the axis-aligned bounding box (AABB) of the given entity.

An invalid bounding box corresponds to those values:

  • The computation is done on infinite elements.
  • The CAD data do not contain any tessellation.
  • pEntity is of type A3DRiPlane.

It can occur under following conditions:

This function computes the bounding box using tessellation data. If you want to read the actual bounding box from CAD data, see A3DMiscGetBoundingBox().

Parameters

pEntity: The Entity to get the bounding box from. It can be any of A3DAsmModelFile, A3DAsmProductOccurrence, A3DAsmPartDefinition or A3DRiSet.

pOptPlacement: Reserved for future use. Must be set to 0.

pAABB: A pointer to a valid A3DBoundingBoxData which will be filled in with the computed bounding box. If not possible an invalid bounding box is filled in (see below).

Returns

A3D_SUCCESS on success, or an error code on failure