ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkVideoToVideoFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkVideoToVideoFilter_h
19 #define itkVideoToVideoFilter_h
20 
21 #include "itkVideoSource.h"
22 #include "itkVideoStream.h"
23 
24 namespace itk
25 {
26 
43 template< typename TInputVideoStream, typename TOutputVideoStream >
44 class ITK_TEMPLATE_EXPORT VideoToVideoFilter : public VideoSource< TOutputVideoStream >
45 {
46 public:
47 
49  typedef TInputVideoStream InputVideoStreamType;
50  typedef TOutputVideoStream OutputVideoStreamType;
57 
59  typedef typename Superclass::OutputFrameType OutputFrameType;
60  typedef typename Superclass::OutputFrameSpatialRegionType OutputFrameSpatialRegionType;
61 
63  typedef typename InputVideoStreamType::FrameType InputFrameType;
64  typedef typename InputVideoStreamType::SpatialRegionType InputFrameSpatialRegionType;
66  typedef typename InputVideoStreamType::PixelType InputFramePixelType;
68  typedef typename InputVideoStreamType::SpacingType InputFrameSpacingType;
71 
72  itkNewMacro(Self);
73 
75  itkTypeMacro(VideoToVideoFilter, VideoSource);
76 
78  using Superclass::SetInput;
79  virtual void SetInput( const InputVideoStreamType* videoStream);
80 
81  virtual void SetInput( unsigned int idx, const InputVideoStreamType* videoStream);
82 
84  const InputVideoStreamType* GetInput() const;
85 
86  const InputVideoStreamType* GetInput(unsigned int idx) const;
87 
94  virtual void UpdateOutputInformation() ITK_OVERRIDE;
95 
96 protected:
97 
101  InputVideoStreamType* GetInput();
102 
103  InputVideoStreamType* GetInput(unsigned int idx);
104 
109  virtual void GenerateOutputRequestedRegion(DataObject* output) ITK_OVERRIDE;
110 
116  virtual void GenerateInputRequestedRegion() ITK_OVERRIDE;
117 
121  virtual void BeforeTemporalStreamingGenerateData() ITK_OVERRIDE;
122 
124  virtual ~VideoToVideoFilter() ITK_OVERRIDE;
125 
126  virtual void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
127 
128 private:
129 
130  ITK_DISALLOW_COPY_AND_ASSIGN(VideoToVideoFilter);
131 
132 }; // end class VideoToVideoFilter
133 
134 } // end namespace itk
135 
136 #ifndef ITK_MANUAL_INSTANTIATION
137 #include "itkVideoToVideoFilter.hxx"
138 #endif
139 
140 #endif
SmartPointer< const Self > ConstPointer
Light weight base class for most itk classes.
VideoToVideoFilter< InputVideoStreamType, OutputVideoStreamType > Self
VideoSource< OutputVideoStreamType > Superclass
SmartPointer< Self > Pointer
Superclass::OutputFrameType OutputFrameType
Implements a weak reference to an object.
A TemporalProcessObject that produces a VideoStream.
InputVideoStreamType::PointType InputFramePointType
InputVideoStreamType::PixelType InputFramePixelType
TOutputVideoStream OutputVideoStreamType
InputVideoStreamType::IndexType InputFrameIndexType
Base class for filters that use a VideoStream as input and output.
InputVideoStreamType::DirectionType InputFrameDirectionType
Superclass::OutputFrameSpatialRegionType OutputFrameSpatialRegionType
InputVideoStreamType::SizeType InputFrameSizeType
InputVideoStreamType::FrameType InputFrameType
Control indentation during Print() invocation.
Definition: itkIndent.h:49
InputVideoStreamType::SpacingType InputFrameSpacingType
Base class for all data objects in ITK.
WeakPointer< const Self > ConstWeakPointer
InputVideoStreamType::SpatialRegionType InputFrameSpatialRegionType
TInputVideoStream InputVideoStreamType