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
Sauvage
CGoGN
Commits
6144181d
Commit
6144181d
authored
Jan 24, 2013
by
Kenneth Vanhoey
Browse files
merge commit
parent
8058dafc
Changes
2
Hide whitespace changes
Inline
Side-by-side
include/Algo/Decimation/halfEdgeSelector.h
View file @
6144181d
...
...
@@ -463,9 +463,9 @@ public:
(
*
errors
)[
d
]
=
halfEdgeInfo
[
d
].
it
->
first
;
}
Dart
dd
=
this
->
m_map
.
phi2
(
d
)
;
if
(
halfEdgeInfo
[
dd
].
valid
&&
halfEdgeInfo
[
dd
].
it
->
first
<
(
*
errors
)[
d
])
if
(
halfEdgeInfo
[
dd
].
valid
&&
halfEdgeInfo
[
dd
].
it
->
first
>
(
*
errors
)[
d
])
{
(
*
errors
)[
d
]
=
halfEdgeInfo
[
dd
].
it
->
first
;
(
*
errors
)[
d
d
]
=
halfEdgeInfo
[
dd
].
it
->
first
;
}
//m_avgColor[d] = VEC3(m_visualImportance[d]/6.,m_visualImportance[d]/6.,m_visualImportance[d]/6.) ;
}
...
...
include/Algo/Decimation/halfEdgeSelector.hpp
View file @
6144181d
...
...
@@ -293,7 +293,6 @@ bool HalfEdgeSelector_QEMextColor<PFP>::init()
{
assert
(
this
->
m_approximators
[
approxindex
]
->
getType
()
==
A_hQEM
||
this
->
m_approximators
[
approxindex
]
->
getType
()
==
A_hHalfCollapse
||
this
->
m_approximators
[
approxindex
]
->
getType
()
!=
A_Lightfield
||
!
"Approximator for selector (HalfEdgeSelector_QEMextColor) must be of a half-edge approximator"
)
;
bool
saved
=
false
;
...
...
@@ -1670,9 +1669,9 @@ void HalfEdgeSelector_LightfieldKCL<PFP>::computeHalfEdgeInfo(Dart d, HalfEdgeIn
// New position
const
VEC3
&
newPos
=
(
this
->
m_approx
[
m_approxindex_pos
]
->
getAttr
(
m_attrindex_pos
))[
d
]
;
// get newPos
const
REAL
geomErr
=
quadGeom
(
newPos
)
;
const
REAL
visualI
=
m_visualImportance
[
dd
]
;
const
REAL
lferr
=
computeLightfieldError
(
d
)
;
const
REAL
&
geomErr
=
quadGeom
(
newPos
)
;
const
REAL
&
visualI
=
m_visualImportance
[
dd
]
;
const
REAL
&
lferr
=
computeLightfieldError
(
d
)
;
//std::cout << lferr/geomErr << std::endl ;
const
REAL
&
err
=
...
...
@@ -1699,8 +1698,19 @@ typename PFP::REAL HalfEdgeSelector_LightfieldKCL<PFP>::computeLightfieldError(D
{
Dart
v1
=
this
->
m_map
.
phi1
(
v0
)
;
//return computeSquaredLightfieldDifference(v0,v1) ;
REAL
err
=
0
;
/*Traversor2VVaE<MAP> tv0(this->m_map,v0) ; // all vertices surrounding vertex v0
for (Dart vi = tv0.begin() ; vi != tv0.end() ; vi = tv0.next())
{
if (vi != v1)
{
err += computeSquaredLightfieldDifference(v1,vi) ;
}
}
return err ;
*/
// return computeSquaredLightfieldDifference(v0,v1) ;
Traversor2VVaE
<
MAP
>
tv
(
this
->
m_map
,
v1
)
;
// all vertices surrounding vertex v0
for
(
Dart
vi
=
tv
.
begin
()
;
vi
!=
tv
.
end
()
;
vi
=
tv
.
next
())
{
...
...
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