Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Thomas Pitiot
CGoGN
Commits
2959efd3
Commit
2959efd3
authored
Feb 02, 2011
by
CGoGN GIT Supervisor
Browse files
Merge branch 'master' of /home/kraemer/CGoGN
Conflicts: Apps/Examples/miniTest.cpp
parents
69eb1c3b
059b23c9
Changes
4
Hide whitespace changes
Inline
Side-by-side
Apps/Examples/miniTest.cpp
View file @
2959efd3
...
...
@@ -540,7 +540,6 @@ void MyGlutWin::myKeyboard(unsigned char keycode, int x, int y)
break
;
}
case
'v'
:
{
srand
(
time
(
NULL
))
;
...
...
@@ -554,6 +553,8 @@ void MyGlutWin::myKeyboard(unsigned char keycode, int x, int y)
updateVBOdata
(
Algo
::
Render
::
VBO
::
POSITIONS
|
Algo
::
Render
::
VBO
::
NORMALS
)
;
topo_render
->
updateData
<
PFP
>
(
myMap
,
position
,
0.9
f
,
0.9
f
)
;
}
glutPostRedisplay
()
;
break
;
}
case
'x'
:
...
...
include/Algo/ImplicitHierarchicalMesh/subdivision.hpp
View file @
2959efd3
...
...
@@ -160,7 +160,7 @@ void coarsenFace(typename PFP::MAP& map, Dart d, typename PFP::TVEC3& position)
do
{
map
.
setCurrentLevel
(
cur
+
1
)
;
map
.
remov
eVertex
(
map
.
phi1
(
map
.
phi1
(
fit
)))
;
map
.
delet
eVertex
(
map
.
phi1
(
map
.
phi1
(
fit
)))
;
map
.
setCurrentLevel
(
cur
)
;
fit
=
map
.
phi1
(
fit
)
;
}
while
(
fit
!=
d
)
;
...
...
include/Topology/gmap/gmap2.h
View file @
2959efd3
...
...
@@ -100,6 +100,13 @@ public:
*/
virtual
void
splitVertex
(
Dart
d
,
Dart
e
);
//! Delete the vertex of d (works only for internal vertices)
/*! All the faces around the vertex are merged into one face
* @param d a dart of the vertex to delete
* @return true if the deletion has been executed, false otherwise
*/
virtual
bool
deleteVertex
(
Dart
d
)
;
//! Cut the edge of d and its opposite edge if it exists
/*! @param d a dart of the edge to cut
*/
...
...
src/Topology/gmap/gmap2.cpp
View file @
2959efd3
...
...
@@ -56,6 +56,23 @@ void GMap2::splitVertex(Dart d, Dart e)
phi2sew
(
phi1
(
dd
),
phi1
(
ee
));
// Sew the two faces along the new edge
}
bool
GMap2
::
deleteVertex
(
Dart
d
)
{
if
(
isBoundaryVertex
(
d
))
return
false
;
Dart
vit
=
d
;
do
{
Dart
f
=
phi_1
(
phi2
(
vit
))
;
phi1sew
(
vit
,
f
)
;
vit
=
alpha1
(
vit
)
;
}
while
(
vit
!=
d
)
;
GMap1
::
deleteFace
(
d
)
;
return
true
;
}
void
GMap2
::
cutEdge
(
Dart
d
)
{
GMap1
::
cutEdge
(
d
);
// Cut the edge of d
...
...
@@ -396,7 +413,7 @@ bool GMap2::isBoundaryVertex(Dart d)
{
if
(
beta2
(
dNext
)
==
dNext
)
return
true
;
dNext
=
alpha1
(
d
)
;
dNext
=
alpha1
(
d
Next
)
;
}
while
(
dNext
!=
d
)
;
return
false
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment