Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
CGoGN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
CGoGN
CGoGN
Commits
721eb1c3
Commit
721eb1c3
authored
Dec 06, 2011
by
Thomas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
correction include pickable, correction check 3gmap
parent
68b2491a
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
34 additions
and
21 deletions
+34
-21
Apps/Examples/simpleGMap3.cpp
Apps/Examples/simpleGMap3.cpp
+5
-3
Apps/Examples/simpleGMap3.h
Apps/Examples/simpleGMap3.h
+1
-0
include/Algo/Modelisation/subdivision3.hpp
include/Algo/Modelisation/subdivision3.hpp
+0
-13
include/Algo/Render/GL2/topoRender.hpp
include/Algo/Render/GL2/topoRender.hpp
+1
-1
include/Utils/pickables.h
include/Utils/pickables.h
+2
-2
src/Topology/gmap/embeddedGMap3.cpp
src/Topology/gmap/embeddedGMap3.cpp
+24
-0
src/Utils/pickables.cpp
src/Utils/pickables.cpp
+1
-2
No files found.
Apps/Examples/simpleGMap3.cpp
View file @
721eb1c3
...
...
@@ -32,17 +32,19 @@
SimpleGMap3
::
SimpleGMap3
()
{
position
=
myMap
.
addAttribute
<
PFP
::
VEC3
>
(
VERTEX
,
"position"
);
normal
=
myMap
.
addAttribute
<
PFP
::
VEC3
>
(
VERTEX
,
"position"
);
normal
=
myMap
.
addAttribute
<
PFP
::
VEC3
>
(
VERTEX
,
"normal"
);
volume
=
myMap
.
addAttribute
<
PFP
::
VEC3
>
(
VOLUME
,
"volume"
);
Algo
::
Modelisation
::
Primitive3D
<
PFP
>
primCat
(
myMap
,
position
);
Dart
d
=
primCat
.
hexaGrid_topo
(
2
,
1
,
1
);
primCat
.
embedHexaGrid
(
1
,
1
,
1
);
Dart
d
=
primCat
.
hexaGrid_topo
(
3
,
1
,
1
);
primCat
.
embedHexaGrid
(
2
,
1
,
1
);
myMap
.
check
();
DartMarker
markOrient
(
myMap
);
std
::
vector
<
Dart
>
orient
;
FunctorStore
fs
(
orient
);
d
=
49
;
myMap
.
foreach_dart_of_oriented_volume
(
d
,
fs
);
for
(
std
::
vector
<
Dart
>::
iterator
it
=
orient
.
begin
()
;
it
!=
orient
.
end
()
;
++
it
)
...
...
Apps/Examples/simpleGMap3.h
View file @
721eb1c3
...
...
@@ -55,6 +55,7 @@ public:
PFP
::
TVEC3
position
;
PFP
::
TVEC3
normal
;
PFP
::
TVEC3
volume
;
SimpleGMap3
()
;
...
...
include/Algo/Modelisation/subdivision3.hpp
View file @
721eb1c3
...
...
@@ -113,7 +113,6 @@ void catmullClarkVol(typename PFP::MAP& map, EMBV& attributs, const FunctorSelec
//memorize each vertices per volumes
if
(
selected
(
d
)
&&
!
mv
.
isMarked
(
d
))
{
std
::
cout
<<
" d "
<<
d
<<
std
::
endl
;
l_vertices
.
push_back
(
d
);
mv
.
markOrbitInParent
<
typename
PFP
::
MAP
>
(
VERTEX
,
d
);
}
...
...
@@ -145,12 +144,6 @@ void catmullClarkVol(typename PFP::MAP& map, EMBV& attributs, const FunctorSelec
}
}
unsigned
int
nb_
=
0
;
for
(
unsigned
int
nb
=
attributs
.
begin
()
;
nb
!=
attributs
.
end
()
;
attributs
.
next
(
nb
))
nb_
++
;
std
::
cout
<<
"first "
<<
nb_
<<
std
::
endl
;
// second pass: quandrangule faces
std
::
map
<
Dart
,
Dart
>
toSew
;
for
(
Dart
d
=
map
.
begin
();
d
!=
map
.
end
();
map
.
next
(
d
))
...
...
@@ -230,12 +223,6 @@ void catmullClarkVol(typename PFP::MAP& map, EMBV& attributs, const FunctorSelec
}
}
nb_
=
0
;
for
(
unsigned
int
nb
=
attributs
.
begin
()
;
nb
!=
attributs
.
end
()
;
attributs
.
next
(
nb
))
nb_
++
;
std
::
cout
<<
"then "
<<
nb_
<<
std
::
endl
;
map
.
check
();
//sew all faces leading to the central vertex
...
...
include/Algo/Render/GL2/topoRender.hpp
View file @
721eb1c3
...
...
@@ -182,7 +182,7 @@ void TopoRenderMapD::updateData(typename PFP::MAP& map, const typename PFP::TVEC
template
<
typename
PFP
>
void
TopoRenderGMap
::
updateData
(
typename
PFP
::
MAP
&
map
,
const
typename
PFP
::
TVEC3
&
positions
,
float
ke
,
float
kf
,
const
FunctorSelect
&
good
)
{
/*
/*
typedef typename PFP::VEC3 VEC3;
typedef typename PFP::REAL REAL;
...
...
include/Utils/pickables.h
View file @
721eb1c3
...
...
@@ -24,7 +24,7 @@
#ifndef __PICKABLES_H_
#define __PICKABLE_H_
#define __PICKABLE
S
_H_
#include "Utils/vbo.h"
#include "glm/glm.hpp"
...
...
@@ -270,7 +270,7 @@ class Grid: public LineDrawable
public:
/**
* constructor
* @param sub number of subdivision of gri
g
* @param sub number of subdivision of gri
d
*/
Grid
(
unsigned
int
sub
=
5
);
...
...
src/Topology/gmap/embeddedGMap3.cpp
View file @
721eb1c3
...
...
@@ -477,6 +477,30 @@ bool EmbeddedGMap3::check()
}
}
if
(
isOrbitEmbedded
(
VERTEX
))
{
delete
dvMark
;
delete
vMark
;
}
if
(
isOrbitEmbedded
(
EDGE
))
{
delete
deMark
;
delete
eMark
;
}
if
(
isOrbitEmbedded
(
FACE
))
{
delete
dfMark
;
delete
fMark
;
}
if
(
isOrbitEmbedded
(
VOLUME
))
{
delete
dvolMark
;
delete
volMark
;
}
CGoGNout
<<
"Check: embedding ok"
<<
CGoGNendl
;
return
true
;
}
...
...
src/Utils/pickables.cpp
View file @
721eb1c3
...
...
@@ -134,7 +134,6 @@ glm::mat4& Pickable::transfo()
return
m_transfo
;
}
void
Pickable
::
rotate
(
float
angle
,
const
Geom
::
Vec3f
&
Axis
)
{
m_transfo
=
glm
::
rotate
(
m_transfo
,
angle
,
glm
::
vec3
(
Axis
[
0
],
Axis
[
1
],
Axis
[
2
]));
...
...
@@ -472,7 +471,7 @@ unsigned int Sphere::pick(const Geom::Vec3f& P, const Geom::Vec3f& V, Geom::Vec3
I
=
P
;
I
.
normalize
();
// grossiere approximation TODO amelio
e
rer approxim ?
I
.
normalize
();
// grossiere approximation TODO ameliorer approxim ?
return
1
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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