Mercurial > hg > orthanc-stone
annotate Samples/Sdl/CMakeLists.txt @ 938:eaaa9b574e05 toa2019073101
Fixed the Stone samples wrt the recent API changes (SdlOpenGLViewport, ICompositor...)
author | Benjamin Golinvaux <bgo@osimis.io> |
---|---|
date | Wed, 31 Jul 2019 10:58:16 +0200 |
parents | a911f5bb48da |
children |
rev | line source |
---|---|
600 | 1 cmake_minimum_required(VERSION 2.8.3) |
2 | |
3 ##################################################################### | |
4 ## Configuration of the Orthanc framework | |
5 ##################################################################### | |
6 | |
7 # This CMake file defines the "ORTHANC_STONE_VERSION" macro, so it | |
8 # must be the first inclusion | |
9 include(${CMAKE_SOURCE_DIR}/../../Resources/CMake/Version.cmake) | |
10 | |
11 if (ORTHANC_STONE_VERSION STREQUAL "mainline") | |
12 set(ORTHANC_FRAMEWORK_VERSION "mainline") | |
13 set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "hg") | |
14 else() | |
15 set(ORTHANC_FRAMEWORK_VERSION "1.5.7") | |
16 set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "web") | |
17 endif() | |
18 | |
19 set(ORTHANC_FRAMEWORK_SOURCE "${ORTHANC_FRAMEWORK_DEFAULT_SOURCE}" CACHE STRING "Source of the Orthanc source code (can be \"hg\", \"archive\", \"web\" or \"path\")") | |
20 set(ORTHANC_FRAMEWORK_ARCHIVE "" CACHE STRING "Path to the Orthanc archive, if ORTHANC_FRAMEWORK_SOURCE is \"archive\"") | |
21 set(ORTHANC_FRAMEWORK_ROOT "" CACHE STRING "Path to the Orthanc source directory, if ORTHANC_FRAMEWORK_SOURCE is \"path\"") | |
22 | |
23 | |
24 ##################################################################### | |
25 ## Configuration of the Stone framework | |
26 ##################################################################### | |
27 | |
28 include(${CMAKE_SOURCE_DIR}/../../Resources/CMake/OrthancStoneParameters.cmake) | |
29 include(${ORTHANC_ROOT}/Resources/CMake/DownloadPackage.cmake) | |
30 | |
31 DownloadPackage( | |
32 "a24b8136b8f3bb93f166baf97d9328de" | |
33 "http://orthanc.osimis.io/ThirdPartyDownloads/ubuntu-font-family-0.83.zip" | |
34 "${CMAKE_BINARY_DIR}/ubuntu-font-family-0.83") | |
35 | |
36 set(ORTHANC_STONE_APPLICATION_RESOURCES | |
37 UBUNTU_FONT ${CMAKE_BINARY_DIR}/ubuntu-font-family-0.83/Ubuntu-R.ttf | |
38 ) | |
39 | |
632
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
40 SET(ENABLE_SDL_CONSOLE OFF CACHE BOOL "Enable the use of the MIT-licensed SDL_Console") |
600 | 41 SET(ENABLE_GOOGLE_TEST OFF) |
42 SET(ENABLE_LOCALE ON) | |
43 SET(ENABLE_SDL ON) | |
44 SET(ENABLE_WEB_CLIENT ON) | |
45 SET(ORTHANC_SANDBOXED OFF) | |
46 LIST(APPEND ORTHANC_BOOST_COMPONENTS program_options) | |
47 | |
48 include(${CMAKE_SOURCE_DIR}/../../Resources/CMake/OrthancStoneConfiguration.cmake) | |
49 | |
857
0c0fc20a6902
macro ORTHANC_ENABLE_LOGGING_PLUGIN must be defined per app, not by stone
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
827
diff
changeset
|
50 add_definitions( |
0c0fc20a6902
macro ORTHANC_ENABLE_LOGGING_PLUGIN must be defined per app, not by stone
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
827
diff
changeset
|
51 -DORTHANC_ENABLE_LOGGING_PLUGIN=0 |
0c0fc20a6902
macro ORTHANC_ENABLE_LOGGING_PLUGIN must be defined per app, not by stone
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
827
diff
changeset
|
52 ) |
0c0fc20a6902
macro ORTHANC_ENABLE_LOGGING_PLUGIN must be defined per app, not by stone
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
827
diff
changeset
|
53 |
0c0fc20a6902
macro ORTHANC_ENABLE_LOGGING_PLUGIN must be defined per app, not by stone
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
827
diff
changeset
|
54 |
600 | 55 ##################################################################### |
56 ## Build the samples | |
57 ##################################################################### | |
58 | |
59 add_library(OrthancStone STATIC | |
60 ${ORTHANC_STONE_SOURCES} | |
61 ) | |
62 | |
827
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
63 # |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
64 # BasicScene |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
65 # |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
66 |
600 | 67 add_executable(BasicScene |
68 BasicScene.cpp | |
69 ) | |
70 | |
71 target_link_libraries(BasicScene OrthancStone) | |
619
9cd19b28f011
test: refactoring oracle
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
616
diff
changeset
|
72 |
827
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
73 # |
848
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
74 # TrackerSample |
827
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
75 # |
632
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
76 |
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
77 LIST(APPEND TRACKERSAMPLE_SOURCE "TrackerSample.cpp") |
644 | 78 LIST(APPEND TRACKERSAMPLE_SOURCE "TrackerSampleApp.cpp") |
79 LIST(APPEND TRACKERSAMPLE_SOURCE "TrackerSampleApp.h") | |
80 | |
81 if (MSVC AND MSVC_VERSION GREATER 1700) | |
82 LIST(APPEND TRACKERSAMPLE_SOURCE "cpp.hint") | |
83 endif() | |
632
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
84 |
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
85 add_executable(TrackerSample |
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
86 ${TRACKERSAMPLE_SOURCE} |
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
87 ) |
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
88 |
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
89 target_link_libraries(TrackerSample OrthancStone) |
500c3f70b6c2
- Added a ClearAllChains method to PolylineSceneLayer --> revision must change
Benjamin Golinvaux <bgo@osimis.io>
parents:
616
diff
changeset
|
90 |
827
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
91 # |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
92 # Loader |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
93 # |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
94 |
619
9cd19b28f011
test: refactoring oracle
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
616
diff
changeset
|
95 add_executable(Loader |
9cd19b28f011
test: refactoring oracle
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
616
diff
changeset
|
96 Loader.cpp |
9cd19b28f011
test: refactoring oracle
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
616
diff
changeset
|
97 ) |
9cd19b28f011
test: refactoring oracle
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
616
diff
changeset
|
98 |
9cd19b28f011
test: refactoring oracle
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
616
diff
changeset
|
99 target_link_libraries(Loader OrthancStone) |
827
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
100 |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
101 # |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
102 # FusionMprSdl |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
103 # |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
104 |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
105 add_executable(FusionMprSdl |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
106 FusionMprSdl.cpp |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
107 FusionMprSdl.h |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
108 ) |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
109 |
2fd96a637a59
Added FusioMpr sample + small dumb changes
Benjamin Golinvaux <bgo@osimis.io>
parents:
698
diff
changeset
|
110 target_link_libraries(FusionMprSdl OrthancStone) |
848
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
111 |
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
112 # |
916
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
113 # Multiplatform Basic Scene |
848
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
114 # |
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
115 |
916
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
116 LIST(APPEND MP_BASIC_SCENE_SOURCE "../MultiPlatform/BasicScene/BasicScene.cpp") |
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
117 LIST(APPEND MP_BASIC_SCENE_SOURCE "../MultiPlatform/BasicScene/BasicScene.h") |
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
118 LIST(APPEND MP_BASIC_SCENE_SOURCE "../MultiPlatform/BasicScene/mainSdl.cpp") |
848
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
119 |
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
120 if (MSVC AND MSVC_VERSION GREATER 1700) |
916
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
121 LIST(APPEND MP_BASIC_SCENE_SOURCE "cpp.hint") |
848
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
122 endif() |
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
123 |
916
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
124 add_executable(MpBasicScene |
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
125 ${MP_BASIC_SCENE_SOURCE} |
848
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
126 ) |
80829436ce0c
starting to re-implement radiography editor with latest framework
Alain Mazy <alain@mazy.be>
parents:
827
diff
changeset
|
127 |
916
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
128 target_include_directories(MpBasicScene PUBLIC ${ORTHANC_STONE_ROOT}) |
a911f5bb48da
MultiPlatform Basic Scene sample (so far: SDL + Qt)
Alain Mazy <alain@mazy.be>
parents:
897
diff
changeset
|
129 target_link_libraries(MpBasicScene OrthancStone) |