1 #ifndef ITKVTKCOLORTRANSFERFUNCTION_H
2 #define ITKVTKCOLORTRANSFERFUNCTION_H
5 #include <itkProcessObject.h>
7 #include <vtkColorTransferFunction.h>
9 #include <itkRGBToLuminanceImageFilter.h>
10 #include <itkImageRegionConstIterator.h>
14 template< class TypeImage>
15 class VTKColorTransferFunction :
21 /** Standard class typedefs. */
22 typedef VTKColorTransferFunction Self;
24 /** Standard "Superclass" typedef */
25 typedef ProcessObject Superclass;
27 /** Smart pointer typedef support. */
28 typedef SmartPointer<Self> Pointer;
29 typedef SmartPointer<const Self> ConstPointer;
31 /** Method for creation through the object factory. */
34 /** Run-time type information (and related methods). */
35 itkTypeMacro( VTKColorTransferFunction, ProcessObject );
37 /** InputImageType typedef support. */
38 typedef TypeImage InputImageType;
39 typedef typename InputImageType::Pointer InputImagePointerType;
40 typedef typename InputImageType::PixelType PixelType;
41 typedef typename InputImageType::IndexType IndexType;
45 * set the rgb image to create the transfer function
47 itkSetMacro(Input, InputImagePointerType)
49 * set the rgb image to create the transfer function
51 itkGetConstMacro(Input, InputImagePointerType)
54 get the color transfer created from the image
56 itkGetMacro(Output, vtkColorTransferFunction*)
58 virtual void Update();
61 VTKColorTransferFunction();
62 ~VTKColorTransferFunction();
64 virtual void GenerateData ();
66 virtual void GenerateOutputInformation();
69 vtkColorTransferFunction* m_Output;
70 InputImagePointerType m_Input;
75 #ifndef ITK_MANUAL_INSTANTIATION
76 #include "itkvtkcolortransferfunction.txx"
79 #endif // ITKVTKCOLORTRANSFERFUNCTION_H