Class AbstractMovieImageSampler<T extends adams.data.image.AbstractImageContainer>
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.flow.transformer.movieimagesampler.AbstractMovieImageSampler<T>
-
- All Implemented Interfaces:
adams.core.Destroyable
,adams.core.GlobalInfoSupporter
,adams.core.logging.LoggingLevelHandler
,adams.core.logging.LoggingSupporter
,adams.core.option.OptionHandler
,adams.core.SizeOfHandler
,adams.core.Stoppable
,Serializable
- Direct Known Subclasses:
AbstractBufferedImageMovieImageSampler
public abstract class AbstractMovieImageSampler<T extends adams.data.image.AbstractImageContainer> extends adams.core.option.AbstractOptionHandler implements adams.core.Stoppable
Ancestor for classes that sample images from movies.- Version:
- $Revision$
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
m_Stopped
whether the sampler was stopped.
-
Constructor Summary
Constructors Constructor Description AbstractMovieImageSampler()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected void
check(File file)
Performs some checks on the movie file.protected abstract T[]
doSample(File file)
Samples images from a movie file.abstract Class
generates()
Returns the type of image container the sample generates.T[]
sample(File file)
Samples images from a movie file.void
stopExecution()
Stops the execution.-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, defineOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, globalInfo, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
-
-
-
Method Detail
-
generates
public abstract Class generates()
Returns the type of image container the sample generates.- Returns:
- the image container class
-
check
protected void check(File file)
Performs some checks on the movie file.
Default implementation only ensures that the file exists and is not a directory.- Parameters:
file
- the file to check
-
doSample
protected abstract T[] doSample(File file)
Samples images from a movie file.- Parameters:
file
- the movie to sample- Returns:
- the samples, null if failed to sample
-
sample
public T[] sample(File file)
Samples images from a movie file.- Parameters:
file
- the movie to sample- Returns:
- the samples, null if failed to sample
-
stopExecution
public void stopExecution()
Stops the execution.- Specified by:
stopExecution
in interfaceadams.core.Stoppable
-
-