CAD Exchanger SDK
cadex::ModelAlgo_ValidationProperty Class Reference

Computes validation properties of the objects. More...

Static Public Member Functions

static double ComputeSurfaceArea (const ModelData_Model &theModel, bool theUseProperty=false, bool theStoreProperty=false)
 Returns a surface area of a scene graph.
 
static double ComputeSurfaceArea (const ModelData_SceneGraphElement &theElement, bool theUseProperty=false, bool theStoreProperty=false)
 Returns a surface area of a scene graph element.
 
static double ComputeSurfaceArea (const ModelData_Representation &theRep)
 Returns a surface area of a representation.
 
static double ComputeSurfaceArea (const ModelData_Shape &theRep)
 Returns a surface area of a shape.
 
static double ComputeSurfaceArea (const ModelData_IndexedTriangleSet &theTriangleSet)
 Returns a surface area of a triangle set.
 
static double ComputeVolume (const ModelData_Model &theModel, bool theUseProperty=false, bool theStoreProperty=false)
 Returns a volume of a scene graph.
 
static double ComputeVolume (const ModelData_SceneGraphElement &theElement, bool theUseProperty=false, bool theStoreProperty=false)
 Returns a volume of a scene graph element.
 
static double ComputeVolume (const ModelData_Representation &theRep)
 Returns a volume of a representation.
 
static double ComputeVolume (const ModelData_Shape &theRep)
 Returns a volume of a shape.
 
static void ComputeCentroid (const ModelData_Model &theModel, ModelData_Point &theValue)
 Returns a center of mass of a scene graph.
 
static void ComputeCentroid (const ModelData_SceneGraphElement &theElement, ModelData_Point &theValue)
 Returns a center of mass of a scene graph element.
 
static void ComputeCentroid (const ModelData_Representation &theRep, ModelData_Point &theValue)
 Returns a center of mass of a representation.
 
static void ComputeCentroid (const ModelData_Shape &theShape, ModelData_Point &theValue)
 Returns a center of mass of a shape.
 
static bool ComputeValidationProperties (const ModelData_Model &theModel, ModelAlgo_ValidationPropertyData &theData)
 Returns validation properties data of a scene graph.
 
static bool ComputeValidationProperties (const ModelData_SceneGraphElement &theElement, ModelAlgo_ValidationPropertyData &theData)
 Returns validation properties data of a scene graph element.
 
static bool ComputeValidationProperties (const ModelData_Representation &theRep, ModelAlgo_ValidationPropertyData &theData)
 Returns validation properties data of a representation.
 
static bool ComputeValidationProperties (const ModelData_Shape &theShape, ModelAlgo_ValidationPropertyData &theData)
 Returns validation properties data of a shape.
 

Detailed Description

Computes validation properties of the objects.

Each property can be computed either for an entire model (ModelData_Model) or for any assembly, part, instance, or part representation. Additionally, you can compute all properties for a particular object at once for improved performance.

Depending on model contents some validation properties cannot be computed. For instance, volume cannot be computed for sheet bodies and surface area cannot be computed for wireframe bodies. Currently for polygonal representations, only surface area can be computed.

Methods computing properties for an entire model or a graph element accept extra parameters:

  • Boolean theUseProperty - specifies whether the validation property already stored in the model should be returned (if true) or computed
  • Boolean theStoreProperty - specifies whether the validation property should be stored inside the model (if true).

Validation properties can be stored in the model using property tables attached to respective scene graph element using predefined property names (e.g. "CADEX_VOLUME" for volume).

See also
ModelAlgo_ValidationPropertyData, Measurements.