ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkVTKImageExport.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 itkVTKImageExport_h
19 #define itkVTKImageExport_h
20 
21 #include "itkVTKImageExportBase.h"
22 #include "itkConceptChecking.h"
23 
24 namespace itk
25 {
53 template< typename TInputImage >
54 class ITK_TEMPLATE_EXPORT VTKImageExport:public VTKImageExportBase
55 {
56 public:
62  itkStaticConstMacro(InputImageDimension, unsigned int,
63  TInputImage::ImageDimension);
64 
66  itkTypeMacro(VTKImageExport, VTKImageExportBase);
67 
69  itkNewMacro(Self);
70 
72  typedef TInputImage InputImageType;
73 
74 #ifdef ITK_USE_CONCEPT_CHECKING
75  itkConceptMacro( ImageDimensionCheck,
77  3,itkGetStaticConstMacro(InputImageDimension) > ) );
78 #endif
79 
80  using Superclass::SetInput;
81  void SetInput(const InputImageType *);
82  InputImageType * GetInput();
84 
85 protected:
88  void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
89 
90  typedef typename InputImageType::Pointer InputImagePointer;
91  typedef typename InputImageType::RegionType InputRegionType;
94 
95  int * WholeExtentCallback() ITK_OVERRIDE;
96 
97  double * SpacingCallback() ITK_OVERRIDE;
98 
99  double * OriginCallback() ITK_OVERRIDE;
100 
101  float * FloatSpacingCallback() ITK_OVERRIDE;
102 
103  float * FloatOriginCallback() ITK_OVERRIDE;
104 
105  const char * ScalarTypeCallback() ITK_OVERRIDE;
106 
107  int NumberOfComponentsCallback() ITK_OVERRIDE;
108 
109  void PropagateUpdateExtentCallback(int *) ITK_OVERRIDE;
110 
111  int * DataExtentCallback() ITK_OVERRIDE;
112 
113  void * BufferPointerCallback() ITK_OVERRIDE;
114 
115 private:
116  ITK_DISALLOW_COPY_AND_ASSIGN(VTKImageExport);
117 
118  std::string m_ScalarTypeName;
119  int m_WholeExtent[6];
120  int m_DataExtent[6];
121  double m_DataSpacing[3];
122  double m_DataOrigin[3];
123  float m_FloatDataSpacing[3];
124  float m_FloatDataOrigin[3];
125 };
126 } // end namespace itk
127 
128 #ifndef ITK_MANUAL_INSTANTIATION
129 #include "itkVTKImageExport.hxx"
130 #endif
131 
132 #endif
Connect the end of an ITK image pipeline to a VTK pipeline.
Light weight base class for most itk classes.
InputRegionType::SizeType InputSizeType
TInputImage InputImageType
SmartPointer< Self > Pointer
InputRegionType::IndexType InputIndexType
InputImageType::Pointer InputImagePointer
Superclass for VTKImageExport instantiations.
VTKImageExportBase Superclass
InputImageType::RegionType InputRegionType
SmartPointer< const Self > ConstPointer
Control indentation during Print() invocation.
Definition: itkIndent.h:49
#define itkConceptMacro(name, concept)