edu.jhu.ece.iacl.jist.structures.image
Class VoxelMipav

java.lang.Object
  extended by java.lang.Number
      extended by edu.jhu.ece.iacl.jist.structures.image.Voxel
          extended by edu.jhu.ece.iacl.jist.structures.image.VoxelMipav
All Implemented Interfaces:
Indexable<Voxel>, java.io.Serializable, java.lang.Cloneable, java.lang.Comparable<Voxel>

public class VoxelMipav
extends Voxel
implements Indexable<Voxel>

An adapter for each element of ModelImage in Mipav so that data does not have to be copied to and from the Model Image class.

Author:
Blake Lucas
See Also:
Serialized Form

Field Summary
protected  VoxelType type
          The type.
protected  Voxel vox
          The vox.
 
Constructor Summary
VoxelMipav(int x, int y, int z, ModelStorageBase img, VoxelType type)
          Instantiates a new voxel mipav.
 
Method Summary
 Voxel add(Voxel v)
          Adds the.
 Voxel clone()
           
 int compareTo(Voxel arg0)
           
 Voxel div(Voxel v)
          Div.
 boolean getBoolean()
          Gets the boolean.
 int getChainIndex()
          Gets the chain index.
 java.awt.Color getColor()
          Gets the color.
 int getColumn()
          Gets the column.
 double getDouble()
          Gets the double.
 float getFloat()
          Gets the float.
 int getIndex()
          Get heap index.
 int getInt()
          Gets the int.
 int getRow()
          Gets the row.
 short getShort()
          Gets the short.
 int getSlice()
          Gets the slice.
 VoxelType getType()
          Gets the type.
 short getUByte()
          Gets the u byte.
 java.lang.Comparable getValue()
          Gets the value.
 Voxel mul(Voxel v)
          Mul.
 Voxel neg()
          Neg.
 void set(boolean vox)
          Sets the.
 void set(java.awt.Color vox)
          Sets the.
 void set(double vox)
          Sets the.
 void set(int vox)
          Sets the.
 void set(short vox)
          Sets the.
 void set(Voxel v)
          Sets the.
 void setChainIndex(int chainIndex)
          Sets the chain index.
 void setIndex(int index)
          Set index into heap.
 void setRefPosition(int i, int j, int k)
          Set position in volume.
 void setValue(java.lang.Comparable obj)
          Sets the value.
 Voxel sub(Voxel v)
          Sub.
 java.lang.String toString()
           
 
Methods inherited from class edu.jhu.ece.iacl.jist.structures.image.Voxel
byteValue, doubleValue, equals, floatValue, getRestriction, getVector, intValue, longValue, round, set, set, set, shortValue
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

type

protected VoxelType type
The type.


vox

protected Voxel vox
The vox.

Constructor Detail

VoxelMipav

public VoxelMipav(int x,
                  int y,
                  int z,
                  ModelStorageBase img,
                  VoxelType type)
Instantiates a new voxel mipav.

Parameters:
x - the x
y - the y
z - the z
img - the img
type - the type
Method Detail

getBoolean

public boolean getBoolean()
Description copied from class: Voxel
Gets the boolean.

Specified by:
getBoolean in class Voxel
Returns:
the boolean

getShort

public short getShort()
Description copied from class: Voxel
Gets the short.

Specified by:
getShort in class Voxel
Returns:
the short

getUByte

public short getUByte()
Description copied from class: Voxel
Gets the u byte.

Overrides:
getUByte in class Voxel
Returns:
the u byte

getFloat

public float getFloat()
Description copied from class: Voxel
Gets the float.

Overrides:
getFloat in class Voxel
Returns:
the float

getColor

public java.awt.Color getColor()
Description copied from class: Voxel
Gets the color.

Specified by:
getColor in class Voxel
Returns:
the color

getDouble

public double getDouble()
Description copied from class: Voxel
Gets the double.

Specified by:
getDouble in class Voxel
Returns:
the double

getInt

public int getInt()
Description copied from class: Voxel
Gets the int.

Specified by:
getInt in class Voxel
Returns:
the int

clone

public Voxel clone()
Specified by:
clone in class Voxel

set

public void set(Voxel v)
Description copied from class: Voxel
Sets the.

Specified by:
set in class Voxel
Parameters:
v - the v

set

public void set(boolean vox)
Description copied from class: Voxel
Sets the.

Specified by:
set in class Voxel
Parameters:
vox - the vox

set

public void set(short vox)
Description copied from class: Voxel
Sets the.

Specified by:
set in class Voxel
Parameters:
vox - the vox

set

public void set(int vox)
Description copied from class: Voxel
Sets the.

Specified by:
set in class Voxel
Parameters:
vox - the vox

set

public void set(java.awt.Color vox)
Description copied from class: Voxel
Sets the.

Specified by:
set in class Voxel
Parameters:
vox - the vox

set

public void set(double vox)
Description copied from class: Voxel
Sets the.

Specified by:
set in class Voxel
Parameters:
vox - the vox

add

public Voxel add(Voxel v)
Description copied from class: Voxel
Adds the.

Specified by:
add in class Voxel
Parameters:
v - the v
Returns:
the voxel

sub

public Voxel sub(Voxel v)
Description copied from class: Voxel
Sub.

Specified by:
sub in class Voxel
Parameters:
v - the v
Returns:
the voxel

mul

public Voxel mul(Voxel v)
Description copied from class: Voxel
Mul.

Specified by:
mul in class Voxel
Parameters:
v - the v
Returns:
the voxel

div

public Voxel div(Voxel v)
Description copied from class: Voxel
Div.

Specified by:
div in class Voxel
Parameters:
v - the v
Returns:
the voxel

neg

public Voxel neg()
Description copied from class: Voxel
Neg.

Specified by:
neg in class Voxel
Returns:
the voxel

toString

public java.lang.String toString()
Specified by:
toString in class Voxel

compareTo

public int compareTo(Voxel arg0)
Specified by:
compareTo in interface java.lang.Comparable<Voxel>

setRefPosition

public void setRefPosition(int i,
                           int j,
                           int k)
Description copied from interface: Indexable
Set position in volume.

Specified by:
setRefPosition in interface Indexable<Voxel>
Parameters:
i - row
j - column
k - slice

getRow

public int getRow()
Description copied from interface: Indexable
Gets the row.

Specified by:
getRow in interface Indexable<Voxel>
Returns:
the row

getColumn

public int getColumn()
Description copied from interface: Indexable
Gets the column.

Specified by:
getColumn in interface Indexable<Voxel>
Returns:
the column

getSlice

public int getSlice()
Description copied from interface: Indexable
Gets the slice.

Specified by:
getSlice in interface Indexable<Voxel>
Returns:
the slice

setIndex

public void setIndex(int index)
Description copied from interface: Indexable
Set index into heap.

Specified by:
setIndex in interface Indexable<Voxel>
Parameters:
index - the index

getIndex

public int getIndex()
Description copied from interface: Indexable
Get heap index.

Specified by:
getIndex in interface Indexable<Voxel>
Returns:
the index

getType

public VoxelType getType()
Description copied from class: Voxel
Gets the type.

Specified by:
getType in class Voxel
Returns:
the type

getChainIndex

public int getChainIndex()
Description copied from interface: Indexable
Gets the chain index.

Specified by:
getChainIndex in interface Indexable<Voxel>
Returns:
the chain index

setChainIndex

public void setChainIndex(int chainIndex)
Description copied from interface: Indexable
Sets the chain index.

Specified by:
setChainIndex in interface Indexable<Voxel>
Parameters:
chainIndex - the new chain index

getValue

public java.lang.Comparable getValue()
Description copied from interface: Indexable
Gets the value.

Specified by:
getValue in interface Indexable<Voxel>
Returns:
the value

setValue

public void setValue(java.lang.Comparable obj)
Description copied from interface: Indexable
Sets the value.

Specified by:
setValue in interface Indexable<Voxel>
Parameters:
obj - the new value