Commit 9e94ac25 authored by Pierre Kraemer's avatar Pierre Kraemer

move traversors & mapImpl files + create Algo/Topo/basic.h

parent 6b5d560c
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
#include "Algo/Render/GL2/topo3Render.h" #include "Algo/Render/GL2/topo3Render.h"
#include "Algo/Render/SVG/mapSVGRender.h" #include "Algo/Render/SVG/mapSVGRender.h"
#include "Topology/generic/traversorFactory.h" #include "Topology/generic/traversor/traversorFactory.h"
#include "Algo/Render/GL2/drawerCells.h" #include "Algo/Render/GL2/drawerCells.h"
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
#include "Algo/Geometry/area.h" #include "Algo/Geometry/area.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include <cmath> #include <cmath>
#include <sstream> #include <sstream>
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
#include "Algo/Render/SVG/mapSVGRender.h" #include "Algo/Render/SVG/mapSVGRender.h"
#include "Algo/Import/import.h" #include "Algo/Import/import.h"
#include "Topology/generic/traversorFactory.h" #include "Topology/generic/traversor/traversorFactory.h"
MAP myMap; MAP myMap;
VertexAttribute<VEC3, MAP_IMPL> position ; VertexAttribute<VEC3, MAP_IMPL> position ;
......
...@@ -3,6 +3,8 @@ ...@@ -3,6 +3,8 @@
#include "Algo/Geometry/normal.h" #include "Algo/Geometry/normal.h"
#include "Algo/Geometry/laplacian.h" #include "Algo/Geometry/laplacian.h"
#include "Algo/Topo/basic.h"
#include <QKeyEvent> #include <QKeyEvent>
#include <QMouseEvent> #include <QMouseEvent>
...@@ -62,7 +64,7 @@ void MapParameters::start(MapHandlerGen* mhg) ...@@ -62,7 +64,7 @@ void MapParameters::start(MapHandlerGen* mhg)
for(unsigned int i = vertexRotationMatrix.begin(); i != vertexRotationMatrix.end(); vertexRotationMatrix.next(i)) for(unsigned int i = vertexRotationMatrix.begin(); i != vertexRotationMatrix.end(); vertexRotationMatrix.next(i))
vertexRotationMatrix[i] = Eigen::Matrix3f::Identity(); vertexRotationMatrix[i] = Eigen::Matrix3f::Identity();
nb_vertices = map->computeIndexCells<VERTEX>(vIndex); nb_vertices = Algo::Topo::computeIndexCells<VERTEX>(*map, vIndex);
if(nlContext) if(nlContext)
nlDeleteContext(nlContext); nlDeleteContext(nlContext);
...@@ -260,6 +262,7 @@ void Surface_Deformation_Plugin::mapRemoved(MapHandlerGen* map) ...@@ -260,6 +262,7 @@ void Surface_Deformation_Plugin::mapRemoved(MapHandlerGen* map)
void Surface_Deformation_Plugin::attributeAdded(unsigned int orbit, const QString& name) void Surface_Deformation_Plugin::attributeAdded(unsigned int orbit, const QString& name)
{ {
MapHandlerGen* map = static_cast<MapHandlerGen*>(QObject::sender()); MapHandlerGen* map = static_cast<MapHandlerGen*>(QObject::sender());
if(orbit == VERTEX && map->isSelectedMap()) if(orbit == VERTEX && map->isSelectedMap())
m_dockTab->addVertexAttribute(name); m_dockTab->addVertexAttribute(name);
} }
......
...@@ -17,6 +17,8 @@ ...@@ -17,6 +17,8 @@
#include "Algo/Render/GL2/mapRender.h" #include "Algo/Render/GL2/mapRender.h"
#include "Algo/Geometry/boundingbox.h" #include "Algo/Geometry/boundingbox.h"
#include "Algo/Topo/basic.h"
#include "Utils/vbo.h" #include "Utils/vbo.h"
namespace CGoGN namespace CGoGN
...@@ -80,6 +82,13 @@ public: ...@@ -80,6 +82,13 @@ public:
void setPrimitiveDirty(int primitive) { m_render->setPrimitiveDirty(primitive); } void setPrimitiveDirty(int primitive) { m_render->setPrimitiveDirty(primitive); }
/*********************************************************
* MANAGE TOPOLOGICAL QUERIES
*********************************************************/
virtual unsigned int getNbDarts() = 0;
virtual unsigned int getNbOrbits(unsigned int orbit) = 0;
/********************************************************* /*********************************************************
* MANAGE ATTRIBUTES * MANAGE ATTRIBUTES
*********************************************************/ *********************************************************/
...@@ -227,6 +236,13 @@ public: ...@@ -227,6 +236,13 @@ public:
inline MAP* getMap() { return static_cast<MAP*>(m_map); } inline MAP* getMap() { return static_cast<MAP*>(m_map); }
/*********************************************************
* MANAGE TOPOLOGICAL QUERIES
*********************************************************/
unsigned int getNbDarts();
unsigned int getNbOrbits(unsigned int orbit);
/********************************************************* /*********************************************************
* MANAGE ATTRIBUTES * MANAGE ATTRIBUTES
*********************************************************/ *********************************************************/
......
...@@ -22,6 +22,18 @@ inline QString MapHandlerGen::getAttributeTypeName(unsigned int orbit, const QSt ...@@ -22,6 +22,18 @@ inline QString MapHandlerGen::getAttributeTypeName(unsigned int orbit, const QSt
template <typename PFP>
unsigned int MapHandler<PFP>::getNbDarts()
{
return static_cast<MAP*>(m_map)->getNbDarts();
}
template <typename PFP>
unsigned int MapHandler<PFP>::getNbOrbits(unsigned int orbit)
{
return Algo::Topo::getNbOrbits(*static_cast<MAP*>(m_map), orbit);
}
template <typename PFP> template <typename PFP>
template <typename T, unsigned int ORBIT> template <typename T, unsigned int ORBIT>
AttributeHandler<T, ORBIT, typename PFP::MAP::IMPL> MapHandler<PFP>::getAttribute(const QString& nameAttr, bool onlyRegistered) const AttributeHandler<T, ORBIT, typename PFP::MAP::IMPL> MapHandler<PFP>::getAttribute(const QString& nameAttr, bool onlyRegistered) const
......
...@@ -221,19 +221,21 @@ void ControlDock_MapTab::removeSelector() ...@@ -221,19 +221,21 @@ void ControlDock_MapTab::removeSelector()
void ControlDock_MapTab::mapAdded(MapHandlerGen* m) void ControlDock_MapTab::mapAdded(MapHandlerGen* m)
{ {
b_updatingUI = true;
QListWidgetItem* item = new QListWidgetItem(m->getName(), list_maps); QListWidgetItem* item = new QListWidgetItem(m->getName(), list_maps);
b_updatingUI = true;
item->setCheckState(Qt::Unchecked); item->setCheckState(Qt::Unchecked);
b_updatingUI = false; b_updatingUI = false;
} }
void ControlDock_MapTab::mapRemoved(MapHandlerGen* m) void ControlDock_MapTab::mapRemoved(MapHandlerGen* m)
{ {
b_updatingUI = true; QList<QListWidgetItem*> items = list_maps->findItems(m->getName(), Qt::MatchExactly);
QList<QListWidgetItem*> items = list_maps->selectedItems();
if(!items.empty()) if(!items.empty())
{
b_updatingUI = true;
delete items[0]; delete items[0];
b_updatingUI = false; b_updatingUI = false;
}
} }
void ControlDock_MapTab::selectedViewChanged(View* prev, View* cur) void ControlDock_MapTab::selectedViewChanged(View* prev, View* cur)
...@@ -357,35 +359,35 @@ void ControlDock_MapTab::updateSelectedMapInfo() ...@@ -357,35 +359,35 @@ void ControlDock_MapTab::updateSelectedMapInfo()
switch(orbit) switch(orbit)
{ {
case DART : { case DART : {
unsigned int nb = m->getNbDarts(); unsigned int nb = m_selectedMap->getNbDarts();
label_dartNbOrbits->setText(QString::number(nb)); label_dartNbOrbits->setText(QString::number(nb));
label_dartNbCells->setText(QString::number(nbc)); label_dartNbCells->setText(QString::number(nbc));
selectorList = list_dartSelectors; selectorList = list_dartSelectors;
break; break;
} }
case VERTEX : { case VERTEX : {
unsigned int nb = m->getNbOrbits(VERTEX); unsigned int nb = m_selectedMap->getNbOrbits(VERTEX);
label_vertexNbOrbits->setText(QString::number(nb)); label_vertexNbOrbits->setText(QString::number(nb));
label_vertexNbCells->setText(QString::number(nbc)); label_vertexNbCells->setText(QString::number(nbc));
selectorList = list_vertexSelectors; selectorList = list_vertexSelectors;
break; break;
} }
case EDGE : { case EDGE : {
unsigned int nb = m->getNbOrbits(EDGE); unsigned int nb = m_selectedMap->getNbOrbits(EDGE);
label_edgeNbOrbits->setText(QString::number(nb)); label_edgeNbOrbits->setText(QString::number(nb));
label_edgeNbCells->setText(QString::number(nbc)); label_edgeNbCells->setText(QString::number(nbc));
selectorList = list_edgeSelectors; selectorList = list_edgeSelectors;
break; break;
} }
case FACE : { case FACE : {
unsigned int nb = m->getNbOrbits(FACE); unsigned int nb = m_selectedMap->getNbOrbits(FACE);
label_faceNbOrbits->setText(QString::number(nb)); label_faceNbOrbits->setText(QString::number(nb));
label_faceNbCells->setText(QString::number(nbc)); label_faceNbCells->setText(QString::number(nbc));
selectorList = list_faceSelectors; selectorList = list_faceSelectors;
break; break;
} }
case VOLUME : { case VOLUME : {
unsigned int nb = m->getNbOrbits(VOLUME); unsigned int nb = m_selectedMap->getNbOrbits(VOLUME);
label_volumeNbOrbits->setText(QString::number(nb)); label_volumeNbOrbits->setText(QString::number(nb));
label_volumeNbCells->setText(QString::number(nbc)); label_volumeNbCells->setText(QString::number(nbc));
selectorList = list_volumeSelectors; selectorList = list_volumeSelectors;
......
...@@ -229,7 +229,7 @@ void nlGetDoublev(NLenum pname, NLdouble* params) { ...@@ -229,7 +229,7 @@ void nlGetDoublev(NLenum pname, NLdouble* params) {
} }
} }
void nlGetIntergerv(NLenum pname, NLint* params) { void nlGetIntegerv(NLenum pname, NLint* params) {
switch(pname) { switch(pname) {
case NL_SOLVER: { case NL_SOLVER: {
*params = (NLint)(nlCurrentContext->solver) ; *params = (NLint)(nlCurrentContext->solver) ;
......
...@@ -72,13 +72,13 @@ NLuint nlSolve_CG() { ...@@ -72,13 +72,13 @@ NLuint nlSolve_CG() {
NLdouble *g = NL_NEW_ARRAY(NLdouble, N) ; NLdouble *g = NL_NEW_ARRAY(NLdouble, N) ;
NLdouble *r = NL_NEW_ARRAY(NLdouble, N) ; NLdouble *r = NL_NEW_ARRAY(NLdouble, N) ;
NLdouble *p = NL_NEW_ARRAY(NLdouble, N) ; NLdouble *p = NL_NEW_ARRAY(NLdouble, N) ;
NLuint its=0; NLuint its = 0;
NLint i; NLint i;
NLdouble t, tau, sig, rho, gam; NLdouble t, tau, sig, rho, gam;
NLdouble b_square=ddot(N,b,1,b,1); NLdouble b_square = ddot(N,b,1,b,1);
NLdouble err=eps*eps*b_square; NLdouble err = eps*eps*b_square;
NLdouble accu =0.0; NLdouble accu = 0.0;
NLdouble * Ax=NL_NEW_ARRAY(NLdouble,nlCurrentContext->n); NLdouble * Ax = NL_NEW_ARRAY(NLdouble,nlCurrentContext->n);
NLdouble curr_err; NLdouble curr_err;
nlCurrentContext->matrix_vector_prod(x,g); nlCurrentContext->matrix_vector_prod(x,g);
...@@ -86,9 +86,9 @@ NLuint nlSolve_CG() { ...@@ -86,9 +86,9 @@ NLuint nlSolve_CG() {
dscal(N,-1.,g,1); dscal(N,-1.,g,1);
dcopy(N,g,1,r,1); dcopy(N,g,1,r,1);
curr_err = ddot(N,g,1,g,1); curr_err = ddot(N,g,1,g,1);
while ( curr_err >err && its < max_iter) { while ( curr_err > err && its < max_iter) {
if(!(its % 100)) { if(!(its % 100)) {
printf ( "%d : %.10e -- %.10e\n", its, curr_err, err ) ; // printf ( "%d : %.10e -- %.10e\n", its, curr_err, err ) ;
} }
nlCurrentContext->matrix_vector_prod(r,p); nlCurrentContext->matrix_vector_prod(r,p);
rho=ddot(N,p,1,p,1); rho=ddot(N,p,1,p,1);
...@@ -101,12 +101,12 @@ NLuint nlSolve_CG() { ...@@ -101,12 +101,12 @@ NLuint nlSolve_CG() {
dscal(N,gam,r,1); dscal(N,gam,r,1);
daxpy(N,1.,g,1,r,1); daxpy(N,1.,g,1,r,1);
++its; ++its;
curr_err = ddot(N,g,1,g,1); curr_err = ddot(N,g,1,g,1);
} }
nlCurrentContext->matrix_vector_prod(x,Ax); nlCurrentContext->matrix_vector_prod(x,Ax);
for(i = 0 ; i < N ; ++i) for(i = 0 ; i < N ; ++i)
accu+=(Ax[i]-b[i])*(Ax[i]-b[i]); accu+=(Ax[i]-b[i])*(Ax[i]-b[i]);
printf("in OpenNL : ||Ax-b||/||b|| = %e\n",sqrt(accu)/sqrt(b_square)); // printf("in OpenNL : ||Ax-b||/||b|| = %e\n",sqrt(accu)/sqrt(b_square));
NL_DELETE_ARRAY(Ax); NL_DELETE_ARRAY(Ax);
NL_DELETE_ARRAY(g) ; NL_DELETE_ARRAY(g) ;
NL_DELETE_ARRAY(r) ; NL_DELETE_ARRAY(r) ;
......
...@@ -24,8 +24,8 @@ ...@@ -24,8 +24,8 @@
#include "Topology/generic/attributeHandler.h" #include "Topology/generic/attributeHandler.h"
#include "Topology/generic/autoAttributeHandler.h" #include "Topology/generic/autoAttributeHandler.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor2.h" #include "Topology/generic/traversor/traversor2.h"
#include "Topology/generic/cellmarker.h" #include "Topology/generic/cellmarker.h"
#include "Utils/compress.h" #include "Utils/compress.h"
......
...@@ -24,8 +24,8 @@ ...@@ -24,8 +24,8 @@
#include "Topology/generic/attributeHandler.h" #include "Topology/generic/attributeHandler.h"
#include "Topology/generic/autoAttributeHandler.h" #include "Topology/generic/autoAttributeHandler.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor2.h" #include "Topology/generic/traversor/traversor2.h"
#include "Topology/generic/cellmarker.h" #include "Topology/generic/cellmarker.h"
#include "Algo/Import/importFileTypes.h" #include "Algo/Import/importFileTypes.h"
......
...@@ -24,8 +24,8 @@ ...@@ -24,8 +24,8 @@
#include "Geometry/basic.h" #include "Geometry/basic.h"
#include "Algo/Geometry/centroid.h" #include "Algo/Geometry/centroid.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor2.h" #include "Topology/generic/traversor/traversor2.h"
namespace CGoGN namespace CGoGN
{ {
......
...@@ -28,8 +28,7 @@ ...@@ -28,8 +28,7 @@
#include "Geometry/basic.h" #include "Geometry/basic.h"
#include "Geometry/bounding_box.h" #include "Geometry/bounding_box.h"
#include "Topology/generic/attributeHandler.h" #include "Topology/generic/attributeHandler.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
namespace CGoGN namespace CGoGN
{ {
......
...@@ -22,11 +22,11 @@ ...@@ -22,11 +22,11 @@
* * * *
*******************************************************************************/ *******************************************************************************/
#include "Topology/generic/traversorCell.h"
#include "Topology/generic/traversor2.h"
#include "Topology/generic/cellmarker.h" #include "Topology/generic/cellmarker.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor3.h" #include "Topology/generic/traversor/traversor2.h"
#include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor/traversor3.h"
#include "Algo/Parallel/parallel_foreach.h" #include "Algo/Parallel/parallel_foreach.h"
namespace CGoGN namespace CGoGN
......
...@@ -24,9 +24,8 @@ ...@@ -24,9 +24,8 @@
#include "Algo/Geometry/localFrame.h" #include "Algo/Geometry/localFrame.h"
#include "Geometry/matrix.h" #include "Geometry/matrix.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor2.h" #include "Topology/generic/traversor/traversor2.h"
namespace CGoGN namespace CGoGN
{ {
......
...@@ -22,8 +22,8 @@ ...@@ -22,8 +22,8 @@
* * * *
*******************************************************************************/ *******************************************************************************/
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor2.h" #include "Topology/generic/traversor/traversor2.h"
#include "Algo/Geometry/basic.h" #include "Algo/Geometry/basic.h"
namespace CGoGN namespace CGoGN
......
...@@ -25,8 +25,8 @@ ...@@ -25,8 +25,8 @@
#include "Algo/Geometry/basic.h" #include "Algo/Geometry/basic.h"
#include "Algo/Geometry/area.h" #include "Algo/Geometry/area.h"
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Topology/generic/traversor2.h" #include "Topology/generic/traversor/traversor2.h"
#include "Algo/Parallel/parallel_foreach.h" #include "Algo/Parallel/parallel_foreach.h"
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
* * * *
*******************************************************************************/ *******************************************************************************/
#include "Topology/generic/traversorCell.h" #include "Topology/generic/traversor/traversorCell.h"
#include "Algo/Geometry/centroid.h" #include "Algo/Geometry/centroid.h"
#include "Algo/Modelisation/tetrahedralization.h" #include "Algo/Modelisation/tetrahedralization.h"
......
...@@ -26,6 +26,7 @@ ...@@ -26,6 +26,7 @@
#include "Topology/generic/autoAttributeHandler.h" #include "Topology/generic/autoAttributeHandler.h"
#include "Container/fakeAttribute.h" #include "Container/fakeAttribute.h"
#include "Algo/Modelisation/polyhedron.h" #include "Algo/Modelisation/polyhedron.h"
#include "Algo/Topo/basic.h"
namespace CGoGN namespace CGoGN
{ {
...@@ -147,7 +148,7 @@ bool importMesh(typename PFP::MAP& map, MeshTablesSurface<PFP>& mts) ...@@ -147,7 +148,7 @@ bool importMesh(typename PFP::MAP& map, MeshTablesSurface<PFP>& mts)
if (needBijectiveCheck) if (needBijectiveCheck)
{ {
// ensure bijection between topo and embedding // ensure bijection between topo and embedding
map.template bijectiveOrbitEmbedding<VERTEX>(); Algo::Topo::bijectiveOrbitEmbedding<VERTEX>(map);
} }
return true ; return true ;
......
...@@ -28,6 +28,7 @@ ...@@ -28,6 +28,7 @@
#include "NL/nl.h" #include "NL/nl.h"
#include "Algo/LinearSolving/variablesSetup.h" #include "Algo/LinearSolving/variablesSetup.h"
#include "Algo/LinearSolving/matrixSetup.h" #include "Algo/LinearSolving/matrixSetup.h"
#include "Algo/Topo/basic.h"
namespace CGoGN namespace CGoGN
{ {
...@@ -46,8 +47,14 @@ void setupVariables( ...@@ -46,8 +47,14 @@ void setupVariables(
const CellMarker<typename PFP::MAP, VERTEX>& fm, const CellMarker<typename PFP::MAP, VERTEX>& fm,
const VertexAttribute<ATTR_TYPE, typename PFP::MAP::IMPL>& attr) const VertexAttribute<ATTR_TYPE, typename PFP::MAP::IMPL>& attr)
{ {
// TraversorV<MAP> t(m);
// for (Dart d = t.begin(); d != t.end(); d = t.next())
// {
// }
FunctorMeshToSolver_Scalar<PFP, ATTR_TYPE> fmts(index, fm, attr) ; FunctorMeshToSolver_Scalar<PFP, ATTR_TYPE> fmts(index, fm, attr) ;
m.template foreach_orbit<VERTEX>(fmts) ; Algo::Topo::foreach_orbit<VERTEX>(m, fmts) ;
} }
template <typename PFP, typename ATTR_TYPE> template <typename PFP, typename ATTR_TYPE>
...@@ -59,7 +66,7 @@ void setupVariables( ...@@ -59,7 +66,7 @@ void setupVariables(
unsigned int coord) unsigned int coord)
{ {
FunctorMeshToSolver_Vector<PFP, ATTR_TYPE> fmts(index, fm, attr, coord) ; FunctorMeshToSolver_Vector<PFP, ATTR_TYPE> fmts(index, fm, attr, coord) ;
m.template foreach_orbit<VERTEX>(fmts) ; Algo::Topo::foreach_orbit<VERTEX>(m, fmts) ;
} }
/******************************************************************************* /*******************************************************************************
...@@ -75,7 +82,7 @@ void addRowsRHS_Equality( ...@@ -75,7 +82,7 @@ void addRowsRHS_Equality(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorEquality_PerVertexWeight_Scalar<PFP, ATTR_TYPE> feq(index, attr, weight) ; FunctorEquality_PerVertexWeight_Scalar<PFP, ATTR_TYPE> feq(index, attr, weight) ;
m.template foreach_orbit<VERTEX>(feq) ; Algo::Topo::foreach_orbit<VERTEX>(m, feq) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -88,7 +95,7 @@ void addRowsRHS_Equality( ...@@ -88,7 +95,7 @@ void addRowsRHS_Equality(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorEquality_UniformWeight_Scalar<PFP, ATTR_TYPE> feq(index, attr, weight) ; FunctorEquality_UniformWeight_Scalar<PFP, ATTR_TYPE> feq(index, attr, weight) ;
m.template foreach_orbit<VERTEX>(feq) ; Algo::Topo::foreach_orbit<VERTEX>(m, feq) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -102,7 +109,7 @@ void addRowsRHS_Equality( ...@@ -102,7 +109,7 @@ void addRowsRHS_Equality(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorEquality_PerVertexWeight_Vector<PFP, ATTR_TYPE> feq(index, attr, weight, coord) ; FunctorEquality_PerVertexWeight_Vector<PFP, ATTR_TYPE> feq(index, attr, weight, coord) ;
m.template foreach_orbit<VERTEX>(feq) ; Algo::Topo::foreach_orbit<VERTEX>(m, feq) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -116,7 +123,7 @@ void addRowsRHS_Equality( ...@@ -116,7 +123,7 @@ void addRowsRHS_Equality(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorEquality_UniformWeight_Vector<PFP, ATTR_TYPE> feq(index, attr, weight, coord) ; FunctorEquality_UniformWeight_Vector<PFP, ATTR_TYPE> feq(index, attr, weight, coord) ;
m.template foreach_orbit<VERTEX>(feq) ; Algo::Topo::foreach_orbit<VERTEX>(m, feq) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -131,7 +138,7 @@ void addRows_Laplacian_Topo( ...@@ -131,7 +138,7 @@ void addRows_Laplacian_Topo(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorLaplacianTopo<PFP> flt(m, index) ; FunctorLaplacianTopo<PFP> flt(m, index) ;
m.template foreach_orbit<VERTEX>(flt) ; Algo::Topo::foreach_orbit<VERTEX>(m, flt) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -143,7 +150,7 @@ void addRowsRHS_Laplacian_Topo( ...@@ -143,7 +150,7 @@ void addRowsRHS_Laplacian_Topo(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorLaplacianTopoRHS_Scalar<PFP, ATTR_TYPE> flt(m, index, attr) ; FunctorLaplacianTopoRHS_Scalar<PFP, ATTR_TYPE> flt(m, index, attr) ;
m.template foreach_orbit<VERTEX>(flt) ; Algo::Topo::foreach_orbit<VERTEX>(m, flt) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -156,7 +163,7 @@ void addRowsRHS_Laplacian_Topo( ...@@ -156,7 +163,7 @@ void addRowsRHS_Laplacian_Topo(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorLaplacianTopoRHS_Vector<PFP, ATTR_TYPE> flt(m, index, attr, coord) ; FunctorLaplacianTopoRHS_Vector<PFP, ATTR_TYPE> flt(m, index, attr, coord) ;
m.template foreach_orbit<VERTEX>(flt) ; Algo::Topo::foreach_orbit<VERTEX>(m, flt) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -173,7 +180,7 @@ void addRows_Laplacian_Cotan( ...@@ -173,7 +180,7 @@ void addRows_Laplacian_Cotan(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorLaplacianCotan<PFP> flc(m, index, edgeWeight, vertexArea) ; FunctorLaplacianCotan<PFP> flc(m, index, edgeWeight, vertexArea) ;
m.template foreach_orbit<VERTEX>(flc) ; Algo::Topo::foreach_orbit<VERTEX>(m, flc) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -187,7 +194,7 @@ void addRowsRHS_Laplacian_Cotan( ...@@ -187,7 +194,7 @@ void addRowsRHS_Laplacian_Cotan(
{ {
nlEnable(NL_NORMALIZE_ROWS) ; nlEnable(NL_NORMALIZE_ROWS) ;
FunctorLaplacianCotanRHS_Scalar<PFP, ATTR_TYPE> flc(m, index, edgeWeight, vertexArea, attr) ; FunctorLaplacianCotanRHS_Scalar<PFP, ATTR_TYPE> flc(m, index, edgeWeight, vertexArea, attr) ;
m.template foreach_orbit<VERTEX>(flc) ; Algo::Topo::foreach_orbit<VERTEX>(m, flc) ;
nlDisable(NL_NORMALIZE_ROWS) ; nlDisable(NL_NORMALIZE_ROWS) ;
} }
...@@ -202,7 +209,7 @@ void addRowsRHS_Laplacian_Cotan( ...@@ -202,7 +209,7 @@ void addRowsRHS_Laplacian_Cotan(
{ {