Skip to content

Commit b2c7886

Browse files
committed
0.31.3
1 parent ed62a4e commit b2c7886

33 files changed

+1177
-847
lines changed

.gitignore

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
# Exclude everything
1+
# ignore everything
22
/*
3+
/.*
34

45
# Except for default project files
56
!/.github
@@ -25,17 +26,3 @@
2526

2627
!/lib
2728
!.vscode
28-
29-
# Exclude lock files
30-
*.lock.json
31-
32-
# Exclude macOS legacy resource forks
33-
.DS_Store
34-
35-
36-
37-
# Exclude generated packages
38-
/packages
39-
40-
# Exclude dependency cache (now in build directories)
41-
/.deps

CMakeLists.txt

Lines changed: 17 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -22,48 +22,27 @@ include(helpers)
2222
file(READ "${CMAKE_SOURCE_DIR}/buildspec.json" buildspec)
2323
string(JSON QT6_VERSION GET ${buildspec} dependencies qt6 version)
2424

25-
# Define architecture-specific dependency directory in the build directory
26-
# Use CMAKE_BINARY_DIR so it works with any configured build directory
27-
set(DEPS_DIR "${CMAKE_BINARY_DIR}/obs-deps")
25+
# Persistent dependency directory (survives cache clears)
26+
if(WIN32)
27+
set(DEPS_DIR "${CMAKE_SOURCE_DIR}/_deps/${CMAKE_VS_PLATFORM_NAME}")
28+
else()
29+
set(DEPS_DIR "${CMAKE_SOURCE_DIR}/_deps")
30+
endif()
2831

29-
# Configure Qt paths for cross-compilation on Windows
32+
# Qt paths for Windows builds
3033
if(WIN32)
3134
if(CMAKE_VS_PLATFORM_NAME STREQUAL "ARM64")
32-
# ARM64 Cross-compilation setup
33-
set(QT_HOST_PATH "${DEPS_DIR}/obs-deps-qt6-${QT6_VERSION}-x64")
34-
set(Qt6_DIR "${DEPS_DIR}/obs-deps-qt6-${QT6_VERSION}-ARM64/lib/cmake/Qt6" CACHE STRING "Qt6 ARM64 CMake directory" FORCE)
35-
36-
message(STATUS "ARM64 Cross-compilation detected")
37-
message(STATUS "QT_HOST_PATH: ${QT_HOST_PATH}")
38-
message(STATUS "Qt6_DIR: ${Qt6_DIR}")
39-
40-
# Check if x64 Qt host tools exist
41-
if(EXISTS "${QT_HOST_PATH}/bin/moc.exe")
42-
message(STATUS "Found x64 Qt host tools at: ${QT_HOST_PATH}")
43-
else()
44-
message(FATAL_ERROR "x64 Qt host tools not found at: ${QT_HOST_PATH}. ARM64 cross-compilation requires both x64 and ARM64 Qt dependencies.")
45-
endif()
46-
47-
# Set Qt host tools for cross-compilation (use x64 tools for ARM64 builds)
48-
set(Qt6CoreTools_DIR "${QT_HOST_PATH}/lib/cmake/Qt6CoreTools" CACHE STRING "Qt6 x64 Core Tools" FORCE)
49-
set(Qt6GuiTools_DIR "${QT_HOST_PATH}/lib/cmake/Qt6GuiTools" CACHE STRING "Qt6 x64 GUI Tools" FORCE)
50-
set(Qt6WidgetsTools_DIR "${QT_HOST_PATH}/lib/cmake/Qt6WidgetsTools" CACHE STRING "Qt6 x64 Widget Tools" FORCE)
51-
52-
# Explicitly set tool executables that AUTOMOC/AUTOUIC/AUTORCC will use
53-
set(CMAKE_AUTOMOC_MOC_EXECUTABLE "${QT_HOST_PATH}/bin/moc.exe" CACHE FILEPATH "MOC executable for ARM64 cross-compilation" FORCE)
54-
set(CMAKE_AUTOUIC_UIC_EXECUTABLE "${QT_HOST_PATH}/bin/uic.exe" CACHE FILEPATH "UIC executable for ARM64 cross-compilation" FORCE)
55-
set(CMAKE_AUTORCC_RCC_EXECUTABLE "${QT_HOST_PATH}/bin/rcc.exe" CACHE FILEPATH "RCC executable for ARM64 cross-compilation" FORCE)
56-
57-
# Also set the legacy variables for compatibility
58-
set(QT_MOC_EXECUTABLE "${QT_HOST_PATH}/bin/moc.exe")
59-
set(QT_RCC_EXECUTABLE "${QT_HOST_PATH}/bin/rcc.exe")
60-
set(QT_UIC_EXECUTABLE "${QT_HOST_PATH}/bin/uic.exe")
61-
62-
message(STATUS "Set CMAKE_AUTOMOC_MOC_EXECUTABLE to: ${CMAKE_AUTOMOC_MOC_EXECUTABLE}")
35+
# ARM64 cross-compilation: use x64 Qt tools with ARM64 libraries
36+
set(QT_HOST_PATH "${CMAKE_SOURCE_DIR}/_deps/x64/obs-deps-qt6-${QT6_VERSION}-x64")
37+
set(Qt6_DIR "${DEPS_DIR}/obs-deps-qt6-${QT6_VERSION}-ARM64/lib/cmake/Qt6" CACHE PATH "" FORCE)
38+
set(Qt6CoreTools_DIR "${QT_HOST_PATH}/lib/cmake/Qt6CoreTools" CACHE PATH "" FORCE)
39+
set(Qt6GuiTools_DIR "${QT_HOST_PATH}/lib/cmake/Qt6GuiTools" CACHE PATH "" FORCE)
40+
set(Qt6WidgetsTools_DIR "${QT_HOST_PATH}/lib/cmake/Qt6WidgetsTools" CACHE PATH "" FORCE)
41+
set(CMAKE_AUTOMOC_MOC_EXECUTABLE "${QT_HOST_PATH}/bin/moc.exe" CACHE FILEPATH "" FORCE)
42+
set(CMAKE_AUTOUIC_UIC_EXECUTABLE "${QT_HOST_PATH}/bin/uic.exe" CACHE FILEPATH "" FORCE)
43+
set(CMAKE_AUTORCC_RCC_EXECUTABLE "${QT_HOST_PATH}/bin/rcc.exe" CACHE FILEPATH "" FORCE)
6344
else()
64-
# x64 build - set paths to x64 Qt
65-
set(Qt6_DIR "${DEPS_DIR}/obs-deps-qt6-${QT6_VERSION}-x64/lib/cmake/Qt6" CACHE STRING "Qt6 x64 CMake directory" FORCE)
66-
message(STATUS "x64 build detected - using x64 Qt at: ${Qt6_DIR}")
45+
set(Qt6_DIR "${DEPS_DIR}/obs-deps-qt6-${QT6_VERSION}-x64/lib/cmake/Qt6" CACHE PATH "" FORCE)
6746
endif()
6847
endif()
6948

CMakePresets.json

Lines changed: 21 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,16 @@
1414
"ENABLE_FRONTEND_API": true
1515
}
1616
},
17+
{
18+
"name": "ci-template",
19+
"hidden": true,
20+
"environment": {
21+
"CI": "true"
22+
},
23+
"cacheVariables": {
24+
"CMAKE_COMPILE_WARNING_AS_ERROR": false
25+
}
26+
},
1727
{
1828
"name": "ubuntu-cross-compile-template",
1929
"hidden": true,
@@ -64,13 +74,13 @@
6474
{
6575
"name": "macos-ci",
6676
"inherits": [
67-
"macos"
77+
"macos",
78+
"ci-template"
6879
],
6980
"displayName": "macOS Universal CI build",
7081
"description": "Build for macOS 12.0+ (Universal binary) for CI",
7182
"generator": "Xcode",
7283
"cacheVariables": {
73-
"CMAKE_COMPILE_WARNING_AS_ERROR": false,
7484
"CMAKE_OSX_DEPLOYMENT_TARGET": "12.0"
7585
}
7686
},
@@ -100,13 +110,11 @@
100110
{
101111
"name": "windows-ci-x64",
102112
"inherits": [
103-
"windows-x64"
113+
"windows-x64",
114+
"ci-template"
104115
],
105116
"displayName": "Windows x64 CI build",
106-
"description": "Build for Windows x64 on CI",
107-
"cacheVariables": {
108-
"CMAKE_COMPILE_WARNING_AS_ERROR": false
109-
}
117+
"description": "Build for Windows x64 on CI"
110118
},
111119
{
112120
"name": "windows-arm64",
@@ -134,13 +142,11 @@
134142
{
135143
"name": "windows-ci-arm64",
136144
"inherits": [
137-
"windows-arm64"
145+
"windows-arm64",
146+
"ci-template"
138147
],
139148
"displayName": "Windows ARM64 CI build",
140-
"description": "Build for Windows ARM64 on CI",
141-
"cacheVariables": {
142-
"CMAKE_COMPILE_WARNING_AS_ERROR": false
143-
}
149+
"description": "Build for Windows ARM64 on CI"
144150
},
145151
{
146152
"name": "ubuntu-x86_64",
@@ -169,14 +175,11 @@
169175
{
170176
"name": "ubuntu-ci-x86_64",
171177
"inherits": [
172-
"ubuntu-x86_64"
178+
"ubuntu-x86_64",
179+
"ci-template"
173180
],
174181
"displayName": "Ubuntu x86_64 CI build",
175-
"description": "Build for Ubuntu x86_64 on CI",
176-
"cacheVariables": {
177-
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
178-
"CMAKE_COMPILE_WARNING_AS_ERROR": false
179-
}
182+
"description": "Build for Ubuntu x86_64 on CI"
180183
}
181184
],
182185
"buildPresets": [
@@ -201,13 +204,6 @@
201204
"description": "Windows build for x64",
202205
"configuration": "RelWithDebInfo"
203206
},
204-
{
205-
"name": "windows-x64-release",
206-
"configurePreset": "windows-x64",
207-
"displayName": "Windows x64 Release",
208-
"description": "Windows build for x64",
209-
"configuration": "Release"
210-
},
211207
{
212208
"name": "windows-ci-x64",
213209
"configurePreset": "windows-ci-x64",
@@ -222,13 +218,6 @@
222218
"description": "Windows build for ARM64",
223219
"configuration": "RelWithDebInfo"
224220
},
225-
{
226-
"name": "windows-arm64-release",
227-
"configurePreset": "windows-arm64",
228-
"displayName": "Windows ARM64 Release",
229-
"description": "Windows build for ARM64",
230-
"configuration": "Release"
231-
},
232221
{
233222
"name": "windows-ci-arm64",
234223
"configurePreset": "windows-ci-arm64",

README.md

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,19 @@ Develop your own audio processing plugins and integrate them into `PluginHost2`
3232

3333
## Audio Source Mixer (OBS Source)
3434

35-
- Mix audio from up to 8 OBS sources into a new OBS audio source
36-
- E.g. allows creating new submixes
37-
- Can be used as 'dummy' source to host Device IO
35+
- Mix audio from OBS sources into a new OBS audio source
36+
- Can be used as 'dummy' source to host filters, e.g. PluginHost2
37+
38+
## Usage examples
39+
40+
- Use Delay filter to manually delay/sync individual audio sources
41+
- Source Mixer can create submixes (or one main mix) from multiple OBS audio sources
42+
- Mute original sources to prevent double/parallel audio
43+
- Use DeviceIo2 to route audio directly between OBS and audio devices (e.g. ASIO)
44+
- Put CPU intensive plugins into PluginHost and enable MT for better performance (multi-core, one buffer extra latency)
45+
- Use a sampler plugin with a MIDI keyboard in PluginHost as a soundboard
46+
- Do all of the above and more with PluginHost2
47+
- MIDI control of OBS audio source volume & mute
3848

3949
## Build instructions
4050

buildspec.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,6 @@
4747
"uuids": {
4848
"windowsApp": "ad885c58-5ca9-44de-8f4f-1c12676626a9"
4949
},
50-
"version": "0.31.2",
50+
"version": "0.31.3",
5151
"website": "https://www.atkaudio.com"
5252
}

cmake/macos/buildspec.cmake

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ function(_check_dependencies_macos)
1111

1212
file(READ "${CMAKE_CURRENT_SOURCE_DIR}/buildspec.json" buildspec)
1313

14-
# Use build-directory-specific dependency directory
15-
set(dependencies_dir "${CMAKE_BINARY_DIR}/obs-deps")
14+
# Use source-directory-based dependency directory to persist across cache clears
15+
set(dependencies_dir "${CMAKE_SOURCE_DIR}/_deps")
1616
set(prebuilt_filename "macos-deps-VERSION-ARCH_REVISION.tar.xz")
1717
set(prebuilt_destination "obs-deps-VERSION-ARCH")
1818
set(qt6_filename "macos-deps-qt6-VERSION-ARCH-REVISION.tar.xz")
@@ -23,10 +23,9 @@ function(_check_dependencies_macos)
2323

2424
_check_dependencies()
2525

26+
# Remove quarantine flags from downloaded dependencies (ignore errors on read-only git pack files)
2627
execute_process(
27-
COMMAND "xattr" -r -d com.apple.quarantine "${dependencies_dir}"
28-
RESULT_VARIABLE result
29-
COMMAND_ERROR_IS_FATAL ANY
28+
COMMAND bash -c "find '${dependencies_dir}' -not -path '*/.git/*' -exec xattr -d com.apple.quarantine {} \\; 2>/dev/null || true"
3029
)
3130

3231
list(APPEND CMAKE_FRAMEWORK_PATH "${dependencies_dir}/Frameworks")

cmake/windows/buildspec.cmake

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ function(_check_dependencies_windows)
99
set(arch ${CMAKE_VS_PLATFORM_NAME})
1010
set(platform windows-${arch})
1111

12-
# Use build-directory-specific dependency directories to avoid conflicts
13-
set(dependencies_dir "${CMAKE_BINARY_DIR}/obs-deps")
12+
# Use source-directory-based dependency directory to persist across cache clears
13+
set(dependencies_dir "${CMAKE_SOURCE_DIR}/_deps/${arch}")
1414
set(prebuilt_filename "windows-deps-VERSION-ARCH-REVISION.zip")
1515
set(prebuilt_destination "obs-deps-VERSION-ARCH")
1616
set(qt6_filename "windows-deps-qt6-VERSION-ARCH-REVISION.zip")
@@ -34,8 +34,8 @@ endfunction()
3434
function(_download_x64_qt_for_arm64)
3535
set(arch "x64")
3636
set(platform "windows-x64")
37-
# Store x64 tools in the build deps directory for cross-compilation
38-
set(dependencies_dir "${CMAKE_BINARY_DIR}/obs-deps")
37+
# Store x64 tools in a persistent deps directory for cross-compilation
38+
set(dependencies_dir "${CMAKE_SOURCE_DIR}/_deps/x64")
3939
set(qt6_filename "windows-deps-qt6-VERSION-ARCH-REVISION.zip")
4040
set(qt6_destination "obs-deps-qt6-VERSION-ARCH")
4141
set(dependencies_list qt6)

lib/atkaudio/CMakeLists.txt

Lines changed: 21 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,15 @@ set(target ${PROJECT_NAME})
1717
# Always use JUCE modules only (no helper tools)
1818
set(JUCE_MODULES_ONLY ON CACHE BOOL "Only build JUCE modules" FORCE)
1919

20+
# Store FetchContent downloads in _deps to persist across cache clears
21+
set(FETCHCONTENT_BASE_DIR "${CMAKE_SOURCE_DIR}/_deps" CACHE PATH "" FORCE)
22+
2023
include(FetchContent)
2124
FetchContent_Declare(
2225
juce
2326
EXCLUDE_FROM_ALL
2427
GIT_REPOSITORY https://github.com/juce-framework/JUCE.git
25-
GIT_TAG master
26-
GIT_SHALLOW TRUE
28+
GIT_TAG 230340dbfc580628596243bb63b31aeb4d6b5a6d # develop 2025-11-27
2729
)
2830
FetchContent_MakeAvailable(juce)
2931
# _juce_initialise_target(${target} ${target})
@@ -52,6 +54,8 @@ target_compile_definitions(
5254
JUCE_MODAL_LOOPS_PERMITTED=1 # we use QT event loop, so this is needed
5355
# Disable DBG() output in CI/GitHub Actions RelWithDebInfo builds (keeps debug symbols but no console spam in CI)
5456
$<$<AND:$<CONFIG:RelWithDebInfo>,$<OR:$<BOOL:$ENV{CI}>,$<BOOL:$ENV{GITHUB_ACTIONS}>>>:JUCE_DISABLE_ASSERTIONS>
57+
# SIMULATE_UPDATE_CHECK # Uncomment to test update dialog without network
58+
SIMULATE_UPDATE_CHECK # Testing update dialog
5559
)
5660

5761
set_target_properties(${PROJECT_NAME} PROPERTIES
@@ -91,42 +95,25 @@ if(NOT WIN32)
9195
)
9296
endif()
9397

94-
# ASIO SDK is only needed on Windows
98+
# ASIO SDK (Windows only)
9599
if(WIN32)
96-
set(ASIO_SDK_URL "https://www.steinberg.net/asiosdk")
97-
set(ASIO_SDK_TEMPDIR "${CMAKE_CURRENT_BINARY_DIR}/asiosdk_temp")
98-
set(ASIO_SDK_DIR "${CMAKE_CURRENT_BINARY_DIR}/asiosdk")
99-
100+
set(ASIO_SDK_DIR "${CMAKE_SOURCE_DIR}/_deps/asiosdk")
100101
if(NOT EXISTS "${ASIO_SDK_DIR}")
102+
set(_asio_zip "${CMAKE_SOURCE_DIR}/_deps/asiosdk.zip")
103+
set(_asio_temp "${CMAKE_SOURCE_DIR}/_deps/asiosdk_temp")
101104
message(STATUS "Downloading ASIO SDK...")
102-
file(DOWNLOAD "${ASIO_SDK_URL}" "${CMAKE_CURRENT_BINARY_DIR}/asiosdk.zip"
103-
STATUS download_status
104-
SHOW_PROGRESS
105-
)
106-
if(download_status)
107-
message(STATUS "Extracting ASIO SDK...")
108-
file(ARCHIVE_EXTRACT
109-
INPUT "${CMAKE_CURRENT_BINARY_DIR}/asiosdk.zip"
110-
DESTINATION "${ASIO_SDK_TEMPDIR}"
111-
)
112-
file(GLOB ASIO_SDK_DIRS "${ASIO_SDK_TEMPDIR}/*")
113-
foreach(dir ${ASIO_SDK_DIRS})
114-
if(IS_DIRECTORY ${dir} AND dir MATCHES ".*asiosdk.*")
115-
message(STATUS "ASIO SDK extracted to ${dir}")
116-
file(RENAME ${dir} ${ASIO_SDK_DIR})
117-
break()
118-
endif()
119-
endforeach()
105+
file(DOWNLOAD "https://www.steinberg.net/asiosdk" "${_asio_zip}" STATUS _status SHOW_PROGRESS)
106+
list(GET _status 0 _code)
107+
if(_code EQUAL 0)
108+
file(ARCHIVE_EXTRACT INPUT "${_asio_zip}" DESTINATION "${_asio_temp}")
109+
file(GLOB _dirs "${_asio_temp}/*")
110+
list(GET _dirs 0 _extracted)
111+
file(RENAME "${_extracted}" "${ASIO_SDK_DIR}")
112+
file(REMOVE_RECURSE "${_asio_temp}" "${_asio_zip}")
113+
message(STATUS "ASIO SDK installed to ${ASIO_SDK_DIR}")
120114
endif()
121115
endif()
122-
123-
target_include_directories(
124-
${PROJECT_NAME}
125-
PRIVATE
126-
${CMAKE_CURRENT_BINARY_DIR}/asiosdk/common
127-
)
128-
129-
target_include_directories(${PROJECT_NAME} PRIVATE "${ASIO_SDK_DIR}")
116+
target_include_directories(${PROJECT_NAME} PRIVATE "${ASIO_SDK_DIR}/common")
130117
endif()
131118

132119
if(WIN32)
@@ -142,4 +129,4 @@ endif()
142129

143130
target_compile_definitions(${PROJECT_NAME} PRIVATE JUCE_ASIO=1)
144131

145-
file(COPY_FILE ${CMAKE_SOURCE_DIR}/LICENSE ${CMAKE_BINARY_DIR}/INSTALLER-LICENSE)
132+
file(COPY_FILE ${CMAKE_SOURCE_DIR}/LICENSE ${CMAKE_BINARY_DIR}/INSTALLER-LICENSE)

lib/atkaudio/cmake/cpack.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,7 @@ set(CPACK_NSIS_DISPLAY_NAME "${DISPLAYNAME}")
295295
set(CPACK_NSIS_UNINSTALL_NAME "Uninstall ${DISPLAYNAME}")
296296
set(CPACK_NSIS_INSTALL_ROOT "$COMMONPROGRAMDATA\\obs-studio\\plugins")
297297
set(CPACK_NSIS_BRANDING_TEXT " ")
298+
set(CPACK_NSIS_COMPRESSOR "zlib")
298299
file(TO_NATIVE_PATH "${CPACK_NSIS_INSTALL_ROOT}" CPACK_NSIS_INSTALL_ROOT)
299300
string(REPLACE "\\" "\\\\" CPACK_NSIS_INSTALL_ROOT "${CPACK_NSIS_INSTALL_ROOT}")
300301

0 commit comments

Comments
 (0)