Module fmeobjects :: Class FMEFace
[hide private]
[frames] | no frames]

Class FMEFace

 object --+            
          |            
FMEGeometry --+        
              |        
     FMESurface --+    
                  |    
   FMESimpleSurface --+
                      |
                     FMEFace

init(MultipleInvocations)

FME Face class.

Create an instance of a Face geometry object.

init(boundary, mode)

This routine creates a new Face geometry object. The stroked boundary of the area isused. If there are any errors, None may be returned. If the area passed in is not in 3D, then the default value for the z coordinates is 0.0

Parameters

Returns: FMEFace

init(boundary, mode, matrix)

This routine creates a new Face geometry object. With the specified transformation matirx

Parameters

Returns: FMEFace

init(boundary, mode)

This routine creates a new Face geometry object. The stroked boundary of the line isused. If there are any errors, None may be returned. If the line passed in is not in 3D, then the default value for the z coordinates is 0.0

Parameters

Returns: FMEFace

init(boundary, mode, matrix)

This routine creates a new Face geometry object. With the specified transformation matirx

Parameters

Returns: FMEFace

init(points, mode)

Creates a face from the list of points passed in.

Parameters

Returns: FMEFace

init(points, mode matrix)

Creates a face from the list of points passed in.

Parameters

Returns: FMEFace

init(face)

Create a copy of the passed in Face geometry object.

Parameters

Returns: FMEFace

Instance Methods [hide private]
 
__init__(MultipleInvocations)
x.__init__(...) initializes x; see help(type(x)) for signature
None
addInnerBoundaryCurve(innerBoundary, closeMode)
Adds an inner-boundary area to this face, represented by the specified curve.
None
addInnerBoundarySimpleArea(innerBoundary, closeMode)
Adds an inner-boundary area to this face.
FMEArea of a terminal type.
getAsArea()
Returns the face as an area.
FMEArea of a terminal type.
getAsAreaInLocalCoordinates()
Returns the face as an area in local coordinates.
tuple of 3 floats
getNormal()
Returns the normal vector of this face, normalized to the unit length.
list of lists of floats
getTransformationMatrix()
Gets this face's transformation matrix.
bool
hasTransformationMatrix()
This method determines if the face has a transformation matrix or not.
bool
isConvex()
Determines if face is convex.
None
removeTransformationMatrix()
Removes this face's transformation matrix.
None
setArea(area, closeMode)
Sets the area of this face.
None
setAreaInLocalCoordinates(area, closeMode)
Sets the area of this face.
None
setTransformationMatrix(matrix)
Sets this face's transformation matrix, replacing the existing matrix if it exists.

Inherited from FMESimpleSurface: numParts

Inherited from FMESurface: __decIterRef__, __incIterRef__, __iter__, deleteSide, getAppearanceReference, getAsWireFrame, isInPlane, isOriented, isPlanar, offset, orient, reorient, reverse, rotate2D, scale, setAppearanceReference, sideExists

Inherited from FMEGeometry: __getObject__, __new__, boundingBox, boundingCube, bounds, clearMeasures, copyAttributesFromFeature, copyNameFromGeometry, copyTraitsFromGeometry, copyTraitsToFeature, deleteName, force2D, force3D, getArea, getMeasureNames, getName, getTrait, getTraitNames, getTraitNullMissingAndType, getTraitType, hasMeasures, hasName, is3D, isCollection, measureExists, removeMeasure, removeTraits, renameMeasure, setName, setTrait, setTraitNullWithType

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(MultipleInvocations)
(Constructor)

 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__

addInnerBoundaryCurve(innerBoundary, closeMode)

 

Adds an inner-boundary area to this face, represented by the specified curve. Refer to setArea() for the usage of the parameter closeMode. If None is passed in, this face will not be modified.

Parameters:
Returns: None

addInnerBoundarySimpleArea(innerBoundary, closeMode)

 

Adds an inner-boundary area to this face. represented by the specified simple area. Refer to setArea() for the usage of the parameter closeMode. If None is passed in, this face will not be modified.

Parameters:
Returns: None

getAsArea()

 

Returns the face as an area.

Returns: FMEArea of a terminal type.
The face as a FMEArea object. Note: This method returns a terminal geometry type of the FMEArea; i.e. one of the leaf classes in the FMEArea inheritance graph. For example, a FMEPolygon is returned if the geometry truly is a polygon.

getAsAreaInLocalCoordinates()

 

Returns the face as an area in local coordinates.

Returns: FMEArea of a terminal type.
The face as a FMEArea object. Note: This method returns a terminal geometry type of the FMEArea; i.e. one of the leaf classes in the FMEArea inheritance graph. For example, a FMEPolygon is returned if the geometry truly is a polygon.

getNormal()

 

Returns the normal vector of this face, normalized to the unit length. The returned vector is computed using Newell's method on the vertices contained on the outer boundary of this face. If the face is a single point, then a zero vector will be returned.

Returns: tuple of 3 floats
The normal vector of this face.

getTransformationMatrix()

 

Gets this face's transformation matrix. If the face does not have such a matrix, an identity matrix is returned. Only the top three rows of the matrix will be returned, as the bottom row is always [ 0 0 0 1 ].

Returns: list of lists of floats
The face's tranformation matrix, formatted [[dddd][dddd][dddd]].

hasTransformationMatrix()

 

This method determines if the face has a transformation matrix or not.

Returns: bool
Returns True if this face has a transformation matrix, and False otherwise.

isConvex()

 

Determines if face is convex. The polygon making up the area is convex if all internal angles are less than 180 degrees and it's not self-intersecting. Imperfectly planar 3D polygons are tolerated.

Returns: bool
Returns True if this face is convex, and False otherwise.

setArea(area, closeMode)

 

Sets the area of this face. The existing area will be replaced and the transformation matrix will be reset.The parameter closeMode specifies how this face treates areas that are not closed in 3D.

  • If FME_CLOSE_3D_AVERAGE_MODE is specified, an additional point is added, connecting the start and end points of the area. This point is computed by the average of the start and end points, in 3D.
  • If FME_CLOSE_3D_EXTEND_MODE is specified, the start and end points are connected with no additional points.
  • If FME_CLOSE_3D_EXTEND_OR_AVERAGE_Z_MODE, we use the AVERAGE mode if and only if the start and end points lie on the same coordinate plane (i.e. they share the same x-, y-, or z-coordinates).
  • Otherwise, the EXTEND mode is used.
  • If the input area is None, then an error will be generated.
Parameters:
Returns: None

setAreaInLocalCoordinates(area, closeMode)

 

Sets the area of this face. the transformation matrix untouched.Refer to setArea() for the usage of the parameter closeMode.

Parameters:
Returns: None

setTransformationMatrix(matrix)

 

Sets this face's transformation matrix, replacing the existing matrix if it exists. Only three rows are expected in the input array, as a bottom row of [ 0 0 0 1 ] is assumed.

Parameters:
  • matrix (list of lists of floats) - The transformation matrix, formatted [[dddd][dddd][dddd]].
Returns: None