@@ -3,6 +3,8 @@ project(obs-browser)
3
3
option (ENABLE_BROWSER "Enable building OBS with browser source plugin (required Chromium Embedded Framework)"
4
4
${OS_LINUX} )
5
5
6
+ add_subdirectory (lib)
7
+
6
8
if (NOT ENABLE_BROWSER OR NOT ENABLE_UI)
7
9
message (STATUS "OBS: DISABLED obs-browser" )
8
10
message (
@@ -54,6 +56,8 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/browser-config.h.in ${CMAKE_BINARY_DI
54
56
target_sources (
55
57
obs-browser
56
58
PRIVATE obs-browser-plugin.cpp
59
+ obs-browser-api-impl.cpp
60
+ obs-browser-api-impl.hpp
57
61
obs-browser-source .cpp
58
62
obs-browser-source .hpp
59
63
obs-browser-source -audio.cpp
@@ -76,13 +80,13 @@ target_sources(
76
80
77
81
target_include_directories (obs-browser PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} /deps ${CMAKE_BINARY_DIR} /config)
78
82
79
- target_link_libraries (obs-browser PRIVATE OBS::libobs OBS::frontend-api nlohmann_json::nlohmann_json)
83
+ target_link_libraries (obs-browser PRIVATE OBS::libobs OBS::frontend-api OBS::browser-api nlohmann_json::nlohmann_json)
80
84
81
85
target_compile_features (obs-browser PRIVATE cxx_std_17)
82
86
83
- if (ENABLE_BROWSER_PANELS OR ENABLE_BROWSER_QT_LOOP)
84
- find_qt(COMPONENTS Widgets)
87
+ find_qt(COMPONENTS Widgets)
85
88
89
+ if (ENABLE_BROWSER_PANELS OR ENABLE_BROWSER_QT_LOOP)
86
90
set_target_properties (
87
91
obs-browser
88
92
PROPERTIES AUTOMOC ON
@@ -251,6 +255,8 @@ if(ENABLE_BROWSER_PANELS)
251
255
252
256
target_compile_definitions (obs-browser-panels INTERFACE BROWSER_AVAILABLE)
253
257
258
+ target_sources (obs-browser PRIVATE obs-browser-api-impl-panel.cpp obs-browser-api-impl.cpp)
259
+
254
260
if (ENABLE_BROWSER_QT_LOOP)
255
261
target_compile_definitions (obs-browser-panels INTERFACE ENABLE_BROWSER_QT_LOOP)
256
262
endif ()
0 commit comments