VTK
vtkAttributesErrorMetric.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAttributesErrorMetric.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
31 #ifndef vtkAttributesErrorMetric_h
32 #define vtkAttributesErrorMetric_h
33 
34 #include "vtkCommonDataModelModule.h" // For export macro
36 
38 class vtkGenericDataSet;
39 
40 class VTKCOMMONDATAMODEL_EXPORT vtkAttributesErrorMetric : public vtkGenericSubdivisionErrorMetric
41 {
42 public:
47  static vtkAttributesErrorMetric *New();
48 
50 
54  void PrintSelf(ostream& os, vtkIndent indent) override;
56 
58 
66  vtkGetMacro(AbsoluteAttributeTolerance, double);
68 
79  void SetAbsoluteAttributeTolerance(double value);
80 
82 
90  vtkGetMacro(AttributeTolerance, double);
92 
98  void SetAttributeTolerance(double value);
99 
119  int RequiresEdgeSubdivision(double *leftPoint, double *midPoint, double *rightPoint,
120  double alpha) override;
121 
135  double GetError(double *leftPoint, double *midPoint,
136  double *rightPoint, double alpha) override;
137 
138 protected:
140  ~vtkAttributesErrorMetric() override;
141 
146  void ComputeSquareAbsoluteAttributeTolerance();
147 
149 
150  double SquareAbsoluteAttributeTolerance; // cached value computed from
151  // AttributeTolerance and active attribute/component
152 
155 
157 
158  double Range; // cached value computed from active attribute/component
159 
161 
162 private:
164  void operator=(const vtkAttributesErrorMetric&) = delete;
165 };
166 
167 #endif
168 
vtkGenericAttributeCollection * AttributeCollection
record modification and/or execution time
Definition: vtkTimeStamp.h:35
void PrintSelf(ostream &os, vtkIndent indent) override
Standard VTK type and error macros.
virtual int RequiresEdgeSubdivision(double *leftPoint, double *midPoint, double *rightPoint, double alpha)=0
Does the edge need to be subdivided according to the implemented computation? The edge is defined by ...
Objects that compute attribute-based error during cell tessellation.
a simple class to control print indentation
Definition: vtkIndent.h:39
Objects that compute error during cell tessellation.
virtual double GetError(double *leftPoint, double *midPoint, double *rightPoint, double alpha)=0
Return the error at the mid-point.
vtkTimeStamp SquareAbsoluteAttributeToleranceComputeTime
defines dataset interface
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...