pyvista.DataSetFilters.extract_feature_edges#

DataSetFilters.extract_feature_edges(feature_angle=30.0, boundary_edges=True, non_manifold_edges=True, feature_edges=True, manifold_edges=True, clear_data=False, progress_bar=False)[source]#

Extract edges from the surface of the mesh.

If the given mesh is not PolyData, the external surface of the given mesh is extracted and used.

From vtk documentation, the edges are one of the following:

  1. Boundary (used by one polygon) or a line cell.

  2. Non-manifold (used by three or more polygons).

  3. Feature edges (edges used by two triangles and whose dihedral angle > feature_angle).

  4. Manifold edges (edges used by exactly two polygons).

Parameters:
feature_anglefloat, default: 30.0

Feature angle (in degrees) used to detect sharp edges on the mesh. Used only when feature_edges=True.

boundary_edgesbool, default: True

Extract the boundary edges.

non_manifold_edgesbool, default: True

Extract non-manifold edges.

feature_edgesbool, default: True

Extract edges exceeding feature_angle.

manifold_edgesbool, default: True

Extract manifold edges.

clear_databool, default: False

Clear any point, cell, or field data. This is useful if wanting to strictly extract the edges.

progress_barbool, default: False

Display a progress bar to indicate progress.

Returns:
pyvista.PolyData

Extracted edges.

Examples

Extract the edges from an unstructured grid.

>>> import pyvista as pv
>>> from pyvista import examples
>>> hex_beam = pv.read(examples.hexbeamfile)
>>> feat_edges = hex_beam.extract_feature_edges()
>>> feat_edges.clear_data()  # clear array data for plotting
>>> feat_edges.plot(line_width=10)
../../../_images/pyvista-DataSetFilters-extract_feature_edges-1_00_00.png

See the Extract Edges for more examples using this filter.