Skip to content

Merge Gradient and UnstructuredGradient filters

Currently, there are two filters to compute the gradient of a dataset:

  • Gradient based on vtkImageGradient for vtkImageData only
  • Gradient Of Unstructured DataSet based on vtkGradientFilter for all vtkDataSet

This merge request replaces them with a unique Gradient filter based on vtkGradientFilter and including the functionalities from the former Gradient filter.

For vtkImageData objects, the default behavior uses the vtkImageGradient implementation, but it is possible to use the vtkGradientFilter implementation by selecting Forward/backward differencing for the gradient computation at the boundaries as shown below.

GradientImage

Closes #15232 (closed).

The merge request also includes a small fix in the enumeration domain of the ReplacementValueOption property of the previous Gradient Of Unstructured DataSet.

Edited by Tiffany Chhim

Merge request reports