Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages

# vtkFiniteDifferenceGradientEstimator Class Reference

`#include <vtkFiniteDifferenceGradientEstimator.h>`

Inheritance diagram for vtkFiniteDifferenceGradientEstimator:

[legend]
Collaboration diagram for vtkFiniteDifferenceGradientEstimator:

[legend]
List of all members.

## Detailed Description

Use finite differences to estimate gradient.

Date:
  2002/08/22 18:39:30

Revision:
  1.19

vtkFiniteDifferenceGradientEstimator is a concrete subclass of vtkEncodedGradientEstimator that uses a central differences technique to estimate the gradient. The gradient at some sample location (x,y,z) would be estimated by:

nx = (f(x-dx,y,z) - f(x+dx,y,z)) / 2*dx; ny = (f(x,y-dy,z) - f(x,y+dy,z)) / 2*dy; nz = (f(x,y,z-dz) - f(x,y,z+dz)) / 2*dz;

This value is normalized to determine a unit direction vector and a magnitude. The normal is computed in voxel space, and dx = dy = dz = SampleSpacingInVoxels. A scaling factor is applied to convert this normal from voxel space to world coordinates.

See also:
  vtkEncodedGradientEstimator

Created by:
  - Avila, Lisa

CVS contributions (if > 5%):
  - Avila, Lisa (71%)
  - Martin, Ken (7%)
  - Lorensen, Bill (6%)

CVS logs (CVSweb):
  - .`h` (`/Rendering/vtkFiniteDifferenceGradientEstimator.h)`
  - .`cxx` (`/Rendering/vtkFiniteDifferenceGradientEstimator.cxx)`

Tests:
  vtkFiniteDifferenceGradientEstimator (Tests)

Definition at line 62 of file vtkFiniteDifferenceGradientEstimator.h.

## Public Types

typedef vtkEncodedGradientEstimator | Superclass

## Public Methods

virtual const char * | GetClassName ()
virtual int | IsA (const char *type)
void | PrintSelf (ostream &os, vtkIndent indent)
virtual void | SetSampleSpacingInVoxels (int)
virtual int | GetSampleSpacingInVoxels ()

## Static Public Methods

int | IsTypeOf (const char *type)
vtkFiniteDifferenceGradientEstimator * | SafeDownCast (vtkObject *o)
vtkFiniteDifferenceGradientEstimator * | New ()

## Public Attributes

int | SampleSpacingInVoxels

## Protected Methods

| vtkFiniteDifferenceGradientEstimator ()
| ~vtkFiniteDifferenceGradientEstimator ()
void | UpdateNormals (void)

## Member Typedef Documentation

typedef vtkEncodedGradientEstimator vtkFiniteDifferenceGradientEstimator::Superclass

| Reimplemented from vtkEncodedGradientEstimator. Definition at line 65 of file vtkFiniteDifferenceGradientEstimator.h.

## Constructor & Destructor Documentation

vtkFiniteDifferenceGradientEstimator::vtkFiniteDifferenceGradientEstimator | ( |  | ) | `[protected]`

vtkFiniteDifferenceGradientEstimator::~vtkFiniteDifferenceGradientEstimator | ( |  | ) | `[protected]`

## Member Function Documentation

virtual const char* vtkFiniteDifferenceGradientEstimator::GetClassName | ( |  | ) | `[virtual]`

| Reimplemented from vtkEncodedGradientEstimator.

int vtkFiniteDifferenceGradientEstimator::IsTypeOf | ( | const char * | type | ) | `[static]`

| Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h. Reimplemented from vtkEncodedGradientEstimator.

virtual int vtkFiniteDifferenceGradientEstimator::IsA | ( | const char * | type | ) | `[virtual]`

| Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h. Reimplemented from vtkEncodedGradientEstimator.

vtkFiniteDifferenceGradientEstimator* vtkFiniteDifferenceGradientEstimator::SafeDownCast | ( | vtkObject * | o | ) | `[static]`

| Reimplemented from vtkEncodedGradientEstimator.

void vtkFiniteDifferenceGradientEstimator::PrintSelf | ( | ostream & | os,
|  | vtkIndent | indent
| ) | `[virtual]`

| Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes. Reimplemented from vtkEncodedGradientEstimator.

vtkFiniteDifferenceGradientEstimator* vtkFiniteDifferenceGradientEstimator::New | ( |  | ) | `[static]`

| Construct a vtkFiniteDifferenceGradientEstimator with a SampleSpacingInVoxels of 1. Reimplemented from vtkObject.

virtual void vtkFiniteDifferenceGradientEstimator::SetSampleSpacingInVoxels | ( | int |  | ) | `[virtual]`

| Set/Get the spacing between samples for the finite differences method used to compute the normal. This spacing is in voxel units.

virtual int vtkFiniteDifferenceGradientEstimator::GetSampleSpacingInVoxels | ( |  | ) | `[virtual]`

| Set/Get the spacing between samples for the finite differences method used to compute the normal. This spacing is in voxel units.

void vtkFiniteDifferenceGradientEstimator::UpdateNormals | ( | void |  | ) | `[protected, virtual]`

| Recompute the encoded normals and gradient magnitudes. Implements vtkEncodedGradientEstimator.

## Member Data Documentation

int vtkFiniteDifferenceGradientEstimator::SampleSpacingInVoxels

| Definition at line 80 of file vtkFiniteDifferenceGradientEstimator.h.

The documentation for this class was generated from the following file:

- Rendering/vtkFiniteDifferenceGradientEstimator.h