Rumba C++ SDK
Mesh.h
Go to the documentation of this file.
1
/*
2
3
*
4
***
5
*****
6
********************* Mercenaries Engineering SARL
7
***************** Copyright (C) 2018
8
*************
9
********* http://www.mercenaries-engineering.com
10
***********
11
**** ****
12
** **
13
14
*/
15
#pragma once
16
17
#include "
Points.h
"
18
#include "
SpanSpan.h
"
19
20
namespace
maquina
21
{
23
33
class
MAQUINA_EXPORT
Mesh
:
public
Points
34
{
35
public
:
37
Mesh
();
38
40
43
Mesh
(
44
const
BufferConstV3f
& points,
45
const
BufferConstUInt32
& indices,
46
const
BufferConstUInt32
& offsets
47
);
48
50
51
Mesh
(
const
Value
&v);
52
54
SpanSpan<const uint32_t, const uint32_t>
position_topology()
const
;
55
SpanSpan< const uint32_t, const uint32_t >
vertex_to_faces()
const
;
56
SpanSpan< const uint32_t, const uint32_t >
vertex_to_edges()
const
;
57
SpanSpan< const uint32_t, const uint32_t >
edges_to_faces()
const
;
58
SpanSpan< const uint32_t, const uint32_t >
adjacent_vertices()
const
;
59
61
66
Mesh
triangulate()
const
;
67
69
72
void
compute_triangle_indices(
BufferV3i
&result)
const
;
73
75
79
void
compute_triangle_face_varying_indices(
BufferV3i
&result)
const
;
80
82
87
int
closest_face(
const
Imath::V3f
&p,
88
float
&max_distance,
89
Imath::V3f
* closest_pos =
nullptr
90
)
const
;
91
93
94
Imath::V3f
normal(
95
int
face,
96
int
corner
97
)
const
;
98
100
Imath::V3f
smooth_normal(
int
vertex)
const
;
101
102
void
finalize();
103
105
static
const
Mesh
default_value
;
106
108
Mesh
(
const
std::shared_ptr<Impl>& impl) { _impl=impl; }
109
};
110
}
Imath::Vec3
Definition:
ImathFrame.h:42
maquina::Mesh
A mesh value.
Definition:
Mesh.h:33
maquina::BufferConst< Imath::V3f >
Points.h
maquina
This version of the SDK is unstable, i-e, it may change with no warning.
Definition:
AddCurveAction.h:20
MAQUINA_EXPORT
#define MAQUINA_EXPORT
Definition:
Export.h:31
maquina::Buffer< Imath::V3i >
SpanSpan.h
maquina::Mesh::default_value
static const Mesh default_value
The default value.
Definition:
Mesh.h:105
maquina::Points
A set of 3d points.
Definition:
Points.h:25
maquina::SpanSpan< const uint32_t, const uint32_t >
maquina::Value
Base class of all Rumba values.
Definition:
Value.h:34
maquina
include
Maquina
Mesh.h
Generated by
doxygen
1.8.14