VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkVolumeRayCastCompositeFunction.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00034 #ifndef __vtkVolumeRayCastCompositeFunction_h 00035 #define __vtkVolumeRayCastCompositeFunction_h 00036 00037 #include "vtkVolumeRayCastFunction.h" 00038 00039 #define VTK_COMPOSITE_CLASSIFY_FIRST 0 00040 #define VTK_COMPOSITE_INTERPOLATE_FIRST 1 00041 00042 class VTK_VOLUMERENDERING_EXPORT vtkVolumeRayCastCompositeFunction : public vtkVolumeRayCastFunction 00043 { 00044 public: 00045 static vtkVolumeRayCastCompositeFunction *New(); 00046 vtkTypeMacro(vtkVolumeRayCastCompositeFunction,vtkVolumeRayCastFunction); 00047 void PrintSelf( ostream& os, vtkIndent indent ); 00048 00050 00051 vtkSetClampMacro( CompositeMethod, int, 00052 VTK_COMPOSITE_CLASSIFY_FIRST, VTK_COMPOSITE_INTERPOLATE_FIRST ); 00053 vtkGetMacro(CompositeMethod,int); 00054 void SetCompositeMethodToInterpolateFirst() 00055 {this->SetCompositeMethod(VTK_COMPOSITE_INTERPOLATE_FIRST);} 00056 void SetCompositeMethodToClassifyFirst() 00057 {this->SetCompositeMethod(VTK_COMPOSITE_CLASSIFY_FIRST);} 00058 const char *GetCompositeMethodAsString(void); 00060 00061 //BTX 00062 void CastRay( vtkVolumeRayCastDynamicInfo *dynamicInfo, 00063 vtkVolumeRayCastStaticInfo *staticInfo); 00064 00065 float GetZeroOpacityThreshold( vtkVolume *vol ); 00066 //ETX 00067 00068 protected: 00069 vtkVolumeRayCastCompositeFunction(); 00070 ~vtkVolumeRayCastCompositeFunction(); 00071 00072 //BTX 00073 void SpecificFunctionInitialize( vtkRenderer *ren, 00074 vtkVolume *vol, 00075 vtkVolumeRayCastStaticInfo *staticInfo, 00076 vtkVolumeRayCastMapper *mapper ); 00077 //ETX 00078 00079 int CompositeMethod; 00080 private: 00081 vtkVolumeRayCastCompositeFunction(const vtkVolumeRayCastCompositeFunction&); // Not implemented. 00082 void operator=(const vtkVolumeRayCastCompositeFunction&); // Not implemented. 00083 }; 00084 00085 00086 #endif