JSci.instruments
Class TestImageSource

java.lang.Object
  extended by JSci.instruments.TestImageSource
All Implemented Interfaces:
java.lang.Runnable, Control, Dimensions, ImageSource

public class TestImageSource
extends java.lang.Object
implements ImageSource, java.lang.Runnable

An object that delivers sample frames


Field Summary
(package private)  java.awt.Dimension dim
           
 
Constructor Summary
TestImageSource()
           
 
Method Summary
 java.awt.Component getControlComponent()
           
 int getHeight()
           
 java.awt.Dimension getSize()
           
 int getWidth()
           
 void run()
           
 void setSink(ImageSink fs)
          set the object that must read the frames through receive() method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dim

java.awt.Dimension dim
Constructor Detail

TestImageSource

public TestImageSource()
Method Detail

setSink

public void setSink(ImageSink fs)
set the object that must read the frames through receive() method.

Specified by:
setSink in interface ImageSource
Parameters:
fs - the object that reads the frames

run

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

getWidth

public int getWidth()
Specified by:
getWidth in interface Dimensions
Returns:
the width of the image

getHeight

public int getHeight()
Specified by:
getHeight in interface Dimensions
Returns:
the height of the image

getSize

public java.awt.Dimension getSize()
Specified by:
getSize in interface Dimensions
Returns:
the dimension of the image

getControlComponent

public java.awt.Component getControlComponent()
Specified by:
getControlComponent in interface Control
Returns:
the component that controls the object that implements this interface