ITK
6.0.0
Insight Toolkit
|
#include <itkLightProcessObject.h>
LightProcessObject is the base class for all process objects (source, filters, mappers) in the Insight data processing pipeline.
LightProcessObject is an abstract object that specifies behavior and interface of visualization network process objects (sources, filters, mappers). Source objects are creators of visualization data; filters input, process, and output visualization data; and mappers transform data into another form (like rendering primitives or write data to a file).
A major role of LightProcessObject is to define the inputs and outputs of a filter. More than one input and/or output may exist for a given filter. Some classes (e.g., source objects or mapper objects) will not use inputs (the source) or outputs (mappers). In this case, the inputs or outputs is just ignored.
LightProcessObject invokes the following events: , Command::StartEvent, Command::EndEvent These are convenience events you can use for any purpose (e.g., debugging info, highlighting/notifying user interface, etc.) See Command and LightObject for information on using AddObserver.
Another event Command::ProgressEvent can be observed. Some filters invoke this event periodically during their execution (with the progress, parameter, the fraction of work done). The use is similar to that of StartEvent and EndEvent. Filters may also check their AbortGenerateData flag to determine whether to prematurely end their execution.
An important feature of subclasses of LightProcessObject is that it is possible to control the memory-management model (i.e., retain output versus delete output data). If enabled the ReleaseDataFlag enables the deletion of the output data once the downstream process object finishes processing the data (please see text).
Subclasses of LightProcessObject may override 4 of the methods of this class to control how a given filter may interact with the pipeline (dataflow). These methods are: GenerateOutputInformation(), EnlargeOutputRequestedRegion(), GenerateInputRequestedRegion(), and GenerateOutputRequestedRegion(). By overriding these methods, a filter can deviate from the base assumptions of the pipeline execution model.
Definition at line 72 of file itkLightProcessObject.h.
Public Types | |
using | ConstPointer = SmartPointer< const Self > |
using | Pointer = SmartPointer< Self > |
using | Self = LightProcessObject |
using | Superclass = Object |
Public Types inherited from itk::Object | |
using | ConstPointer = SmartPointer< const Self > |
using | Pointer = SmartPointer< Self > |
using | Self = Object |
using | Superclass = LightObject |
Public Types inherited from itk::LightObject | |
using | ConstPointer = SmartPointer< const Self > |
using | Pointer = SmartPointer< Self > |
using | Self = LightObject |
Public Member Functions | |
virtual void | AbortGenerateDataOn () |
virtual const bool & | GetAbortGenerateData () const |
const char * | GetNameOfClass () const override |
virtual void | SetAbortGenerateData (bool _arg) |
virtual void | UpdateOutputData () |
void | UpdateProgress (float amount) |
virtual void | SetProgress (float _arg) |
virtual const float & | GetProgress () const |
Public Member Functions inherited from itk::Object | |
unsigned long | AddObserver (const EventObject &event, Command *cmd) const |
unsigned long | AddObserver (const EventObject &event, std::function< void(const EventObject &)> function) const |
LightObject::Pointer | CreateAnother () const override |
virtual void | DebugOff () const |
virtual void | DebugOn () const |
Command * | GetCommand (unsigned long tag) |
bool | GetDebug () const |
MetaDataDictionary & | GetMetaDataDictionary () |
const MetaDataDictionary & | GetMetaDataDictionary () const |
virtual ModifiedTimeType | GetMTime () const |
const char * | GetNameOfClass () const override |
virtual const TimeStamp & | GetTimeStamp () const |
bool | HasObserver (const EventObject &event) const |
void | InvokeEvent (const EventObject &) |
void | InvokeEvent (const EventObject &) const |
virtual void | Modified () const |
void | Register () const override |
void | RemoveAllObservers () |
void | RemoveObserver (unsigned long tag) const |
void | SetDebug (bool debugFlag) const |
void | SetReferenceCount (int) override |
void | UnRegister () const noexcept override |
void | SetMetaDataDictionary (const MetaDataDictionary &rhs) |
void | SetMetaDataDictionary (MetaDataDictionary &&rrhs) |
virtual void | SetObjectName (std::string _arg) |
virtual const std::string & | GetObjectName () const |
Public Member Functions inherited from itk::LightObject | |
Pointer | Clone () const |
virtual Pointer | CreateAnother () const |
virtual void | Delete () |
virtual const char * | GetNameOfClass () const |
virtual int | GetReferenceCount () const |
void | Print (std::ostream &os, Indent indent=0) const |
virtual void | Register () const |
virtual void | SetReferenceCount (int) |
virtual void | UnRegister () const noexcept |
Static Public Member Functions | |
static Pointer | New () |
Static Public Member Functions inherited from itk::Object | |
static bool | GetGlobalWarningDisplay () |
static void | GlobalWarningDisplayOff () |
static void | GlobalWarningDisplayOn () |
static Pointer | New () |
static void | SetGlobalWarningDisplay (bool val) |
Static Public Member Functions inherited from itk::LightObject | |
static void | BreakOnError () |
static Pointer | New () |
Protected Member Functions | |
virtual void | GenerateData () |
LightProcessObject () | |
void | PrintSelf (std::ostream &os, Indent indent) const override |
~LightProcessObject () override | |
Protected Member Functions inherited from itk::Object | |
Object () | |
bool | PrintObservers (std::ostream &os, Indent indent) const |
void | PrintSelf (std::ostream &os, Indent indent) const override |
virtual void | SetTimeStamp (const TimeStamp &timeStamp) |
~Object () override | |
Protected Member Functions inherited from itk::LightObject | |
virtual LightObject::Pointer | InternalClone () const |
LightObject () | |
virtual void | PrintHeader (std::ostream &os, Indent indent) const |
virtual void | PrintSelf (std::ostream &os, Indent indent) const |
virtual void | PrintTrailer (std::ostream &os, Indent indent) const |
virtual | ~LightObject () |
Private Attributes | |
bool | m_AbortGenerateData {} |
float | m_Progress {} |
Additional Inherited Members | |
Protected Attributes inherited from itk::LightObject | |
std::atomic< int > | m_ReferenceCount {} |
using itk::LightProcessObject::ConstPointer = SmartPointer<const Self> |
Definition at line 81 of file itkLightProcessObject.h.
Definition at line 80 of file itkLightProcessObject.h.
Standard class type aliases.
Definition at line 78 of file itkLightProcessObject.h.
Definition at line 79 of file itkLightProcessObject.h.
|
protected |
|
overrideprotected |
|
virtual |
Turn on and off the AbortGenerateData flag.
|
inlineprotectedvirtual |
This method causes the filter to generate its output.
Reimplemented in itk::ImageClassifierBase< TInputImage, TClassifiedImage >, itk::ImageGaussianModelEstimator< TInputImage, TMembershipFunction, TTrainingImage >, itk::ImageKmeansModelEstimator< TInputImage, TMembershipFunction >, itk::ImageModelEstimatorBase< TInputImage, TMembershipFunction >, itk::LevelSetNeighborhoodExtractor< TLevelSet >, itk::ClassifierBase< TDataContainer >, and itk::ClassifierBase< TInputImage >.
Definition at line 130 of file itkLightProcessObject.h.
|
virtual |
Get the AbortGenerateData flag for the process object. Process objects may handle premature termination of execution in different ways.
|
overridevirtual |
Reimplemented from itk::LightObject.
Reimplemented in itk::BioRadImageIO, itk::BMPImageIO, itk::Bruker2dseqImageIO, itk::CSVArray2DFileReader< TData >, itk::CSVFileReaderBase, itk::CSVNumericObjectFileWriter< TValue, VRows, VColumns >, itk::GDCMImageIO, itk::GE4ImageIO, itk::GE5ImageIO, itk::GEAdwImageIO, itk::GiplImageIO, itk::HDF5ImageIO, itk::ImageIOBase, itk::StreamingImageIOBase, itk::IPLCommonImageIO, itk::JPEGImageIO, itk::LSMImageIO, itk::MeshIOBase, itk::BYUMeshIO, itk::FreeSurferAsciiMeshIO, itk::FreeSurferBinaryMeshIO, itk::GiftiMeshIO, itk::OBJMeshIO, itk::OFFMeshIO, itk::VTKPolyDataMeshIO, itk::MetaArrayReader, itk::MetaArrayWriter, itk::MetaImageIO, itk::MINCImageIO, itk::MRCImageIO, itk::NiftiImageIO, itk::NrrdImageIO, itk::PNGImageIO, itk::RawImageIO< TPixel, VImageDimension >, itk::SiemensVisionImageIO, itk::PolygonGroupSpatialObjectXMLFileReader, itk::PolygonGroupSpatialObjectXMLFileWriter, itk::StimulateImageIO, itk::TIFFImageIO, itk::TransformFileReaderTemplate< TParametersValueType >, itk::TransformFileWriterTemplate< TParametersValueType >, itk::TransformIOBaseTemplate< TParametersValueType >, itk::TransformIOBaseTemplate< ParametersValueType >, itk::HDF5TransformIOTemplate< TParametersValueType >, itk::TxtTransformIOTemplate< TParametersValueType >, itk::MatlabTransformIOTemplate< ParametersValueType >, itk::VTKImageIO, itk::VoxBoCUBImageIO, itk::ClassifierBase< TDataContainer >, itk::ClassifierBase< TInputImage >, itk::ImageClassifierBase< TInputImage, TClassifiedImage >, itk::ImageGaussianModelEstimator< TInputImage, TMembershipFunction, TTrainingImage >, itk::ImageKmeansModelEstimator< TInputImage, TMembershipFunction >, itk::ImageModelEstimatorBase< TInputImage, TMembershipFunction >, itk::LevelSetNeighborhoodExtractor< TLevelSet >, itk::LevelSetVelocityNeighborhoodExtractor< TLevelSet, TAuxValue, VAuxDimension >, itk::FileListVideoIO, and itk::VideoIOBase.
|
virtual |
Get the execution progress of a process object. The progress is a floating number between (0,1), 0 meaning no progress; 1 meaning the filter has completed execution.
|
static |
Method for creation through the object factory.
|
overrideprotectedvirtual |
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from itk::LightObject.
Reimplemented in itk::BioRadImageIO, itk::BMPImageIO, itk::Bruker2dseqImageIO, itk::CSVArray2DFileReader< TData >, itk::CSVFileReaderBase, itk::CSVNumericObjectFileWriter< TValue, VRows, VColumns >, itk::GDCMImageIO, itk::GiplImageIO, itk::HDF5ImageIO, itk::ImageIOBase, itk::StreamingImageIOBase, itk::IPLCommonImageIO, itk::JPEGImageIO, itk::JPEG2000ImageIO, itk::LSMImageIO, itk::MeshIOBase, itk::BYUMeshIO, itk::FreeSurferAsciiMeshIO, itk::FreeSurferBinaryMeshIO, itk::GiftiMeshIO, itk::OBJMeshIO, itk::OFFMeshIO, itk::VTKPolyDataMeshIO, itk::MetaArrayReader, itk::MetaArrayWriter, itk::MetaImageIO, itk::MINCImageIO, itk::MRCImageIO, itk::NiftiImageIO, itk::NrrdImageIO, itk::PNGImageIO, itk::RawImageIO< TPixel, VImageDimension >, itk::StimulateImageIO, itk::TIFFImageIO, itk::TransformFileReaderTemplate< TParametersValueType >, itk::TransformFileWriterTemplate< TParametersValueType >, itk::TransformIOBaseTemplate< TParametersValueType >, itk::TransformIOBaseTemplate< ParametersValueType >, itk::VTKImageIO, itk::XMLReaderBase, itk::VoxBoCUBImageIO, itk::ClassifierBase< TDataContainer >, itk::ClassifierBase< TInputImage >, itk::ImageClassifierBase< TInputImage, TClassifiedImage >, itk::ImageGaussianModelEstimator< TInputImage, TMembershipFunction, TTrainingImage >, itk::ImageKmeansModelEstimator< TInputImage, TMembershipFunction >, itk::ImageModelEstimatorBase< TInputImage, TMembershipFunction >, itk::LevelSetNeighborhoodExtractor< TLevelSet >, itk::LevelSetVelocityNeighborhoodExtractor< TLevelSet, TAuxValue, VAuxDimension >, itk::FileListVideoIO, and itk::VideoIOBase.
|
virtual |
Set the AbortGenerateData flag for the process object. Process objects may handle premature termination of execution in different ways.
|
virtual |
Set the execution progress of a process object. The progress is a floating number between (0,1), 0 meaning no progress; 1 meaning the filter has completed execution.
|
virtual |
Actually generate new output.
void itk::LightProcessObject::UpdateProgress | ( | float | amount | ) |
Update the progress of the process object. If a ProgressMethod exists, executes it. Then set the Progress ivar to amount. The parameter amount should range between (0,1).
|
private |
These support the progress method and aborting filter execution.
Definition at line 137 of file itkLightProcessObject.h.
|
private |
Definition at line 138 of file itkLightProcessObject.h.