Package net.sourceforge.jiu.geometry

# Class ResampleFilter

java.lang.Object
net.sourceforge.jiu.geometry.ResampleFilter

Direct Known Subclasses:
  `BellFilter`, `BoxFilter`, `BSplineFilter`, `HermiteFilter`, `Lanczos3Filter`, `MitchellFilter`, `TriangleFilter`

public abstract class ResampleFilter extends Object
Abstract base class for filters to be used with the `Resample` operation.

Since:
  0.10.0
Author:
  Marco Schmidt

## Field Summary

Fields
Modifier and Type
Field
Description
`private float`
`samplingRadius`

## Constructor Summary

Constructors
Constructor
Description
`ResampleFilter()`
This empty constructor sets the sampling radius to the recommended sampling radius as provided by `getRecommendedSamplingRadius()`.

## Method Summary

Modifier and Type
Method
Description
`abstract float`
`apply(float value)`
Returns the weight of the sample at the distance given by the argument value.
`abstract String`
`getName()`
Return the name of this filter.
`abstract float`
`getRecommendedSamplingRadius()`
Returns a recommendation for the sampling radius to be used with this filter.
`float`
`getSamplingRadius()`
Returns the sampling radius of this object.
`void`
`setSamplingRadius(float newValue)`
Sets the sampling radius to a new value.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### samplingRadius

private float samplingRadius

## Constructor Details

### ResampleFilter

public ResampleFilter()
This empty constructor sets the sampling radius to the recommended sampling radius as provided by `getRecommendedSamplingRadius()`.

## Method Details

### apply

public abstract float apply(float value)
Returns the weight of the sample at the distance given by the argument value.

### getName

public abstract String getName()
Return the name of this filter. Should avoid natural language words if possible.

Returns:
  String with filter name

### getRecommendedSamplingRadius

public abstract float getRecommendedSamplingRadius()
Returns a recommendation for the sampling radius to be used with this filter. This recommendation value will be the default value for the sampling radius of objects of this class. You can modify it with a call to `setSamplingRadius(float)`.

Returns:
  the recommended sampling radius to be used with this filter

### getSamplingRadius

public float getSamplingRadius()
Returns the sampling radius of this object.

See Also:
  - `getRecommendedSamplingRadius()`
  - `setSamplingRadius(float)`

### setSamplingRadius

public void setSamplingRadius(float newValue)
Sets the sampling radius to a new value. Call this method if you do not want to use the default radius as provided by `getRecommendedSamplingRadius()`.

Parameters:
  `newValue` - new sampling radius to be used with this object