Version: 6.5.0
Home
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Functions
Basic Operations
Transforming geometrical objects

Functions

def geompy.MakePartition
 Perform partition operation.
def geompy.MakePartitionNonSelfIntersectedShape
 Perform partition operation.
def geompy.Partition
 See method MakePartition() for more information.
def geompy.MakeHalfPartition
 Perform partition of the Shape with the Plane.
def geompy.Archimede
 Perform an Archimde operation on the given shape with given parameters.

Detailed Description

Function Documentation

def geompy.MakePartition (   self,
  ListShapes,
  ListTools = [],
  ListKeepInside = [],
  ListRemoveInside = [],
  Limit = ShapeType["AUTO"],
  RemoveWebs = 0,
  ListMaterials = [],
  KeepNonlimitShapes = 0 
)

Perform partition operation.

Parameters
ListShapesShapes to be intersected.
ListToolsShapes to intersect theShapes.
LimitType of resulting shapes (see ShapeType()).
If this parameter is set to -1 ("Auto"), most appropriate shape limit type will be detected automatically.
KeepNonlimitShapesif this parameter == 0, then only shapes of target type (equal to Limit) are kept in the result, else standalone shapes of lower dimension are kept also (if they exist).
Note
Each compound from ListShapes and ListTools will be exploded in order to avoid possible intersection between shapes from this compound.

After implementation new version of PartitionAlgo (October 2006) other parameters are ignored by current functionality. They are kept in this function only for support old versions.

Parameters
ListKeepInsideShapes, outside which the results will be deleted. Each shape from theKeepInside must belong to theShapes also.
ListRemoveInsideShapes, inside which the results will be deleted. Each shape from theRemoveInside must belong to theShapes also.
RemoveWebsIf TRUE, perform Glue 3D algorithm.
ListMaterialsMaterial indices for each shape. Make sence, only if theRemoveWebs is TRUE.
Returns
New GEOM.GEOM_Object, containing the result shapes.

Example

References geompy.EnumToLong(), geompy.MakePartitionNonSelfIntersectedShape(), and geompy.RaiseIfFailed().

def geompy.MakePartitionNonSelfIntersectedShape (   self,
  ListShapes,
  ListTools = [],
  ListKeepInside = [],
  ListRemoveInside = [],
  Limit = ShapeType["AUTO"],
  RemoveWebs = 0,
  ListMaterials = [],
  KeepNonlimitShapes = 0 
)

Perform partition operation.

This method may be useful if it is needed to make a partition for compound contains nonintersected shapes. Performance will be better since intersection between shapes from compound is not performed.

Description of all parameters as in previous method MakePartition()

Note
Passed compounds (via ListShapes or via ListTools) have to consist of nonintersecting shapes.
Returns
New GEOM.GEOM_Object, containing the result shapes.

Example

References geompy.EnumToLong(), geompy.Partition(), and geompy.RaiseIfFailed().

def geompy.Partition (   self,
  ListShapes,
  ListTools = [],
  ListKeepInside = [],
  ListRemoveInside = [],
  Limit = ShapeType["AUTO"],
  RemoveWebs = 0,
  ListMaterials = [],
  KeepNonlimitShapes = 0 
)

See method MakePartition() for more information.

Example 1
Example 2

def geompy.MakeHalfPartition (   self,
  theShape,
  thePlane 
)

Perform partition of the Shape with the Plane.

Parameters
theShapeShape to be intersected.
thePlaneTool shape, to intersect theShape.
Returns
New GEOM.GEOM_Object, containing the result shape.

Example

References geompy.RaiseIfFailed().

def geompy.Archimede (   self,
  theShape,
  theWeight,
  theWaterDensity,
  theMeshDeflection 
)

Perform an Archimde operation on the given shape with given parameters.

The object presenting the resulting face is returned.

Parameters
theShapeShape to be put in water.
theWeightWeight og the shape.
theWaterDensityDensity of the water.
theMeshDeflectionDeflection of the mesh, using to compute the section.
Returns
New GEOM.GEOM_Object, containing a section of theShape by a plane, corresponding to water level.

Example

References geompy.ParseParameters(), and geompy.RaiseIfFailed().

Copyright © 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE
Copyright © 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS