BIJ API

VolumeJ
Class VJBinaryShell

java.lang.Object
  |
  +--volume.Volume
        |
        +--VolumeJ.VJBinaryShell
All Implemented Interfaces:
java.io.Serializable

public class VJBinaryShell
extends Volume

VJBInaryShell. For patenting and copyrighting reasons all Javadoc comments have been removed. This class implements a binary shell (created from a VJThresholdedVolume). Copyright (c) 2001-2003, Michael Abramoff. All rights reserved. Patent pending.

See Also:
Serialized Form

Field Summary
(package private)  java.lang.String s
           
 boolean[] v
          During instantiation, every cell (of 8 voxels) is checked to see whether this cell contains both a true and a false thresholded voxel.
 
Fields inherited from class volume.Volume
aspectx, aspecty, aspectz, depth, edge, height, width
 
Constructor Summary
VJBinaryShell()
           
VJBinaryShell(VJThresholdedVolume vt)
          Create a binary shell out of a a thresholded volume
 
Method Summary
 int advanceInit(VJCell cell, double ox, double oy, double oz)
          Initialization of depth search routine.
 void advancePrepare(double dx, double dy, double dz)
          Prepare surface search for a ray with a specific direction vector.
 int advanceToSurface(VJCell cell)
          Advance a cell to a surface along the ray.
 int advanceToSurfaceTracing(VJCell cell)
          Advance a cell to a surface along the ray.
 java.lang.Object get(int x, int y, int z)
          Get the shell value as a boolean.
 ij.ImageStack getImageStack()
          Make an ImageJ imagestack from this shell.
 void set(java.lang.Object value, int x, int y, int z)
          Set the shell value to a boolean value.
 boolean surface(int ix, int iy, int iz)
          Determine whether cell contains a surface.
 boolean surface(VJCell cell)
          Determine whether cell contains a surface.
 boolean surface(VJVoxelLoc vl)
          Determine whether there is a surface in the cell that vl is in.
 
Methods inherited from class volume.Volume
discreteSupport, getAspectx, getAspecty, getAspectz, getDepth, getEdge, getHeight, getWidth, in, setAspects, setEdge, toString, valid, valid
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

v

public boolean[] v
During instantiation, every cell (of 8 voxels) is checked to see whether this cell contains both a true and a false thresholded voxel. If so, it is part of the binary shell of an object. If not, it is not interesting. It is used as the shell volume input to a iso-surface renderer. Also implements methods to traverse the shell.

s

java.lang.String s
Constructor Detail

VJBinaryShell

public VJBinaryShell()

VJBinaryShell

public VJBinaryShell(VJThresholdedVolume vt)
Create a binary shell out of a a thresholded volume
Parameters:
vt - the thresholded volume to be processed
Method Detail

get

public java.lang.Object get(int x,
                            int y,
                            int z)
Get the shell value as a boolean.
Overrides:
get in class Volume
Parameters:
x - the x position of the voxel
y - the y position of the voxel
z - the z position of the voxel

set

public void set(java.lang.Object value,
                int x,
                int y,
                int z)
Set the shell value to a boolean value.
Overrides:
set in class Volume
Parameters:
value - a boolean
x - the x position of the voxel
y - the y position of the voxel
z - the z position of the voxel

surface

public boolean surface(VJVoxelLoc vl)
Determine whether there is a surface in the cell that vl is in.
Parameters:
x,y,z - the lowerleftanterior corner of the cell
Returns:
true if the cell corresponding to x,y,z is part of a surface, false if not.

surface

public boolean surface(VJCell cell)
Determine whether cell contains a surface.
Parameters:
cell - the cell to examine.
Returns:
true if the cell is part of a surface, false if not, or is not in the shell.

surface

public boolean surface(int ix,
                       int iy,
                       int iz)
Determine whether cell contains a surface.
Parameters:
cell - the cell to examine.
Returns:
true if the cell is part of a surface, false if not, or is not in the shell.

getImageStack

public ij.ImageStack getImageStack()
Make an ImageJ imagestack from this shell. For debugging purposes only.

advancePrepare

public void advancePrepare(double dx,
                           double dy,
                           double dz)
Prepare surface search for a ray with a specific direction vector. Highly factored out. Here you only know the direction of the ray.
Parameters:
dx, - dy, dz the vector orientation of the ray.

advanceInit

public int advanceInit(VJCell cell,
                       double ox,
                       double oy,
                       double oz)
Initialization of depth search routine. Here you know the starting point on the ray.
Parameters:
cell - the starting position of the cell.
ox, - oy, oz the origin (starting point) of the ray
Returns:
the number of cells to be traversed.

advanceToSurface

public int advanceToSurface(VJCell cell)
Advance a cell to a surface along the ray. See advanceInit() for details. At return the cell will be at a surface.
Parameters:
cell - the cell from which to proceed along the ray.
Returns:
the number of cells visited since the call to advanceInit, max if no cell containing a surface can be found anymore.

advanceToSurfaceTracing

public int advanceToSurfaceTracing(VJCell cell)
Advance a cell to a surface along the ray. Set string s to the trace of the cells visited.
Parameters:
cell - the cell from which to proceed along the ray.
Returns:
the number of cells visited since the call to advanceInit, max if no cell containing a surface can be found anymore.

BIJ API

Submit a bug or feature

Copyright (c) 1997-2003 Michael Abramoff
Licensing available. All Rights Reserved.