edu.stanford.rsl.konrad.pipeline
Class ParallelImageFilterSink

java.lang.Object
  extended by edu.stanford.rsl.konrad.pipeline.ParallelImageFilterSink
All Implemented Interfaces:
ProjectionSink, ProjectionSource, java.lang.Runnable

public class ParallelImageFilterSink
extends java.lang.Object
implements java.lang.Runnable, ProjectionSink, ProjectionSource


Constructor Summary
ParallelImageFilterSink()
           
 
Method Summary
 void close()
           
 int getCurrentProjectionNumber()
          Returns the current projection number
 java.lang.String getName()
           
 ij.process.ImageProcessor getNextProjection()
          Returns the next projection.
 void getNextProjection(IndividualImagePipelineFilteringTool tool)
          Writes the next projection into an IndividualImagePipelineFiltering tool, i.e.
 void process(ij.process.ImageProcessor projection, int projectionNumber)
           
 void run()
           
 void setDebug(boolean debug)
           
 void setPipeline(IndividualImageFilteringTool[] pipeline)
           
 void setShowStatus(boolean status)
           
 void setSink(ProjectionSink sink)
           
 void start(int cpus)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ParallelImageFilterSink

public ParallelImageFilterSink()
Method Detail

setShowStatus

public void setShowStatus(boolean status)
Specified by:
setShowStatus in interface ProjectionSink

setDebug

public void setDebug(boolean debug)

setPipeline

public void setPipeline(IndividualImageFilteringTool[] pipeline)

setSink

public void setSink(ProjectionSink sink)

close

public void close()
           throws java.lang.Exception
Specified by:
close in interface ProjectionSink
Throws:
java.lang.Exception

start

public void start(int cpus)

getName

public java.lang.String getName()
Specified by:
getName in interface ProjectionSink

process

public void process(ij.process.ImageProcessor projection,
                    int projectionNumber)
             throws java.lang.Exception
Specified by:
process in interface ProjectionSink
Throws:
java.lang.Exception

getCurrentProjectionNumber

public int getCurrentProjectionNumber()
Description copied from interface: ProjectionSource
Returns the current projection number

Specified by:
getCurrentProjectionNumber in interface ProjectionSource
Returns:
the number
See Also:
ProjectionSource.getNextProjection(), ProjectionSource.getNextProjection(IndividualImagePipelineFilteringTool tool)

getNextProjection

public void getNextProjection(IndividualImagePipelineFilteringTool tool)
Description copied from interface: ProjectionSource
Writes the next projection into an IndividualImagePipelineFiltering tool, i.e. reads the projection and sets the right projection number in a synchornized manner.

Specified by:
getNextProjection in interface ProjectionSource
Parameters:
tool - the tool to write to

getNextProjection

public ij.process.ImageProcessor getNextProjection()
Description copied from interface: ProjectionSource
Returns the next projection. Note that this call may be out of sync with getCurrentProjectionNumber()

Specified by:
getNextProjection in interface ProjectionSource
Returns:
the projection
See Also:
ProjectionSource.getCurrentProjectionNumber(), ProjectionSource.getNextProjection(IndividualImagePipelineFilteringTool tool)

run

public void run()
Specified by:
run in interface java.lang.Runnable