Version: 6.3.1
Home
Functions

Restore presentation parameters and a tree of subshapes

Transforming geometrical objects

Functions

def geompy.RestoreSubShapes
 Publish sub-shapes, standing for arguments and sub-shapes of arguments To be used from python scripts out of geompy.addToStudy (non-default usage)
def geompy.RestoreGivenSubShapes
 Publish sub-shapes, standing for arguments and sub-shapes of arguments To be used from python scripts out of geompy.addToStudy (non-default usage)

Function Documentation

def geompy.RestoreSubShapes (   self,
  theObject,
  theArgs = [],
  theFindMethod = GEOM.FSM_GetInPlace,
  theInheritFirstArg = False,
  theAddPrefix = True 
)

Publish sub-shapes, standing for arguments and sub-shapes of arguments To be used from python scripts out of geompy.addToStudy (non-default usage)

Parameters:
theObjectpublished GEOM object, arguments of which will be published
theArgslist of GEOM_Object, operation arguments to be published. If this list is empty, all operation arguments will be published
theFindMethodmethod to search subshapes, corresponding to arguments and their subshapes. Value from enumeration GEOM.find_shape_method.
theInheritFirstArgset properties of the first argument for theObject. Do not publish subshapes in place of arguments, but only in place of subshapes of the first argument, because the whole shape corresponds to the first argument. Mainly to be used after transformations, but it also can be usefull after partition with one object shape, and some other operations, where only the first argument has to be considered. If theObject has only one argument shape, this flag is automatically considered as True, not regarding really passed value.
theAddPrefixadd prefix "from_" to names of restored sub-shapes, and prefix "from_subshapes_of_" to names of partially restored subshapes.
Returns:
list of published sub-shapes

Example

def geompy.RestoreGivenSubShapes (   self,
  theObject,
  theArgs = [],
  theFindMethod = GEOM.FSM_GetInPlace,
  theInheritFirstArg = False,
  theAddPrefix = True 
)

Publish sub-shapes, standing for arguments and sub-shapes of arguments To be used from python scripts out of geompy.addToStudy (non-default usage)

Parameters:
theObjectpublished GEOM object, arguments of which will be published
theArgslist of GEOM_Object, operation arguments to be published. If this list is empty, all operation arguments will be published
theFindMethodmethod to search subshapes, corresponding to arguments and their subshapes. Value from enumeration GEOM.find_shape_method.
theInheritFirstArgset properties of the first argument for theObject. Do not publish subshapes in place of arguments, but only in place of subshapes of the first argument, because the whole shape corresponds to the first argument. Mainly to be used after transformations, but it also can be usefull after partition with one object shape, and some other operations, where only the first argument has to be considered. If theObject has only one argument shape, this flag is automatically considered as True, not regarding really passed value.
theAddPrefixadd prefix "from_" to names of restored sub-shapes, and prefix "from_subshapes_of_" to names of partially restored subshapes.
Returns:
list of published sub-shapes

Example

 All Data Structures Namespaces Files Functions Variables
Copyright © 2007-2011 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