Subversion Repositories gelsvn

Rev

Rev 514 | Rev 518 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

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