Commit 68b8d632 authored by Thomas's avatar Thomas

Merge branch 'master' of cgogn.u-strasbg.fr:~cgogn/CGoGN

parents a832aa96 d547ef51
SET(EXECUTABLE_OUTPUT_PATH ${CGoGN_ROOT_DIR}/bin)
BOOST_LIBS(boost_regex_lib_lists "boost_regex-mt")
#BOOST_LIBS(boost_regex_lib_lists "boost_regex-mt")
SET (COMMON_LIBS ${GLUT_LIBRARY} ${OPENGL_LIBRARY} ${GLEW_LIBRARY} ${DEVIL_LIBRARIES} ${ZLIB_LIBRARIES} ${LIBXML2_LIBRARIES} ${boost_regex_lib_lists} gzstream AntTweakBar openctm assimp)
SET (COMMON_LIBS ${GLUT_LIBRARY} ${OPENGL_LIBRARY} ${GLEW_LIBRARY} ${DEVIL_LIBRARIES} ${ZLIB_LIBRARIES} ${LIBXML2_LIBRARIES} ${Boost_REGEX_LIBRARY} ${Boost_THREAD_LIBRARY} gzstream AntTweakBar openctm assimp)
SET(CGoGN_LIBS_R topology algo container utils)
......
......@@ -30,6 +30,12 @@ link_directories(
${CGoGN_ROOT_DIR}/lib/Debug
${CGoGN_ROOT_DIR}/lib/Release
)
IF(WIN32)
link_directories( ${CGoGN_ROOT_DIR}/lib/$(ConfigurationName) ${Boost_LIBRARY_DIRS})
ELSE(WIN32)
link_directories( ${CGoGN_ROOT_DIR}/lib/Debug ${CGoGN_ROOT_DIR}/lib/Release )
ENDIF(WIN32)
#define exec to compile
......
......@@ -12,6 +12,8 @@ INCLUDE(${QT_USE_FILE})
ADD_DEFINITIONS(${QT_DEFINITIONS})
find_package(Boost COMPONENTS regex REQUIRED)
# define includes path
include_directories(
${CMAKE_CURRENT_BINARY_DIR}
......@@ -25,11 +27,12 @@ include_directories(
${CGoGN_ROOT_DIR}/ThirdParty/OpenCTM
${CGoGN_ROOT_DIR}/ThirdParty/Assimp/include
${CGoGN_ROOT_DIR}/ThirdParty/glm
${Boost_INCLUDE_DIRS}
)
# define libs path
IF(WIN32)
link_directories( ${CGoGN_ROOT_DIR}/lib/$(ConfigurationName) )
link_directories( ${CGoGN_ROOT_DIR}/lib/$(ConfigurationName) ${Boost_LIBRARY_DIRS})
ELSE(WIN32)
link_directories( ${CGoGN_ROOT_DIR}/lib/Release )
ENDIF(WIN32)
......
......@@ -13,9 +13,6 @@ INCLUDE(${QT_USE_FILE})
ADD_DEFINITIONS(${QT_DEFINITIONS})
# define includes path
MESSAGE (STATUS ${BOOST_INCLUDE_PATH})
include_directories(
${CMAKE_CURRENT_BINARY_DIR}
/usr/include/libxml2/
......@@ -24,17 +21,20 @@ include_directories(
${CGoGN_ROOT_DIR}/ThirdParty/Assimp/include
${CGoGN_ROOT_DIR}/ThirdParty/glm
${CGoGN_ROOT_DIR}/include
${BOOST_INCLUDE_PATH}
${Boost_INCLUDE_DIRS}
)
# define libs path
IF(WIN32)
link_directories(${CGoGN_ROOT_DIR}/lib/$(ConfigurationName))
link_directories(${CGoGN_ROOT_DIR}/lib/$(ConfigurationName) ${Boost_LIBRARY_DIRS})
ELSE(WIN32)
link_directories(${CGoGN_ROOT_DIR}/lib/Release ${CGoGN_ROOT_DIR}/lib/Debug)
ENDIF(WIN32)
# define boost component usage (here only thread)
find_package(Boost COMPONENTS thread REQUIRED)
#define exec to compile
QT4_WRAP_CPP(tuto1_moc tuto1.h)
......@@ -79,17 +79,19 @@ target_link_libraries( tp_master
# -first argument variable that will contain the libs
# -second argument list of boost libs separated by ; in " "
# exemple: BOOST_LIBS(boost_lib_lists "boost_thread-mt;boost_iostreams-mt")
BOOST_LIBS(boost_lib_lists "boost_thread-mt")
#BOOST_LIBS(boost_lib_lists "boost_thread-mt")
QT4_WRAP_CPP(tuto_mt_moc tuto_mt.h)
add_executable( tuto_mt tuto_mt.cpp ${tuto_mt_moc})
target_link_libraries( tuto_mt
${CGoGN_LIBS_D} ${COMMON_LIBS} ${QT_LIBRARIES} ${boost_lib_lists})
${CGoGN_LIBS_D} ${COMMON_LIBS} ${QT_LIBRARIES} ${Boost_THREAD_LIBRARY})
QT4_WRAP_CPP(tuto_ogl3_moc tuto_ogl3.h)
add_executable( tuto_ogl3 tuto_ogl3.cpp ${tuto_ogl3_moc})
target_link_libraries( tuto_ogl3
${CGoGN_LIBS_D} ${COMMON_LIBS} ${QT_LIBRARIES} )
${CGoGN_LIBS_D} ${COMMON_LIBS} ${QT_LIBRARIES})
......
Prérequis:
Visual Studio ou C++ Express (au moins 2005)
CMake (au moins 2.6)
Visual Studio ou C++ Express (au moins 2005, si possible 2010)
CMake (au moins 2.8)
Unziper le windows_dependencies.zip (http://iggservis.u-strasbg.fr/Data/) a la racine de CGoGN
Installer boost et Qt
Attention installer les binaires de Qt dans une version de compilateur differente (VS2008/VS2010)
permet d'executer mais pas de debugger !
Si vous utiliser BoostPro (http://www.boostpro.com) installer toutes les versions multithread dll
pour eviter les pb de compilation.
Le plus sur mais plus long est de compiler soi-même Qt et Boost (bon courage)
Lancer CMake
Mettre le chemin de la racine de CGoGN + /ThirdParty pour les sources
......@@ -16,9 +25,6 @@ Aller compiler sous visual(en release)
Relancer CMake
Mettre le chemin de la racine de CGoGN + /build pour les sources
Mettre le chemin de la racine de CGoGN + /Visual (par exemple) pour le build
ajouter deux entrees dans le cache (pour utilisation de boost precompile: www.boostpro.com)
boost_path avec le chemin d'acces (exemple: C:\Program Files\boost\boost_1_44\)
boost_extension avec ce que vous voulez utiliser (exemple: -vc100-mt-1_44)
Cliquer sur Configure
Choisir le bon compilateur (celui de votre version de Visual C++)
Recliquer sur Configure
......@@ -30,8 +36,6 @@ Pour que les executables fonctionnent ajouter le chemin vers les dll dans la var
(ou copier les dll dans un répertoire déjà dans le path)
Compilation 64bits:
La libraries et les exemples sont compilables en 64bit sous Windows.
......
......@@ -12,6 +12,8 @@ SET(CMAKE_MODULE_PATH " ${CMAKE_MODULE_PATH} ${CGoGN_ROOT_DIR}/cmake_modules/")
find_package(OpenGL REQUIRED)
find_package(Qt4 REQUIRED)
find_package(GLUT)
find_package(Boost COMPONENTS regex thread REQUIRED)
IF (DEFINED ASSERTON)
add_definitions(-DCGOGN_ASSERT_BOOL=${ASSERTON})
......@@ -36,15 +38,14 @@ IF(WIN32)
SET(ZLIB_LIBRARIES zlib)
SET(LIBXML2_LIBRARIES xml2)
MACRO(BOOST_LIBS lib_lists names)
SET (${lib_lists} "")
FOREACH(name ${names})
STRING(REGEX REPLACE "-mt" ${boost_extension} newname ${name})
SET (${lib_lists} ${${lib_lists}} ${newname} )
ENDFOREACH(name)
ENDMACRO(BOOST_LIBS)
set (BOOST_INCLUDE_PATH ${boost_path})
# MACRO(BOOST_LIBS lib_lists names)
# SET (${lib_lists} "")
# FOREACH(name ${names})
# STRING(REGEX REPLACE "-mt" ${boost_extension} newname ${name})
# SET (${lib_lists} ${${lib_lists}} ${newname} )
# ENDFOREACH(name)
# ENDMACRO(BOOST_LIBS)
# set (BOOST_INCLUDE_PATH ${boost_path})
INCLUDE_DIRECTORIES(${CGoGN_ROOT_DIR}/windows_dependencies/include/)
LINK_DIRECTORIES(${CGoGN_ROOT_DIR}/windows_dependencies/lib/ ${boost_path}/lib)
......@@ -71,12 +72,12 @@ ELSE(WIN32)
SET(DEVIL_LIBRARIES ${IL_LIBRARY} ${ILU_LIBRARY} ${ILUT_LIBRARY})
ENDIF(IL_LIBRARIES)
MACRO(BOOST_LIBS lib_lists names)
SET (${lib_lists})
FOREACH(name ${names})
SET (${lib_lists} ${${lib_lists}} ${name} )
ENDFOREACH(name)
ENDMACRO(BOOST_LIBS)
# MACRO(BOOST_LIBS lib_lists names)
# SET (${lib_lists})
# FOREACH(name ${names})
# SET (${lib_lists} ${${lib_lists}} ${name} )
# ENDFOREACH(name)
# ENDMACRO(BOOST_LIBS)
add_subdirectory(Release)
add_subdirectory(Debug)
......
......@@ -27,6 +27,7 @@ include_directories(
${CGoGN_ROOT_DIR}/ThirdParty/gzstream
${CGoGN_ROOT_DIR}/ThirdParty/Assimp/include
${CGoGN_ROOT_DIR}/ThirdParty/glm
${Boost_INCLUDE_DIRS}
)
......
......@@ -29,6 +29,7 @@ include_directories(
${CGoGN_ROOT_DIR}/ThirdParty/gzstream
${CGoGN_ROOT_DIR}/ThirdParty/Assimp/include
${CGoGN_ROOT_DIR}/ThirdParty/glm
${Boost_INCLUDE_DIRS}
)
......
......@@ -541,7 +541,7 @@ bool ImplicitHierarchicalMap3::neighborhoodLevelDiffersByOne(Dart d)
{
// add all face neighbours to the table
if(phi3(e) != e && (abs(volumeLevel(phi3(e)) - vLevel) > 1))
if(phi3(e) != e && (abs(int(volumeLevel(phi3(e)) - vLevel)) > 1))
{
found = true;
}
......
......@@ -24,6 +24,9 @@
#include "Utils/clippingPresets.h"
#define _USE_MATH_DEFINES
#include <math.h>
namespace CGoGN
{
......
......@@ -23,6 +23,8 @@
*******************************************************************************/
#include "Utils/clippingPresetsAnimated.h"
#define _USE_MATH_DEFINES
#include <math.h>
namespace CGoGN
{
......
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