2014-09-30 22:07:25 +08:00
|
|
|
|
|
|
|
set(SRCROOT ${PROJECT_SOURCE_DIR}/examples/opengl)
|
|
|
|
|
|
|
|
# all source files
|
|
|
|
set(SRC ${SRCROOT}/OpenGL.cpp)
|
|
|
|
|
2018-04-13 02:39:55 +08:00
|
|
|
if (SFML_OS_IOS)
|
|
|
|
set(RESOURCES
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/resources/background.jpg
|
2020-12-13 04:40:52 +08:00
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/resources/tuffy.ttf)
|
2018-04-13 02:39:55 +08:00
|
|
|
set_source_files_properties(${RESOURCES} PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
|
|
|
endif()
|
|
|
|
|
2014-09-30 22:07:25 +08:00
|
|
|
# define the opengl target
|
|
|
|
sfml_add_example(opengl GUI_APP
|
|
|
|
SOURCES ${SRC}
|
2018-04-13 02:39:55 +08:00
|
|
|
BUNDLE_RESOURCES ${RESOURCES}
|
2021-12-29 13:28:50 +08:00
|
|
|
DEPENDS SFML::Graphics
|
2018-01-13 07:19:56 +08:00
|
|
|
RESOURCES_DIR resources)
|
2021-04-20 21:59:24 +08:00
|
|
|
|
|
|
|
# external dependency headers
|
2022-04-05 02:13:03 +08:00
|
|
|
target_include_directories(opengl SYSTEM PRIVATE ${PROJECT_SOURCE_DIR}/examples/opengl)
|