Switched to using Qt for loading extensions, instead of GLEW.
This commit is contained in:
@ -42,17 +42,13 @@ SET(INC_FILES
|
||||
Shapes.h
|
||||
)
|
||||
|
||||
add_definitions(-DGLEW_STATIC)
|
||||
|
||||
#"Sources" and "Headers" are the group names in Visual Studio.
|
||||
#They may have other uses too...
|
||||
SOURCE_GROUP("Sources" FILES ${SRC_FILES})
|
||||
SOURCE_GROUP("Headers" FILES ${INC_FILES})
|
||||
|
||||
FIND_PACKAGE(OpenGL REQUIRED)
|
||||
|
||||
#Tell CMake the paths for OpenGL and for PolyVox (which is just relative to our current location)
|
||||
INCLUDE_DIRECTORIES(${OPENGL_INCLUDE_DIR} ${PolyVoxHeaders_SOURCE_DIR} ${GLEW_SOURCE_DIR})
|
||||
INCLUDE_DIRECTORIES(${OPENGL_INCLUDE_DIR} ${PolyVoxHeaders_SOURCE_DIR} ../common)
|
||||
|
||||
#This will include the shader files inside the compiled binary
|
||||
QT5_ADD_RESOURCES(COMMON_RESOURCES_RCC ../common/example.qrc)
|
||||
@ -66,7 +62,7 @@ ADD_EXECUTABLE(OpenGLExample ${SRC_FILES} ${COMMON_RESOURCES_RCC} ${OPENGL_EXAMP
|
||||
IF(MSVC)
|
||||
SET_TARGET_PROPERTIES(OpenGLExample PROPERTIES COMPILE_FLAGS "/W4 /wd4127")
|
||||
ENDIF(MSVC)
|
||||
TARGET_LINK_LIBRARIES(OpenGLExample glew Qt5::OpenGL ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY})
|
||||
TARGET_LINK_LIBRARIES(OpenGLExample Qt5::OpenGL)
|
||||
SET_PROPERTY(TARGET OpenGLExample PROPERTY FOLDER "Examples")
|
||||
|
||||
#Install - Only install the example in Windows
|
||||
|
Reference in New Issue
Block a user