59. plugins.pyformex_gts
— Operations on triangulated surfaces using GTS functions.¶
This module provides access to GTS from insisde pyFormex.
59.1. Functions defined in module plugins.pyformex_gts¶
-
plugins.pyformex_gts.
boolean
(self, surf, op, check=False, verbose=False)[source]¶ Perform a boolean operation with another surface.
Boolean operations between surfaces are a basic operation in free surface modeling. Both surfaces should be closed orientable non-intersecting manifolds. Use the
check()
method to find out.The boolean operations are set operations on the enclosed volumes: union(‘+’), difference(‘-‘) or intersection(‘*’).
Parameters:
- surf: a closed manifold surface
- op: boolean operation: one of ‘+’, ‘-‘ or ‘*’.
- filt: a filter command to be executed on the gtsset output
- ext: extension of the result file
- check: boolean: check that the surfaces are not self-intersecting; if one of them is, the set of self-intersecting faces is written (as a GtsSurface) on standard output
- verbose: boolean: print statistics about the surface
Returns: a closed manifold TriSurface
-
plugins.pyformex_gts.
intersection
(self, surf, check=False, verbose=False)[source]¶ Return the intersection curve of two surfaces.
Boolean operations between surfaces are a basic operation in free surface modeling. Both surfaces should be closed orientable non-intersecting manifolds. Use the
check()
method to find out.Parameters:
- surf: a closed manifold surface
- check: boolean: check that the surfaces are not self-intersecting; if one of them is, the set of self-intersecting faces is written (as a GtsSurface) on standard output
- verbose: boolean: print statistics about the surface
Returns: a list of intersection curves.
-
plugins.pyformex_gts.
inside
(self, pts, atol='auto', multi=True)[source]¶ Test which of the points pts are inside the surface.
Parameters:
- pts: a (usually 1-plex) Formex or a data structure that can be used to initialize a Formex.
Returns an integer array with the indices of the points that are inside the surface. The indices refer to the onedimensional list of points as obtained from pts.points().