Commit 3a4315bb authored by Kenneth Vanhoey's avatar Kenneth Vanhoey

Merge cgogn:~thery/CGoGN

parents 5087f653 2d8f863c
......@@ -78,8 +78,6 @@ void Viewer::cb_initGL()
{
Utils::GLSLShader::setCurrentOGLVersion(2) ;
setFocal(5.0f) ;
m_render = new Algo::Render::GL2::MapRender() ;
m_topoRender = new Algo::Render::GL2::TopoRender() ;
......@@ -109,7 +107,7 @@ void Viewer::cb_initGL()
m_simpleColorShader = new Utils::ShaderSimpleColor() ;
m_simpleColorShader->setAttributePosition(m_positionVBO) ;
Geom::Vec4f c(0.1f, 0.1f, 0.1f, 1.0f) ;
Geom::Vec4f c(0.0f, 0.0f, 0.0f, 1.0f) ;
m_simpleColorShader->setColor(c) ;
m_pointSprite = new Utils::PointSprite() ;
......@@ -294,6 +292,17 @@ void Viewer::slot_drawEdges(bool b)
void Viewer::slot_drawFaces(bool b)
{
m_drawFaces = b ;
if (b)
{
Geom::Vec4f c(0.0f, 0.0f, 0.0f, 1.0f) ;
m_simpleColorShader->setColor(c) ;
}
else
{
Geom::Vec4f c(0.9f, 0.9f, 0.1f, 1.0f) ;
m_simpleColorShader->setColor(c) ;
}
updateGL() ;
}
......
......@@ -24,7 +24,8 @@
#include <iostream>
#include "Utils/Qt/qtSimple.h"
//#include "Utils/Qt/qtSimple.h"
#include "Utils/Qt/qtQGLV.h"
#include "ui_viewer.h"
#include "Utils/Qt/qtui.h"
......@@ -65,7 +66,8 @@ struct PFP: public PFP_STANDARD
typedef PFP::MAP MAP ;
typedef PFP::VEC3 VEC3 ;
class Viewer : public Utils::QT::SimpleQT
//class Viewer : public Utils::QT::SimpleQT
class Viewer : public Utils::QT::SimpleQGLV
{
Q_OBJECT
......
......@@ -111,11 +111,15 @@ bool importMesh(typename PFP::MAP& map, MeshTablesSurface<PFP>& mts)
if (good_dart != NIL)
{
if ((d != map.phi2(d)) && (good_dart != map.phi2(good_dart)) )
if (good_dart == map.phi2(good_dart))
{
map.sewFaces(d, good_dart, false);
m.unmarkOrbit<EDGE>(d);
}
else
{
++nbBoundaryEdges;
}
}
else
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment