OSDN Git Service

FIRST REPOSITORY
[eos/hostdependOTHERS.git] / I386LINUX / util / I386LINUX / include / vtk / vtkKitwareContourFilter.h
1 /*=========================================================================
2
3   Program:   Visualization Toolkit
4   Module:    $RCSfile: vtkKitwareContourFilter.h,v $
5   Language:  C++
6   Date:      $Date: 2003/04/17 17:04:29 $
7   Version:   $Revision: 1.17.12.1 $
8
9   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen 
10   All rights reserved.
11   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
12
13      This software is distributed WITHOUT ANY WARRANTY; without even 
14      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
15      PURPOSE.  See the above copyright notice for more information.
16
17 =========================================================================*/
18 // .NAME vtkKitwareContourFilter - generate isosurfaces/isolines from scalar values
19 // .SECTION Description
20 // vtkKitwareContourFilter is a filter that takes as input any dataset and 
21 // generates on output isosurfaces and/or isolines. The exact form 
22 // of the output depends upon the dimensionality of the input data. 
23 // Data consisting of 3D cells will generate isosurfaces, data 
24 // consisting of 2D cells will generate isolines, and data with 1D 
25 // or 0D cells will generate isopoints. Combinations of output type 
26 // are possible if the input dimension is mixed.
27 //
28 // This filter will identify special dataset types (e.g., structured
29 // points) and use the appropriate specialized filter to process the
30 // data. For examples, if the input dataset type is a volume, this
31 // filter will create an internal vtkSyncronizedTemplates3D instance 
32 // and use it. This gives much better performance on StructuredPoints 
33 // and StructuredGrids.
34 // 
35 // To use this filter you must specify one or more contour values.
36 // You can either use the method SetValue() to specify each contour
37 // value, or use GenerateValues() to generate a series of evenly
38 // spaced contours. It is also possible to accelerate the operation of
39 // this filter (at the cost of extra memory) by using a
40 // vtkScalarTree. A scalar tree is used to quickly locate cells that
41 // contain a contour surface. This is especially effective if multiple
42 // contours are being extracted. If you want to use a scalar tree,
43 // invoke the method UseScalarTreeOn().
44
45 // .SECTION Caveats
46 // For StructuredPoints And StructuredGrids, normals are computed
47 // by default, but it is an expensive computation.  Processing for 
48 // other data set types has not been extended to include normal 
49 // computation.  In the mean time, use vtkPolyDataNormals to compute 
50 // the surface normals.
51
52 // .SECTION See Also
53 // vtkSynchronizedTemplates3D vtkSynchronizedTemplates2D 
54 // vtkGridSynchronizedTemplates3D
55
56 #ifndef __vtkKitwareContourFilter_h
57 #define __vtkKitwareContourFilter_h
58
59 #include "vtkContourFilter.h"
60
61 class VTK_PATENTED_EXPORT vtkKitwareContourFilter : public vtkContourFilter
62 {
63 public:
64   vtkTypeRevisionMacro(vtkKitwareContourFilter,vtkContourFilter);
65   void PrintSelf(ostream& os, vtkIndent indent);
66
67   // Description:
68   // Construct object with initial range (0,1) and single contour value
69   // of 0.0.
70   static vtkKitwareContourFilter *New();
71
72   // Description:
73   // Set/get which component of the scalar array to contour on; defaults to 0.
74   // Currently this feature only works if the input is a vtkImageData.
75   vtkSetMacro(ArrayComponent, int);
76   vtkGetMacro(ArrayComponent, int);
77
78 protected:
79   vtkKitwareContourFilter();
80   ~vtkKitwareContourFilter();
81
82   void ComputeInputUpdateExtents(vtkDataObject *data);
83   void Execute();
84   void ExecuteInformation();
85
86   //special contouring for structured points
87   void StructuredPointsContour(int dim); 
88   //special contouring for structured grid
89   void StructuredGridContour(int dim);
90   //default if not structured data
91   void DataSetContour();
92   
93   int ArrayComponent;
94   
95 private:
96   vtkKitwareContourFilter(const vtkKitwareContourFilter&);  // Not implemented.
97   void operator=(const vtkKitwareContourFilter&);  // Not implemented.
98 };
99
100 #endif
101
102