ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkImageToRGBVTKImageFilter.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 
19 #ifndef itkImageToRGBVTKImageFilter_h
20 #define itkImageToRGBVTKImageFilter_h
21 
22 #include "itkProcessObject.h"
23 #include "vtkSmartPointer.h"
24 #include "vtkImageData.h"
25 
26 namespace itk
27 {
33 template< typename TInputImage >
34 class ITK_TEMPLATE_EXPORT ImageToRGBVTKImageFilter:public ProcessObject
35 {
36 public:
37  ITK_DISALLOW_COPY_AND_ASSIGN(ImageToRGBVTKImageFilter);
38 
44 
46  itkNewMacro(Self);
47 
50 
52  using InputImageType = TInputImage;
53  using InputImagePointer = typename InputImageType::ConstPointer;
55  using InputSpacingType = typename InputImageType::SpacingType;
57  using InputPixelType = typename InputImageType::PixelType;
59 
62  vtkSmartPointer< vtkImageData > GetOutput() const;
63 
65  using Superclass::SetInput;
66  void SetInput(const InputImageType *);
67 
69  void Update() override;
70 
71 protected:
73  ~ImageToRGBVTKImageFilter() override;
74 
75 private:
77  vtkSmartPointer< vtkImageData > m_Output;
78 };
79 } // end namespace itk
80 
81 #ifndef ITK_MANUAL_INSTANTIATION
82 #include "itkImageToRGBVTKImageFilter.hxx"
83 #endif
84 
85 #endif
Light weight base class for most itk classes.
typename InputImageType::IndexType InputIndexType
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
typename InputImageType::ConstPointer InputImagePointer
class ITK_FORWARD_EXPORT ProcessObject
Definition: itkDataObject.h:40
typename InputImageType::SizeType InputSizeType
typename InputImageType::RegionType InputRegionType
Converts an ITK image into a VTK image.
typename InputImageType::PixelType InputPixelType
typename InputImageType::SpacingType InputSpacingType
vtkSmartPointer< vtkImageData > m_Output