2010-04-30 20:22:31 +08:00
|
|
|
SET( TARGET_SRC
|
2011-05-16 17:17:30 +08:00
|
|
|
osgviewerQt.cpp
|
2010-04-30 20:22:31 +08:00
|
|
|
)
|
|
|
|
|
2013-06-10 22:34:25 +08:00
|
|
|
IF ( NOT Qt5Widgets_FOUND )
|
|
|
|
IF( QT4_FOUND )
|
|
|
|
SET(TARGET_EXTERNAL_LIBRARIES ${QT_QTCORE_LIBRARY_RELEASE} ${QT_QTGUI_LIBRARY_RELEASE}
|
|
|
|
${QT_QTOPENGL_LIBRARY_RELEASE} )
|
2010-04-30 20:22:31 +08:00
|
|
|
ADD_DEFINITIONS(-DUSE_QT4)
|
2013-06-10 22:34:25 +08:00
|
|
|
ELSE( QT4_FOUND )
|
2010-04-30 20:22:31 +08:00
|
|
|
SET(TARGET_EXTERNAL_LIBRARIES ${QT_LIBRARIES} )
|
2013-06-10 22:34:25 +08:00
|
|
|
ENDIF( QT4_FOUND )
|
2010-04-30 20:22:31 +08:00
|
|
|
|
2013-06-10 22:34:25 +08:00
|
|
|
INCLUDE_DIRECTORIES( ${QT_INCLUDE_DIR} ${QT_QTCORE_INCLUDE_DIR} ${QT_QTGUI_INCLUDE_DIR}
|
|
|
|
${QT_QTOPENGL_INCLUDE_DIR} )
|
|
|
|
ENDIF()
|
2010-12-14 00:25:50 +08:00
|
|
|
|
|
|
|
SET(TARGET_ADDED_LIBRARIES osgWidget osgQt)
|
|
|
|
|
2013-06-10 22:34:25 +08:00
|
|
|
SET( EXAMPLE_NAME osgviewerQt )
|
|
|
|
|
|
|
|
SETUP_EXAMPLE( ${EXAMPLE_NAME} )
|
|
|
|
|
|
|
|
IF ( Qt5Widgets_FOUND )
|
|
|
|
qt5_use_modules( example_${EXAMPLE_NAME} Widgets OpenGL )
|
|
|
|
ENDIF( Qt5Widgets_FOUND )
|
|
|
|
|