Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

dox/Graphics/vtkThresholdPoints.h

Go to the documentation of this file.
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkThresholdPoints.h,v $ 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 =========================================================================*/ 00032 #ifndef __vtkThresholdPoints_h 00033 #define __vtkThresholdPoints_h 00034 00035 #include "vtkDataSetToPolyDataFilter.h" 00036 00037 class VTK_GRAPHICS_EXPORT vtkThresholdPoints : public vtkDataSetToPolyDataFilter 00038 { 00039 public: 00040 static vtkThresholdPoints *New(); 00041 vtkTypeRevisionMacro(vtkThresholdPoints,vtkDataSetToPolyDataFilter); 00042 void PrintSelf(ostream& os, vtkIndent indent); 00043 00046 void ThresholdByLower(double lower); 00047 00050 void ThresholdByUpper(double upper); 00051 00054 void ThresholdBetween(double lower, double upper); 00055 00057 00058 vtkGetMacro(UpperThreshold,double); 00059 vtkGetMacro(LowerThreshold,double); 00061 00062 protected: 00063 vtkThresholdPoints(); 00064 ~vtkThresholdPoints() {}; 00065 00066 // Usual data generation method 00067 void Execute(); 00068 00069 double LowerThreshold; 00070 double UpperThreshold; 00071 00072 //BTX 00073 int (vtkThresholdPoints::*ThresholdFunction)(double s); 00074 //ETX 00075 00076 int Lower(double s) {return ( s <= this->LowerThreshold ? 1 : 0 );}; 00077 int Upper(double s) {return ( s >= this->UpperThreshold ? 1 : 0 );}; 00078 int Between(double s) {return ( s >= this->LowerThreshold ? 00079 ( s <= this->UpperThreshold ? 1 : 0 ) : 0 );}; 00080 private: 00081 vtkThresholdPoints(const vtkThresholdPoints&); // Not implemented. 00082 void operator=(const vtkThresholdPoints&); // Not implemented. 00083 }; 00084 00085 #endif