514 |
s042372 |
1 |
/* ----------------------------------------------------------------------- *
|
572 |
jab |
2 |
* This file is part of GEL, http://www.imm.dtu.dk/GEL
|
|
|
3 |
* Copyright (C) the authors and DTU Informatics
|
|
|
4 |
* For license and list of authors, see ../../doc/intro.pdf
|
514 |
s042372 |
5 |
* ----------------------------------------------------------------------- */
|
|
|
6 |
|
|
|
7 |
#ifndef __MESHEDIT_CURVATURE_H__
|
|
|
8 |
#define __MESHEDIT_CURVATURE_H__
|
|
|
9 |
|
|
|
10 |
#include <vector>
|
|
|
11 |
|
518 |
s042372 |
12 |
#include "ItemID.h"
|
515 |
s042372 |
13 |
|
514 |
s042372 |
14 |
namespace CGLA
|
|
|
15 |
{
|
|
|
16 |
class Vec3d;
|
|
|
17 |
class Mat2x2d;
|
|
|
18 |
class Mat3x3d;
|
|
|
19 |
class Ma4x4d;
|
|
|
20 |
}
|
|
|
21 |
|
|
|
22 |
namespace HMesh
|
|
|
23 |
{
|
518 |
s042372 |
24 |
class Manifold;
|
|
|
25 |
template<typename ITEM>
|
|
|
26 |
class VertexAttributeVector;
|
|
|
27 |
|
514 |
s042372 |
28 |
double voronoi_area(const Manifold& m,
|
|
|
29 |
VertexID v);
|
|
|
30 |
|
|
|
31 |
double barycentric_area(const Manifold& m,
|
|
|
32 |
VertexID v);
|
|
|
33 |
|
|
|
34 |
void unnormalized_mean_curvature_normal(const Manifold& m,
|
|
|
35 |
VertexID v,
|
|
|
36 |
CGLA::Vec3d& curv_normal,
|
|
|
37 |
double& w_sum);
|
|
|
38 |
|
|
|
39 |
CGLA::Vec3d mean_curvature_normal( const Manifold& m,
|
|
|
40 |
VertexID v);
|
|
|
41 |
|
|
|
42 |
double sum_curvatures( const Manifold& m,
|
|
|
43 |
VertexAttributeVector<double>& curvature);
|
|
|
44 |
|
|
|
45 |
|
|
|
46 |
double gaussian_curvature_angle_defect( const Manifold& m,
|
|
|
47 |
VertexID v);
|
|
|
48 |
|
|
|
49 |
CGLA::Mat3x3d curvature_tensor( const Manifold& m,
|
|
|
50 |
HalfEdgeID h);
|
|
|
51 |
|
|
|
52 |
CGLA::Mat3x3d curvature_tensor_from_edge( const Manifold& m,
|
|
|
53 |
HalfEdgeID h);
|
|
|
54 |
|
|
|
55 |
|
|
|
56 |
void curvature_tensor_paraboloid( const Manifold& m,
|
|
|
57 |
VertexID v,
|
|
|
58 |
CGLA::Mat2x2d& curv_tensor,
|
|
|
59 |
CGLA::Mat3x3d& frame);
|
|
|
60 |
|
|
|
61 |
void curvature_tensors_from_edges( const Manifold& m,
|
|
|
62 |
VertexAttributeVector<CGLA::Mat3x3d>& curvature_tensors);
|
|
|
63 |
|
|
|
64 |
void smooth_curvature_tensors( const Manifold& m,
|
|
|
65 |
VertexAttributeVector<CGLA::Mat3x3d>& curvature_tensors);
|
|
|
66 |
|
|
|
67 |
void gaussian_curvature_angle_defects( const Manifold& m,
|
|
|
68 |
VertexAttributeVector<double>& curvature,
|
|
|
69 |
int smooth_steps=0);
|
|
|
70 |
|
|
|
71 |
void mean_curvatures( const Manifold& m,
|
|
|
72 |
VertexAttributeVector<double>& curvature,
|
|
|
73 |
int smooth_steps=0);
|
|
|
74 |
|
|
|
75 |
|
|
|
76 |
void curvature_paraboloids( const Manifold& m,
|
|
|
77 |
VertexAttributeVector<CGLA::Vec3d>& min_curv_direction,
|
|
|
78 |
VertexAttributeVector<CGLA::Vec3d>& max_curv_direction,
|
|
|
79 |
VertexAttributeVector<double>& curvature);
|
|
|
80 |
|
|
|
81 |
|
|
|
82 |
void curvature_from_tensors(const Manifold& m,
|
|
|
83 |
const VertexAttributeVector<CGLA::Mat3x3d>& curvature_tensors,
|
|
|
84 |
VertexAttributeVector<CGLA::Vec3d>& min_curv_direction,
|
|
|
85 |
VertexAttributeVector<CGLA::Vec3d>& max_curv_direction,
|
|
|
86 |
VertexAttributeVector<double>& curvature);
|
|
|
87 |
|
|
|
88 |
|
|
|
89 |
}
|
|
|
90 |
|
|
|
91 |
#endif
|