Commit f4fac0c4 authored by Sauvage's avatar Sauvage

Merge remote-tracking branch 'CGoGNcentral/develop' into develop

Conflicts:
	CGoGN/include/Utils/sphericalHarmonics.hpp
parents 9ce3d307 413a821f

Too many changes to show.

To preserve performance only 1000 of 1000+ files are displayed.

......@@ -2,4 +2,5 @@
CMakeLists.txt.user
bin/
ThirdParty/bin/
SCHNApps/bin
\ No newline at end of file
SCHNApps/bin/
windows_dependencies/
......@@ -2,26 +2,6 @@ cmake_minimum_required(VERSION 2.8)
project(benches)
#SET(CMAKE_BUILD_TYPE Release)
#SET(CMAKE_BUILD_TYPE Debug)
#SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DNOTOPOWARNING")
# define includes path
include_directories(
${CMAKE_CURRENT_BINARY_DIR}
${CGoGN_ROOT_DIR}/include
${CGoGN_EXT_INCLUDES}
)
# define libs path
#IF(WIN32)
# link_directories( ${CGoGN_ROOT_DIR}/lib/$(ConfigurationName) ${Boost_LIBRARY_DIRS} )
#ELSE(WIN32)
# link_directories( ${CGoGN_ROOT_DIR}/lib/Release )
#ENDIF(WIN32)
add_executable(bench_trav bench_trav.cpp )
target_link_libraries( bench_trav ${CGoGN_LIBS} ${CGoGN_EXT_LIBS} )
......
......@@ -72,7 +72,7 @@ int main(int argc, char **argv)
std::vector<VertexAttribute<typename PFP::VEC3, MAP> > attr;
attr.push_back(position);
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices * 0.05) ;
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices /20) ;
VertexAttribute<PFP::VEC3, MAP> normal = myMap.addAttribute<PFP::VEC3,VERTEX,MAP>( "normal") ;
VertexAttribute<PFP::VEC3, MAP> position2 = myMap.addAttribute<PFP::VEC3,VERTEX,MAP>( "pos2") ;
......
......@@ -54,19 +54,19 @@ int main(int argc, char **argv)
std::vector<VertexAttribute<typename PFP::VEC3, MAP> > attr;
attr.push_back(position);
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices * 0.1) ;
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices / 10) ;
Algo::Surface::Modelisation::LoopSubdivision<PFP>(myMap, position) ;
Algo::Surface::Modelisation::LoopSubdivision<PFP>(myMap, position) ;
nbVertices = Algo::Topo::getNbOrbits<VERTEX>(myMap) ;
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices * 0.1) ;
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices / 10);
Algo::Surface::Modelisation::LoopSubdivision<PFP>(myMap, position) ;
Algo::Surface::Modelisation::LoopSubdivision<PFP>(myMap, position) ;
nbVertices = Algo::Topo::getNbOrbits<VERTEX>(myMap) ;
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices * 0.1) ;
Algo::Surface::Decimation::decimate<PFP>(myMap, Algo::Surface::Decimation::S_QEM, Algo::Surface::Decimation::A_QEM, attr, nbVertices / 10);
Algo::Surface::Modelisation::CatmullClarkSubdivision<PFP>(myMap, position) ;
Algo::Surface::Modelisation::CatmullClarkSubdivision<PFP>(myMap, position) ;
......
......@@ -81,9 +81,11 @@ int main()
});
centerFace /=nbVert;
centerVol += centerFace;
nbFaces++;
});
centerVol /= nbFaces;
centerMesh += centerVol;
nbVols++;
});
centerMesh /= nbVols;
CGoGNout<< "Traverse with foreach in " << ch.elapsed()<< " ms"<< CGoGNendl;
......@@ -110,9 +112,11 @@ int main()
}
centerFace /=nbVert;
centerVol += centerFace;
nbFaces++;
}
centerVol /= nbFaces;
centerMesh += centerVol;
nbVols++;
}
CGoGNout<< "Traverse with traversor in " << ch.elapsed()<< " ms"<< CGoGNendl;
......
IF (ONELIB)
project(Apps)
IF (CGoGN_ONELIB)
SET(CGoGN_LIBS cgogn)
ELSE (ONELIB)
SET(CGoGN_LIBS algo topology container utils)
ENDIF (ONELIB)
ELSE ()
SET(CGoGN_LIBS algo) # topology container utils include by dependencies
ENDIF ()
IF (WIN32)
link_directories( ${CGoGN_ROOT_DIR}/lib/${ConfigurationName} ${Boost_LIBRARY_DIRS})
SET(EXECUTABLE_OUTPUT_PATH ${CGoGN_ROOT_DIR}/bin/) # Release/Debug added automatically by visual
link_directories( ${CGoGN_ROOT_DIR}/windows_dependencies/lib/)
IF((CGoGN_WITH_QTCREATOR))
link_directories( ${CGoGN_ROOT_DIR}/bin/${CMAKE_BUILD_TYPE})
SET(EXECUTABLE_OUTPUT_PATH ${CGoGN_ROOT_DIR}/bin/${CMAKE_BUILD_TYPE}) # Release/Debug added automatically by visual
ELSE()
link_directories( ${CGoGN_ROOT_DIR}/bin/$(ConfigurationName))
SET(EXECUTABLE_OUTPUT_PATH ${CGoGN_ROOT_DIR}/bin/) # Release/Debug added automatically by visual
ENDIF()
ELSE()
link_directories( ${CGoGN_ROOT_DIR}/lib/${CMAKE_BUILD_TYPE} )
SET(EXECUTABLE_OUTPUT_PATH ${CGoGN_ROOT_DIR}/bin/${CMAKE_BUILD_TYPE} )
IF(APPLE)
SET(EXECUTABLE_OUTPUT_PATH ${CGoGN_ROOT_DIR}/bin/${CMAKE_BUILD_TYPE}/Contents/MacOS/ )
ELSE()
SET(EXECUTABLE_OUTPUT_PATH ${CGoGN_ROOT_DIR}/bin/${CMAKE_BUILD_TYPE} )
ENDIF()
ENDIF()
include_directories(
${CGoGN_ROOT_DIR}/include
${CGoGN_EXT_INCLUDES})
#include_directories(
# ${CGoGN_ROOT_DIR}/include
# ${CGoGN_EXT_INCLUDES})
IF (COMPILE_SANDBOX)
IF (CGoGN_COMPILE_SANDBOX)
add_subdirectory(SandBox)
ENDIF()
IF (COMPILE_EXAMPLES AND WITH_QT)
add_subdirectory(Examples)
IF (CGoGN_COMPILE_EXAMPLES AND CGoGN_WITH_QT)
add_subdirectory(Examples)
ENDIF()
IF (COMPILE_TUTOS)
IF (CGoGN_COMPILE_TUTOS)
add_subdirectory(Tuto)
ENDIF()
IF (COMPILE_BENCHES)
IF (CGoGN_COMPILE_BENCHES)
add_subdirectory(Benches)
ENDIF()
IF (COMPILE_TESTS)
IF (CGoGN_COMPILE_TESTS)
add_subdirectory(Tests)
ENDIF()
#IF (WITH_QT)
# add_subdirectory(Tuto)
# add_subdirectory(Examples)
# IF (NOT DONOT_COMPILE_SANDBOX)
# add_subdirectory(SandBox)
# ENDIF (NOT DONOT_COMPILE_SANDBOX)
#ENDIF (WITH_QT)
#add_subdirectory(Tests)
#add_subdirectory(Benches)
#add_subdirectory(Tuto/Traversals)
#add_subdirectory(Tuto/Attributes)
#add_subdirectory(Tuto/Markers)
#add_subdirectory(Tuto/Boundary)
#add_subdirectory(Tuto/Modelling)
......@@ -2,71 +2,65 @@ cmake_minimum_required(VERSION 2.8)
project(examples)
#SET(CMAKE_BUILD_TYPE Release)
#SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DNOTOPOWARNING")
# define includes path
include_directories(${CMAKE_CURRENT_BINARY_DIR})
# define libs path
#IF(WIN32)
# link_directories( ${CGoGN_ROOT_DIR}/lib/$(ConfigurationName) ${Boost_LIBRARY_DIRS} )
#ELSE(WIN32)
# link_directories( ${CGoGN_ROOT_DIR}/lib/Release )
#ENDIF(WIN32)
#define exec to compile
QT4_WRAP_CPP( frame_manip_moc frame_manip.h )
qt_wrap_cpp( frame_manip_moc frame_manip.h )
add_executable( frame_manip frame_manip.cpp ${frame_manip_moc} )
target_link_libraries( frame_manip ${CGoGN_LIBS} ${CGoGN_EXT_LIBS} )
QT4_WRAP_CPP( texturesExample_moc texturesExample.h )
#need to define that we use Qt (only once per cmake directory!)
qt_use_cgogn_modules(frame_manip)
qt_wrap_cpp( texturesExample_moc texturesExample.h )
add_executable( texturesExample texturesExample.cpp ${texturesExample_moc} )
target_link_libraries( texturesExample ${CGoGN_LIBS} ${CGoGN_EXT_LIBS} )
QT4_WRAP_CPP(simpleMap3_moc simpleMap3.h)
qt_wrap_cpp(simpleMap3_moc simpleMap3.h)
add_executable( simpleMap3 simpleMap3.cpp ${simpleMap3_moc} )
target_link_libraries( simpleMap3 ${CGoGN_LIBS} ${CGoGN_EXT_LIBS} )
QT4_WRAP_CPP( simpleGMap2_moc simpleGMap2.h )
qt_wrap_cpp( simpleGMap2_moc simpleGMap2.h )
add_executable( simpleGMap2 simpleGMap2.cpp ${simpleGMap2_moc} )
target_link_libraries( simpleGMap2 ${CGoGN_LIBS} ${CGoGN_EXT_LIBS} )
QT4_WRAP_CPP( simpleGMap3_moc simpleGMap3.h )
qt_wrap_cpp( simpleGMap3_moc simpleGMap3.h )
add_executable( simpleGMap3 simpleGMap3.cpp ${simpleGMap3_moc} )
target_link_libraries( simpleGMap3 ${CGoGN_LIBS} ${CGoGN_EXT_LIBS} )
QT4_WRAP_CPP( extrusionView_moc extrusionView.h )
qt_wrap_cpp( extrusionView_moc extrusionView.h )