|
BIJ API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--VolumeJ.VJInterpolator | +--VolumeJ.VJNearestNeighbor
This class is the standard interpolator and implements nearest neighbor interpolation and interpolation of gradients. Copyright (c) 1999-2002, Michael Abramoff. All rights reserved.
Constructor Summary | |
VJNearestNeighbor()
|
Method Summary | |
protected static VJGradient |
gradient(byte[] v,
int height,
int width,
VJVoxelLoc vl)
Interpolate the gradient *xyz* in a byte volume. |
protected static VJGradient |
gradient(float[][][] v,
VJVoxelLoc vl)
Interpolate the gradient *xyz* in a float volume (central difference). |
protected static VJGradient |
gradient(short[][][] v,
VJVoxelLoc vl)
Interpolate the gradient *xyz* in a short volume (central difference). |
VJGradient |
gradient(Volume v,
VJVoxelLoc vl)
Compute an interpolated gradient from a volume. |
boolean |
isValid(VJVoxelLoc vl,
Volume v)
Does vl fall within the bounds of volume for a nearest neighbor interpolation? |
boolean |
isValidGradient(VJCell c,
Volume v)
Does cell c fall within the bounds of a volume for nearest neighbor gradient interpolation? |
boolean |
isValidGradient(VJVoxelLoc vl,
Volume v)
Does vl fall within the bounds of volume for nearest neighbor gradient interpolation? |
java.lang.String |
toString()
|
protected static float |
value(byte[] v,
int height,
int width,
VJVoxelLoc vl)
Interpolate in a byte volume organized as a single array. |
protected static float |
value(float[][][][] v,
int dimension,
VJVoxelLoc vl)
Interpolate in a float 4D hypervolume in a single dimension. |
protected static float |
value(float[][][][] v,
VJVoxelLoc vl,
int i)
Interpolate an entry in a float vector volume. |
protected static float |
value(float[][][] v,
VJVoxelLoc vl)
Interpolate in a float volume. |
protected static int |
value(short[][][] v,
VJVoxelLoc vl)
Interpolate in a short volume. |
VJValue |
value(VJValue voxel,
Volume v,
VJVoxelLoc vl)
Interpolate a volume. |
protected static float[] |
valueHS(float[] hs,
java.lang.Object[] sliceArray,
int width,
VJVoxelLoc vl)
Interpolate hue and saturation in an RGB int[][] volume organized as an array of slices. |
Methods inherited from class VolumeJ.VJInterpolator |
valueHS |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public VJNearestNeighbor()
Method Detail |
public boolean isValid(VJVoxelLoc vl, Volume v)
isValid
in class VJInterpolator
vl
- a VJVoxelLoc for which you want to know whether it falls inside the bounds,
taking account of support.v
- the volume to be interpolated.public boolean isValidGradient(VJVoxelLoc vl, Volume v)
isValidGradient
in class VJInterpolator
vl
- a VJVoxelLoc for which you want to know whether it falls inside the bounds,
taking account of support for the gradient kernel.v
- the volume to be interpolated.public boolean isValidGradient(VJCell c, Volume v)
isValidGradient
in class VJInterpolator
c
- a VJCell for which you want to know whether it falls inside the bounds,
taking account of support for the gradient kernel.v
- the volume to be interpolated.boolean
- whether or not c falls within the bounds.public VJValue value(VJValue voxel, Volume v, VJVoxelLoc vl)
value
in class VJInterpolator
voxel
- a VJValue which will contain the interpolated voxel value on exit.v
- a volumevl
- a location in the volume.public VJGradient gradient(Volume v, VJVoxelLoc vl)
gradient
in class VJInterpolator
v
- the volume.vl
- the VJVoxelLoc where to interpolate the gradientprotected static float value(float[][][][] v, VJVoxelLoc vl, int i)
v
- the vector volume in which to interpolatevl
- the location where to interpolate.i
- the entry in the vector to interpolate.protected static float value(float[][][] v, VJVoxelLoc vl)
v
- the volume in which to interpolatevl
- the location where to interpolate.protected static int value(short[][][] v, VJVoxelLoc vl)
v
- the volume in which to interpolatevl
- the location where to interpolate.protected static float value(byte[] v, int height, int width, VJVoxelLoc vl)
v
- the volume array in which to interpolateheight
- the height of the volume.width
- the width of the volume.vl
- the location where to interpolate.protected static float[] valueHS(float[] hs, java.lang.Object[] sliceArray, int width, VJVoxelLoc vl)
hs
- a float[2] that will contain the hue and saturation [0-1] on return.v
- the volume array in which to interpolatewidth
- the width of the volume.vl
- the location where to interpolate.protected static VJGradient gradient(short[][][] v, VJVoxelLoc vl)
v
- the volume in which to interpolatevl
- the location where to interpolate.protected static VJGradient gradient(float[][][] v, VJVoxelLoc vl)
v
- the volume in which to interpolatevl
- the location where to interpolate.protected static VJGradient gradient(byte[] v, int height, int width, VJVoxelLoc vl)
v
- the volume in which to interpolatevl
- the location where to interpolate.protected static float value(float[][][][] v, int dimension, VJVoxelLoc vl)
v
- the volume in which to interpolatedimension
- the dimension in which to interpolate.vl
- the location where to interpolate.public java.lang.String toString()
toString
in class VJInterpolator
|
BIJ API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |