Commit 6d8c1419 by Sylvain Thery

Merge cgogn:~untereiner/CGoGN

parents 95cf4074 a119b8e3
 ... ... @@ -1115,9 +1115,9 @@ int main(int argc, char** argv) else { sqt.position = sqt.myMap.addAttribute("position"); Algo::Volume::Modelisation::Primitive3D prim(sqt.myMap, sqt.position); prim.hexaGrid_topo(10,10,10); prim.embedHexaGrid(1.0f,1.0f,1.0f); Algo::Volume::Tilings::Cubic::Grid cubic(sqt.myMap, 10,10,10); cubic.embedIntoGrid(sqt.position, 1.0f, 1.0f, 1.0f); } sqt.initGUI(); ... ...
 ... ... @@ -57,7 +57,7 @@ #include "Utils/cgognStream.h" #include "Utils/drawer.h" #include "Algo/Modelisation/primitives3d.h" #include "Algo/Tiling/Volume/cubic.h" #include #include ... ...
 ... ... @@ -26,6 +26,7 @@ #include "Utils/GLSLShader.h" #include "Algo/Geometry/boundingbox.h" #include "Algo/Modelisation/polyhedron.h" #include "Algo/Tiling/Surface/square.h" SimpleGMap2::SimpleGMap2() { ... ... @@ -41,11 +42,9 @@ SimpleGMap2::SimpleGMap2() myMap.cutEdge(d); position[myMap.phi1(d)] = mid; Algo::Surface::Modelisation::Polyhedron poly(myMap, position); d = poly.cylinder_topo(5, 1, false, false); poly.embedCylinder(10, 10, 5); Algo::Surface::Tilings::Square::Cylinder poly(myMap, 5 ,1, false, false); d = poly.getDart(); poly.embedIntoCylinder(position, 10, 10, 5); d = myMap.phi1(d); Dart dd = myMap.beta2(d); ... ...
 ... ... @@ -25,7 +25,7 @@ #include "simpleGMap3.h" #include "Utils/GLSLShader.h" #include "Algo/Geometry/boundingbox.h" #include "Algo/Modelisation/primitives3d.h" #include "Algo/Tiling/Volume/cubic.h" #include "Algo/Modelisation/subdivision3.h" SimpleGMap3::SimpleGMap3() ... ... @@ -35,22 +35,21 @@ SimpleGMap3::SimpleGMap3() // CellMarker mE(myMap); Algo::Volume::Modelisation::Primitive3D primCat(myMap,position); Dart d = primCat.hexaGrid_topo(1,1,1); primCat.embedHexaGrid(1,1,1); Algo::Volume::Tilings::Cubic::Grid cubic(myMap, 1, 1, 1); cubic.embedIntoGrid(position, 1.0f, 1.0f, 1.0f); myMap.check(); Dart dp = Algo::Surface::Modelisation::createQuadrangularPyramid(myMap); // Dart dp = Algo::Surface::Modelisation::createQuadrangularPyramid(myMap); position[dp] = typename PFP::VEC3(0.5,0.5,-0.5); position[myMap.phi1(dp)] = typename PFP::VEC3(0.5,0.5,0.5); position[myMap.phi1(myMap.phi1(dp))] = typename PFP::VEC3(0.5,-0.5,0.5); position[myMap.phi_1(dp)] = typename PFP::VEC3(0.5,-0.5,-0.5); position[myMap.phi_1(myMap.phi2(dp))] = typename PFP::VEC3(1.5f, 0.0f, 0.0f); // position[dp] = typename PFP::VEC3(0.5,0.5,-0.5); // position[myMap.phi1(dp)] = typename PFP::VEC3(0.5,0.5,0.5); // position[myMap.phi1(myMap.phi1(dp))] = typename PFP::VEC3(0.5,-0.5,0.5); // position[myMap.phi_1(dp)] = typename PFP::VEC3(0.5,-0.5,-0.5); // position[myMap.phi_1(myMap.phi2(dp))] = typename PFP::VEC3(1.5f, 0.0f, 0.0f); Dart dtemp = myMap.beta1(myMap.beta0(myMap.beta1(myMap.beta2(myMap.beta1(myMap.beta0(myMap.beta1(myMap.beta2(d)))))))); // Dart dtemp = myMap.beta1(myMap.beta0(myMap.beta1(myMap.beta2(myMap.beta1(myMap.beta0(myMap.beta1(myMap.beta2(d)))))))); myMap.sewVolumes(dtemp,dp); // myMap.sewVolumes(dtemp,dp); // Geom::Plane3D pl(VEC3(-1,-0.5,-0.5),VEC3(-1,-0.5,0.5),VEC3(1,0.5,0.5)); // Algo::Volume::Modelisation::sliceConvexVolume(myMap, position, d, pl); ... ...
 ... ... @@ -25,35 +25,34 @@ #include "simpleMap3.h" #include "Utils/GLSLShader.h" #include "Algo/Geometry/boundingbox.h" #include "Algo/Modelisation/primitives3d.h" #include "Algo/Tiling/Volume/cubic.h" #include "Algo/Modelisation/subdivision3.h" SimpleMap3::SimpleMap3() { position = myMap.addAttribute("position"); Algo::Volume::Modelisation::Primitive3D primCat(myMap,position); Dart d = primCat.hexaGrid_topo(1,1,1); primCat.embedHexaGrid(1,1,1); myMap.closeMap(); Algo::Volume::Tilings::Cubic::Grid cubic(myMap, 1, 1, 1); cubic.embedIntoGrid(position, 1.0f, 1.0f, 1.0f); myMap.check(); Dart dp = Algo::Surface::Modelisation::createQuadrangularPyramid(myMap); position[dp] = typename PFP::VEC3(0.5,0.5,-0.5); position[myMap.phi1(dp)] = typename PFP::VEC3(0.5,0.5,0.5); position[myMap.phi1(myMap.phi1(dp))] = typename PFP::VEC3(0.5,-0.5,0.5); position[myMap.phi_1(dp)] = typename PFP::VEC3(0.5,-0.5,-0.5); position[myMap.phi_1(myMap.phi2(dp))] = typename PFP::VEC3(1.5f, 0.0f, 0.0f); // Dart dp = Algo::Surface::Modelisation::createQuadrangularPyramid(myMap); // position[dp] = typename PFP::VEC3(0.5,0.5,-0.5); // position[myMap.phi1(dp)] = typename PFP::VEC3(0.5,0.5,0.5); // position[myMap.phi1(myMap.phi1(dp))] = typename PFP::VEC3(0.5,-0.5,0.5); // position[myMap.phi_1(dp)] = typename PFP::VEC3(0.5,-0.5,-0.5); // position[myMap.phi_1(myMap.phi2(dp))] = typename PFP::VEC3(1.5f, 0.0f, 0.0f); Dart dtemp = myMap.phi_1(myMap.phi2(myMap.phi_1(myMap.phi_1(myMap.phi2(d))))); // Dart dtemp = myMap.phi_1(myMap.phi2(myMap.phi_1(myMap.phi_1(myMap.phi2(d))))); myMap.sewVolumes(dtemp,dp); // myMap.sewVolumes(dtemp,dp); // Algo::Volume::Modelisation::Primitive3D primCat(myMap, position); // Dart d = primCat.hexaGrid_topo(2,1,1); // primCat.embedHexaGrid(1,1,1); // myMap.closeMap(); // Algo::Volume::Tilings::Cubic::Grid cubic(myMap, 2, 1, 1); // cubic.embedIntoGrid(position, 1.0f, 1.0f, 1.0f); // myMap.check(); // unsigned int nb=0; // for(unsigned int i = position.begin(); i!=position.end(); position.next(i)) ... ...
 ... ... @@ -24,7 +24,7 @@ #include "texturesExample.h" #include "Algo/Geometry/boundingbox.h" #include "Algo/Modelisation/polyhedron.h" #include "Algo/Tiling/Surface/square.h" #include "Utils/vbo.h" TexView::TexView(): ... ... @@ -215,9 +215,9 @@ void TexView::computeTore() VertexAttribute position = myMap.addAttribute("position"); VertexAttribute texcoord = myMap.addAttribute("texcoord"); Algo::Surface::Modelisation::Polyhedron prim(myMap, position); prim.tore_topo(NB, NB); prim.embedTore(40.0f,20.0f); //Algo::Surface::Modelisation::Polyhedron prim(myMap, position); Algo::Surface::Tilings::Square::Tore prim(myMap, NB, NB); prim.embedIntoTore(position, 40.0f,20.0f); Dart d = prim.getDart(); for(unsigned int i=0; i
 ... ... @@ -26,7 +26,7 @@ #include "volumeExplorer.h" #include #include "Algo/Modelisation/primitives3d.h" #include "Algo/Tiling/Volume/cubic.h" #include "Algo/Modelisation/polyhedron.h" #include "Algo/Import/import.h" #include "Algo/Geometry/volume.h" ... ... @@ -214,7 +214,7 @@ void MyQT::cb_initGL() // create the renders m_topo_render = new Algo::Render::GL2::Topo3Render(); m_explode_render = new Algo::Render::GL2::ExplodeVolumeRender(true,true,false); m_explode_render = new Algo::Render::GL2::ExplodeVolumeRender(true,true,true); // SelectorDartNoBoundary nb(myMap); m_topo_render->updateData(myMap, position, 0.8f, 0.8f, 0.8f); ... ... @@ -440,10 +440,10 @@ int main(int argc, char **argv) else { position = myMap.addAttribute("position"); Algo::Volume::Modelisation::Primitive3D prim(myMap, position); int nb = 8; prim.hexaGrid_topo(nb,nb,nb); prim.embedHexaGrid(1.0f,1.0f,1.0f); Algo::Volume::Tilings::Cubic::Grid cubic(myMap, nb, nb, nb); cubic.embedIntoGrid(position, 1.0f, 1.0f, 1.0f); for (unsigned int i=position.begin(); i != position.end(); position.next(i)) { ... ...
 ... ... @@ -23,8 +23,12 @@ ENDIF(WIN32) #define exec to compile add_executable( multi_att multi_att.cpp) target_link_libraries( multi_att \${CGoGN_LIBS_D} \${CGoGN_EXT_LIBS} ) add_executable(multi_att multi_att.cpp) target_link_libraries(multi_att \${CGoGN_LIBS_D} \${CGoGN_EXT_LIBS}) QT4_WRAP_CPP(tilings_moc tilings.h) add_executable(tilings tilings.cpp \${tilings_moc}) target_link_libraries(tilings \${CGoGN_LIBS_D} \${CGoGN_EXT_LIBS}) # Example with Qt # ... ...