Commit eb589834 authored by Sylvain Thery's avatar Sylvain Thery

core profile in SCHNApps deduced from CGoGN

parent 0598efba
...@@ -18,7 +18,7 @@ INCLUDE(${CGoGN_ROOT_DIR}/cmake_modules/functions.cmake) ...@@ -18,7 +18,7 @@ INCLUDE(${CGoGN_ROOT_DIR}/cmake_modules/functions.cmake)
SET ( CGoGN_WITH_ASSIMP OFF CACHE BOOL "build CGoGN with Assimp" ) SET ( CGoGN_WITH_ASSIMP OFF CACHE BOOL "build CGoGN with Assimp" )
SET ( CGoGN_WITH_ZINRI OFF CACHE BOOL "build CGoGN with Zinri lib" ) SET ( CGoGN_WITH_ZINRI OFF CACHE BOOL "build CGoGN with Zinri lib" )
SET ( CGoGN_WITH_QT ON CACHE BOOL "build CGoGN with Qt lib" ) SET ( CGoGN_WITH_QT ON CACHE BOOL "build CGoGN with Qt lib" )
SET ( CGoGN_DESIRED_QT_VERSION "4" CACHE STRING "4: QT4/ 5 not yet implemented" ) SET ( DESIRED_QT_VERSION "4" CACHE STRING "4: QT4/ 5 not yet implemented" )
SET ( CGoGN_WITH_PYTHONQT ON CACHE BOOL "build PythonQt (for Schnapps)") SET ( CGoGN_WITH_PYTHONQT ON CACHE BOOL "build PythonQt (for Schnapps)")
SET ( CGoGN_WITH_GLEWMX OFF CACHE BOOL "use multi-contex GLEW" ) SET ( CGoGN_WITH_GLEWMX OFF CACHE BOOL "use multi-contex GLEW" )
SET ( CGoGN_USE_OGL_CORE_PROFILE OFF CACHE BOOL "use OpenGL 3.3 core profile (do not work on mac)" ) SET ( CGoGN_USE_OGL_CORE_PROFILE OFF CACHE BOOL "use OpenGL 3.3 core profile (do not work on mac)" )
...@@ -169,6 +169,12 @@ ELSE () ...@@ -169,6 +169,12 @@ ELSE ()
file(WRITE ${CGoGN_SRC_DIR}/include/cgogn_gmx.h "0" ) file(WRITE ${CGoGN_SRC_DIR}/include/cgogn_gmx.h "0" )
ENDIF () ENDIF ()
IF (CGoGN_USE_OGL_CORE_PROFILE)
file(WRITE ${CGoGN_SRC_DIR}/include/cgogn_coreprofile.h "1" )
ELSE ()
file(WRITE ${CGoGN_SRC_DIR}/include/cgogn_coreprofile.h "0" )
ENDIF ()
# #
# INCLUDES AND LIBS # INCLUDES AND LIBS
......
...@@ -17,7 +17,6 @@ SET(CMAKE_MODULE_PATH ${CGoGN_ROOT_DIR}/cmake_modules/) ...@@ -17,7 +17,6 @@ SET(CMAKE_MODULE_PATH ${CGoGN_ROOT_DIR}/cmake_modules/)
SET (CGoGN_SRC_DIR ${CGoGN_ROOT_DIR}/CGoGN) SET (CGoGN_SRC_DIR ${CGoGN_ROOT_DIR}/CGoGN)
SET( CGoGN_SLOT_DEBUG_MODE OFF CACHE BOOL "build with slot debugging mode" ) SET( CGoGN_SLOT_DEBUG_MODE OFF CACHE BOOL "build with slot debugging mode" )
SET( CGoGN_USE_OGL_CORE_PROFILE OFF CACHE BOOL "use OpenGL 3.3 core profile (do not work on mac)" )
SET( CGoGN_ASSERT_ACTIVED OFF CACHE BOOL "assertion activated") SET( CGoGN_ASSERT_ACTIVED OFF CACHE BOOL "assertion activated")
...@@ -54,15 +53,18 @@ ELSE() ...@@ -54,15 +53,18 @@ ELSE()
SET(CGoGN_LIBS topology algo container utils) SET(CGoGN_LIBS topology algo container utils)
ENDIF() ENDIF()
file(STRINGS ${CGoGN_SRC_DIR}/include/cgogn_coreprofile.h COREPROFILE_STR)
IF (COREPROFILE_STR EQUAL 1)
add_definitions(-DCGoGN_USE_OGL_CORE_PROFILE=1)
ENDIF()
add_definitions(-DCGOGN_ASSERT_BOOL=${CGoGN_ASSERT_ACTIVED}) add_definitions(-DCGOGN_ASSERT_BOOL=${CGoGN_ASSERT_ACTIVED})
IF(CGoGN_SLOT_DEBUG_MODE) IF(CGoGN_SLOT_DEBUG_MODE)
add_definitions(-DCGoGN_SLOT_DEBUG_MODE=1) add_definitions(-DCGoGN_SLOT_DEBUG_MODE=1)
ENDIF() ENDIF()
IF(CGoGN_USE_OGL_CORE_PROFILE)
add_definitions(-DCGoGN_USE_OGL_CORE_PROFILE=1)
ENDIF()
# define includes of external libs # define includes of external libs
SET (EXT_INCLUDES SET (EXT_INCLUDES
......
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