VTK  9.3.20240425
vtkAttributesErrorMetric.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
19#ifndef vtkAttributesErrorMetric_h
20#define vtkAttributesErrorMetric_h
21
22#include "vtkCommonDataModelModule.h" // For export macro
24
25VTK_ABI_NAMESPACE_BEGIN
28
29class VTKCOMMONDATAMODEL_EXPORT vtkAttributesErrorMetric : public vtkGenericSubdivisionErrorMetric
30{
31public:
37
39
43 void PrintSelf(ostream& os, vtkIndent indent) override;
45
47
55 vtkGetMacro(AbsoluteAttributeTolerance, double);
57
69
71
79 vtkGetMacro(AttributeTolerance, double);
81
87 void SetAttributeTolerance(double value);
88
109 double* leftPoint, double* midPoint, double* rightPoint, double alpha) override;
110
124 double GetError(double* leftPoint, double* midPoint, double* rightPoint, double alpha) override;
125
126protected:
129
135
137
138 double SquareAbsoluteAttributeTolerance; // cached value computed from
139 // AttributeTolerance and active attribute/component
140
143
145
146 double Range; // cached value computed from active attribute/component
147
149
150private:
152 void operator=(const vtkAttributesErrorMetric&) = delete;
153};
154
155VTK_ABI_NAMESPACE_END
156#endif
Objects that compute attribute-based error during cell tessellation.
void SetAttributeTolerance(double value)
Set the relative attribute accuracy to ‘value’.
~vtkAttributesErrorMetric() override
double GetError(double *leftPoint, double *midPoint, double *rightPoint, double alpha) override
Return the error at the mid-point.
int RequiresEdgeSubdivision(double *leftPoint, double *midPoint, double *rightPoint, double alpha) override
Does the edge need to be subdivided according to the distance between the value of the active attribu...
vtkGenericAttributeCollection * AttributeCollection
static vtkAttributesErrorMetric * New()
Construct the error metric with a default relative attribute accuracy equal to 0.1.
void PrintSelf(ostream &os, vtkIndent indent) override
Standard VTK type and error macros.
void ComputeSquareAbsoluteAttributeTolerance()
Compute the square absolute attribute tolerance, only if the cached value is obsolete.
vtkTimeStamp SquareAbsoluteAttributeToleranceComputeTime
void SetAbsoluteAttributeTolerance(double value)
Set the absolute attribute accuracy to ‘value’.
defines dataset interface
Objects that compute error during cell tessellation.
a simple class to control print indentation
Definition vtkIndent.h:108
record modification and/or execution time