3D Human Airway Tree
Program generuje ludzkie drzewo oskrzelowe
Strona główna
Dodatkowe strony
Przestrzenie nazw
Klasy
Pliki
Lista plików
Składowe plików
src
ThirdParts
vtk
BooleanOperations
vtkImplicitPolyData.h
Idź do dokumentacji tego pliku.
1
/*=========================================================================
2
3
Program: Visualization Toolkit
4
Module: vtkImplicitPolyData.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
=========================================================================*/
15
// .NAME vtkImplicitPolyData
16
// .SECTION Description
17
//
18
// Implicit function that computes the distance from a point x to the
19
// nearest point p on an input vtkPolyData. The sign of the function
20
// is set to the sign of the dot product between the angle-weighted
21
// pseudonormal at the nearest surface point and the vector x - p.
22
// Points interior to the geometry have a negative distance, points on
23
// the exterior have a positive distance, and points on the input
24
// vtkPolyData have a distance of zero. The gradient of the function
25
// is the angle-weighted pseudonormal at the nearest point.
26
//
27
// Baerentzen, J. A. and Aanaes, H. (2005). Signed distance
28
// computation using the angle weighted pseudonormal. IEEE
29
// Transactions on Visualization and Computer Graphics, 11:243-253.
30
//
31
// Written by Chris Weigle and Cory Quammen, The University of North
32
// Carolina at Chapel Hill.
33
34
#ifndef __vtkImplicitPolyData_h
35
#define __vtkImplicitPolyData_h
36
37
#include "vtkImplicitFunction.h"
38
39
40
class
vtkCellLocator;
41
class
vtkPolyData;
42
class
vtkTriangleFilter;
43
44
class
vtkImplicitPolyData
:
public
vtkImplicitFunction
45
{
46
public
:
47
static
vtkImplicitPolyData
*
New
();
48
vtkTypeMacro
(
vtkImplicitPolyData
,vtkImplicitFunction);
49
void
PrintSelf
(ostream& os, vtkIndent indent);
50
51
// Description:
52
// Return the MTime also considering the Input dependency.
53
unsigned
long
GetMTime
();
54
55
// Description:
56
// Evaluate plane equation of nearest triangle to point x[3].
57
double
EvaluateFunction
(
double
x[3]);
58
59
// Description:
60
// Evaluate function gradient of nearest triangle to point x[3].
61
void
EvaluateGradient
(
double
x[3],
double
g[3]);
62
63
// Description:
64
// Set the input vtkPolyData used for the implicit function
65
// evaluation. Passes input through an internal instance of
66
// vtkTriangleFilter to remove vertices and lines, leaving only
67
// triangular polygons for evaluation as implicit planes.
68
void
SetInput
(vtkPolyData *input);
69
70
// Description:
71
// Set/get the function value to use if no input vtkPolyData
72
// specified.
73
vtkSetMacro
(
NoValue
,
double
);
74
vtkGetMacro
(
NoValue
,
double
);
75
76
// Description:
77
// Set/get the function gradient to use if no input vtkPolyData
78
// specified.
79
vtkSetVector3Macro
(
NoGradient
,
double
);
80
vtkGetVector3Macro
(
NoGradient
,
double
);
81
82
// Description:
83
// Set/get the tolerance usued for the locator.
84
vtkGetMacro
(
Tolerance
,
double
);
85
vtkSetMacro
(
Tolerance
,
double
);
86
87
protected
:
88
vtkImplicitPolyData
();
89
~vtkImplicitPolyData
();
90
91
double
NoValue
;
92
double
NoGradient
[3];
93
double
Tolerance
;
94
95
double
SharedEvaluate
(
double
x[3],
double
n[3] );
96
97
private
:
98
vtkImplicitPolyData
(
const
vtkImplicitPolyData
&);
// Not implemented.
99
void
operator=(
const
vtkImplicitPolyData
&);
// Not implemented.
100
101
vtkTriangleFilter *TriangleFilter;
102
vtkPolyData *Input;
103
vtkCellLocator *Locator;
104
105
};
106
107
#endif
Wygenerowano przez
1.8.1