refactor: move scenes to dedicated CMakeLists.txt + clean arg parsing help
- Extract scenes_cube/scenes_sphere (and convenience 'scenes' interface) to scenes/CMakeLists.txt. - Main CMakeLists.txt now much cleaner (single add_subdirectory(scenes)). - Updated help text in cuber.cpp to clearly separate Flags vs Keys (less confusing 'S' section). - No behavior change; depth/viewport/state/post-processing fixes from earlier remain. Followed project conventions and AGENTS.md commit rules.
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
add_library(scenes_cube STATIC "cube.cpp")
|
||||
target_include_directories(scenes_cube PRIVATE "." "..")
|
||||
target_compile_features(scenes_cube PRIVATE cxx_std_23)
|
||||
target_compile_options(scenes_cube PRIVATE ${BASE_OPTIONS})
|
||||
target_compile_definitions(scenes_cube PRIVATE ${BASE_DEFINITIONS})
|
||||
target_link_libraries(scenes_cube PUBLIC cbt_scene glm::glm)
|
||||
|
||||
add_library(scenes_sphere STATIC "sphere.cpp")
|
||||
target_include_directories(scenes_sphere PRIVATE "." "..")
|
||||
target_compile_features(scenes_sphere PRIVATE cxx_std_23)
|
||||
target_compile_options(scenes_sphere PRIVATE ${BASE_OPTIONS})
|
||||
target_compile_definitions(scenes_sphere PRIVATE ${BASE_DEFINITIONS})
|
||||
target_link_libraries(scenes_sphere PUBLIC cbt_scene glm::glm)
|
||||
|
||||
# Convenience interface for all scenes
|
||||
add_library(scenes INTERFACE)
|
||||
target_link_libraries(scenes INTERFACE scenes_cube scenes_sphere)
|
||||
Reference in New Issue
Block a user