Updated build steps
Some checks failed
CI / Native Windows Build And Tests (push) Has been cancelled
CI / React UI Build (push) Has been cancelled
CI / Windows Release Package (push) Has been cancelled

This commit is contained in:
2026-05-05 21:39:33 +10:00
parent 1cde845a77
commit 119e49aec1
2 changed files with 45 additions and 2 deletions

View File

@@ -8,6 +8,7 @@ set(CMAKE_CXX_EXTENSIONS OFF)
set(APP_DIR "${CMAKE_CURRENT_SOURCE_DIR}/apps/LoopThroughWithOpenGLCompositing") set(APP_DIR "${CMAKE_CURRENT_SOURCE_DIR}/apps/LoopThroughWithOpenGLCompositing")
set(GPUDIRECT_DIR "${CMAKE_CURRENT_SOURCE_DIR}/3rdParty/Blackmagic DeckLink SDK 16.0/Win/Samples/NVIDIA_GPUDirect" CACHE PATH "Path to the NVIDIA_GPUDirect sample directory from the Blackmagic DeckLink SDK") set(GPUDIRECT_DIR "${CMAKE_CURRENT_SOURCE_DIR}/3rdParty/Blackmagic DeckLink SDK 16.0/Win/Samples/NVIDIA_GPUDirect" CACHE PATH "Path to the NVIDIA_GPUDirect sample directory from the Blackmagic DeckLink SDK")
set(SLANG_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/3rdParty/slang-2026.8-windows-x86_64" CACHE PATH "Path to a Slang binary release containing bin/slangc.exe")
if(NOT EXISTS "${APP_DIR}/LoopThroughWithOpenGLCompositing.cpp") if(NOT EXISTS "${APP_DIR}/LoopThroughWithOpenGLCompositing.cpp")
message(FATAL_ERROR "Imported app sources were not found under ${APP_DIR}") message(FATAL_ERROR "Imported app sources were not found under ${APP_DIR}")
@@ -17,6 +18,23 @@ if(NOT EXISTS "${GPUDIRECT_DIR}/lib/x64/dvp.lib")
message(FATAL_ERROR "NVIDIA GPUDirect library not found under ${GPUDIRECT_DIR}") message(FATAL_ERROR "NVIDIA GPUDirect library not found under ${GPUDIRECT_DIR}")
endif() endif()
set(SLANG_RUNTIME_FILES
"${SLANG_ROOT}/bin/slangc.exe"
"${SLANG_ROOT}/bin/slang-compiler.dll"
"${SLANG_ROOT}/bin/slang-glslang.dll"
)
foreach(SLANG_RUNTIME_FILE IN LISTS SLANG_RUNTIME_FILES)
if(NOT EXISTS "${SLANG_RUNTIME_FILE}")
message(FATAL_ERROR "Required Slang runtime file not found: ${SLANG_RUNTIME_FILE}")
endif()
endforeach()
set(SLANG_LICENSE_FILE "${SLANG_ROOT}/LICENSE")
if(NOT EXISTS "${SLANG_LICENSE_FILE}")
message(FATAL_ERROR "Slang license file not found: ${SLANG_LICENSE_FILE}")
endif()
set(APP_SOURCES set(APP_SOURCES
"${APP_DIR}/ControlServer.cpp" "${APP_DIR}/ControlServer.cpp"
"${APP_DIR}/ControlServer.h" "${APP_DIR}/ControlServer.h"
@@ -161,6 +179,15 @@ install(FILES "${GPUDIRECT_DIR}/bin/x64/dvp.dll"
DESTINATION "." DESTINATION "."
) )
install(FILES ${SLANG_RUNTIME_FILES}
DESTINATION "3rdParty/slang/bin"
)
install(FILES "${SLANG_LICENSE_FILE}"
DESTINATION "third_party_notices"
RENAME "SLANG_LICENSE.txt"
)
install(DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/config/" install(DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/config/"
DESTINATION "config" DESTINATION "config"
) )

View File

@@ -21,7 +21,7 @@ The app loads shader packages from `shaders/`, compiles Slang to GLSL at runtime
- CMake 3.24 or newer. - CMake 3.24 or newer.
- Node.js and npm for the control UI. - Node.js and npm for the control UI.
- Blackmagic DeckLink SDK 16.0 with the NVIDIA GPUDirect sample files available locally. - Blackmagic DeckLink SDK 16.0 with the NVIDIA GPUDirect sample files available locally.
- Slang compiler available under the repo/tooling paths expected by the runtime, or otherwise discoverable by the existing app setup. - Slang binary release with `slangc.exe`, `slang-compiler.dll`, `slang-glslang.dll`, and `LICENSE`.
The Blackmagic/GPUDirect SDK should not be committed to this repository. `CMakeLists.txt` exposes `GPUDIRECT_DIR` as a cache path so local machines and CI runners can point at their installed SDK location. The Blackmagic/GPUDirect SDK should not be committed to this repository. `CMakeLists.txt` exposes `GPUDIRECT_DIR` as a cache path so local machines and CI runners can point at their installed SDK location.
@@ -37,6 +37,18 @@ Override example:
cmake --preset vs2022-x64-debug -DGPUDIRECT_DIR="D:/SDKs/Blackmagic DeckLink SDK 16.0/Win/Samples/NVIDIA_GPUDirect" cmake --preset vs2022-x64-debug -DGPUDIRECT_DIR="D:/SDKs/Blackmagic DeckLink SDK 16.0/Win/Samples/NVIDIA_GPUDirect"
``` ```
Default expected Slang path:
```text
3rdParty/slang-2026.8-windows-x86_64
```
Override example:
```powershell
cmake --preset vs2022-x64-debug -DSLANG_ROOT="D:/SDKs/slang-2026.8-windows-x86_64"
```
## Build ## Build
Configure and build the native app: Configure and build the native app:
@@ -78,11 +90,15 @@ dist/VideoShader/
dvp.dll dvp.dll
config/ config/
shaders/ shaders/
3rdParty/slang/bin/
ui/dist/ ui/dist/
runtime/templates/ runtime/templates/
third_party_notices/
``` ```
You can run `LoopThroughWithOpenGLCompositing.exe` directly from that folder. In packaged mode, the app resolves `config/`, `shaders/`, `ui/dist/`, and `runtime/templates/` relative to the exe folder. In development mode, it still falls back to repo-root discovery. You can run `LoopThroughWithOpenGLCompositing.exe` directly from that folder. In packaged mode, the app resolves `config/`, `shaders/`, `3rdParty/slang/bin/slangc.exe`, `ui/dist/`, and `runtime/templates/` relative to the exe folder. In development mode, it still falls back to repo-root discovery.
The install step copies only the Slang runtime files required by the shader compiler (`slangc.exe`, `slang-compiler.dll`, and `slang-glslang.dll`) plus `third_party_notices/SLANG_LICENSE.txt`. It does not copy the full Slang release folder.
Create a zip for distribution: Create a zip for distribution: