mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-06-14 21:01:39 -05:00
Add compatability check for screenshot functionality
This commit is contained in:
parent
bb954a2e9a
commit
2d70fbac36
|
|
@ -101,24 +101,6 @@ if(BUILD_OUT_OF_TREE)
|
|||
|
||||
find_package(CURL REQUIRED)
|
||||
include_directories("${CURL_INCLUDE_DIRS}")
|
||||
|
||||
# Backwards compatability with older OBS versions
|
||||
if(LibObs_VERSION_MAJOR GREATER_EQUAL 27)
|
||||
add_definitions(-DVCAM_SUPPORTED)
|
||||
else()
|
||||
message(
|
||||
WARNING
|
||||
"OBS version ${LibObs_VERSION_MAJOR} found - disabling virtual camera functionality"
|
||||
)
|
||||
endif()
|
||||
if(LibObs_VERSION_MAJOR GREATER_EQUAL 26)
|
||||
add_definitions(-DREPLAYBUFFER_SUPPORTED)
|
||||
else()
|
||||
message(
|
||||
WARNING
|
||||
"OBS version ${LibObs_VERSION_MAJOR} found - disabling replay buffer functionality"
|
||||
)
|
||||
endif()
|
||||
else()
|
||||
find_package(Libcurl REQUIRED)
|
||||
include_directories("${LIBCURL_INCLUDE_DIRS}")
|
||||
|
|
@ -384,6 +366,30 @@ else()
|
|||
src/headers/macro-condition-video.hpp)
|
||||
endif()
|
||||
|
||||
# Backwards compatability checks with older OBS versions
|
||||
if(DEFINED LibObs_VERSION_MAJOR)
|
||||
if(LibObs_VERSION_MAJOR GREATER_EQUAL 27)
|
||||
add_definitions(-DVCAM_SUPPORTED)
|
||||
else()
|
||||
message(
|
||||
WARNING
|
||||
"OBS version ${LibObs_VERSION_MAJOR} found - disabling virtual camera functionality"
|
||||
)
|
||||
endif()
|
||||
if(LibObs_VERSION_MAJOR GREATER_EQUAL 26)
|
||||
add_definitions(-DREPLAYBUFFER_SUPPORTED)
|
||||
else()
|
||||
message(
|
||||
WARNING
|
||||
"OBS version ${LibObs_VERSION_MAJOR} found - disabling replay buffer and screenshot functionality"
|
||||
)
|
||||
list(REMOVE_ITEM advanced-scene-switcher_SOURCES
|
||||
src/macro-action-screenshot.cpp)
|
||||
list(REMOVE_ITEM advanced-scene-switcher_HEADERS
|
||||
src/headers/macro-action-screenshot.hpp)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_library(
|
||||
advanced-scene-switcher MODULE
|
||||
${advanced-scene-switcher_HEADERS}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user