NASA World Wind

gov.nasa.worldwind.examples.util
Class IDWInterpolation

java.lang.Object
  extended by gov.nasa.worldwind.examples.util.IDWInterpolation

public class IDWInterpolation
extends Object

Utility class for filling in missing values in elevations. Uses Inverse Distance Weighted method for determining the elevation value of a missing value. Uses 8 neighboring cells: 4 cardinal directions and 4 diagnal If a neighboring cell is also missing an elevation value the algorithm extends up to the MAX_SEARCH_RADIUS in the same direction. Note: Currently only requires one neighbor to determine a value, should there be a requirement for number of neighbors with values?


Field Summary
static int MAX_NUM_NEIGHBORS
           
static int MIN_NUM_NEIGHBORS
           
 
Constructor Summary
IDWInterpolation(int min)
           
 
Method Summary
 void fillVoids(BufferWrapperRaster raster, double xPixelSize, double yPixelSize)
          Fill missing values in elevation rasters
 int getMinNumNeighbors()
           
 void setMinNumNeighbors(int min)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAX_NUM_NEIGHBORS

public static final int MAX_NUM_NEIGHBORS
See Also:
Constant Field Values

MIN_NUM_NEIGHBORS

public static final int MIN_NUM_NEIGHBORS
See Also:
Constant Field Values
Constructor Detail

IDWInterpolation

public IDWInterpolation(int min)
Method Detail

fillVoids

public void fillVoids(BufferWrapperRaster raster,
                      double xPixelSize,
                      double yPixelSize)
Fill missing values in elevation rasters

Parameters:
raster - elevation raster with missing values
xPixelSize - size of cell in X direction
yPixelSize - size of cell in Y direction

getMinNumNeighbors

public int getMinNumNeighbors()

setMinNumNeighbors

public void setMinNumNeighbors(int min)

NASA World Wind