Skip to content

Commit 4383f3d

Browse files
committed
Merge branch 'master' into master
2 parents eff0d35 + 0709990 commit 4383f3d

48 files changed

Lines changed: 4457 additions & 232 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ci-bundle.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
2323

2424
- name: Install npm dependencies
25-
run: npm install --ignore-scripts
25+
run: npm ci --ignore-scripts
2626

2727
- name: Debug install
2828
if: always()

.github/workflows/ci-flatpak.yml

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -44,18 +44,6 @@ jobs:
4444
with:
4545
submodules: recursive
4646

47-
- name: Setup node
48-
id: node
49-
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
50-
with:
51-
node-version: ${{ env.NODE_VERSION }}
52-
53-
- name: Install npm dependencies
54-
run: npm install --ignore-scripts --package-lock-only
55-
56-
- name: Debug package-lock.json
57-
run: cat package-lock.json
58-
5947
- name: Setup python
6048
id: python
6149
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
@@ -209,9 +197,9 @@ jobs:
209197
mkdir -p flathub/modules
210198
cp "./build/generated-sources.json" "./flathub/"
211199
cp "./build/glad-dependencies.json" "./flathub/"
212-
cp "./build/package-lock.json" "./flathub/"
213200
cp "./build/${APP_ID}.yml" "./flathub/"
214201
cp "./build/${APP_ID}.metainfo.xml" "./flathub/"
202+
cp "./package-lock.json" "./flathub/"
215203
cp "./packaging/linux/flatpak/README.md" "./flathub/"
216204
cp "./packaging/linux/flatpak/flathub.json" "./flathub/"
217205
cp -r "./packaging/linux/flatpak/modules/." "./flathub/modules/"

.github/workflows/ci-freebsd.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,7 @@ jobs:
173173
-DSUNSHINE_EXECUTABLE_PATH=/usr/local/bin/sunshine \
174174
-DSUNSHINE_ENABLE_CUDA=OFF \
175175
-DSUNSHINE_ENABLE_DRM=OFF \
176+
-DSUNSHINE_ENABLE_KWIN=ON \
176177
-DSUNSHINE_ENABLE_PORTAL=ON \
177178
-DSUNSHINE_ENABLE_WAYLAND=ON \
178179
-DSUNSHINE_ENABLE_X11=ON \

.github/workflows/ci-windows.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,6 @@ jobs:
111111
dependencies+=(
112112
"mingw-w64-${TOOLCHAIN}-MinHook"
113113
"mingw-w64-${TOOLCHAIN}-nsis"
114-
"mingw-w64-${TOOLCHAIN}-nodejs"
115114
)
116115
fi
117116
@@ -177,14 +176,11 @@ jobs:
177176
dotnet-version: '10.x'
178177

179178
- name: Setup NodeJS
180-
# Clang compiled NodeJS has issues when running rollup webpack
181-
if: matrix.msystem != 'ucrt64'
182179
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
183180
with:
184181
node-version: 'lts/*'
185182

186183
- name: NodeJS Path
187-
if: matrix.msystem != 'ucrt64'
188184
shell: pwsh
189185
run: |
190186
# get NodeJS PATH
@@ -226,10 +222,8 @@ jobs:
226222
COMMIT: ${{ inputs.release_commit }}
227223
run: |
228224
# setup NodeJS PATH
229-
if [[ "${MATRIX_MSYSTEM}" != "ucrt64" ]]; then
230-
NODEJS_PATH=$(cygpath "$NODEJS_PATH")
231-
export PATH="$PATH:$NODEJS_PATH"
232-
fi
225+
NODEJS_PATH=$(cygpath "$NODEJS_PATH")
226+
export PATH="$PATH:$NODEJS_PATH"
233227
234228
mkdir -p build
235229
cmake \

.github/workflows/release-notifier-moonlight.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ docs/doxyconfig*
4444

4545
# npm
4646
node_modules/
47-
package-lock.json
4847

4948
# Translations
5049
*.mo

.gitmodules

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@
4545
path = third-party/nvapi
4646
url = https://github.com/NVIDIA/nvapi.git
4747
branch = main
48+
[submodule "third-party/plasma-wayland-protocols"]
49+
path = third-party/plasma-wayland-protocols
50+
url = https://github.com/KDE/plasma-wayland-protocols.git
51+
branch = master
4852
[submodule "third-party/Simple-Web-Server"]
4953
path = third-party/Simple-Web-Server
5054
url = https://github.com/LizardByte-infrastructure/Simple-Web-Server.git

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,13 @@ LizardByte has the full documentation hosted on [Read the Docs](https://docs.liz
276276
<td>➖</td>
277277
<td>➖</td>
278278
</tr>
279+
<tr>
280+
<td>KWin Screencast</td>
281+
<td>✅</td>
282+
<td>✅</td>
283+
<td>➖</td>
284+
<td>➖</td>
285+
</tr>
279286
</table>
280287

281288
<table>
@@ -322,6 +329,13 @@ LizardByte has the full documentation hosted on [Read the Docs](https://docs.liz
322329
<td>✅</td>
323330
<td>✅</td>
324331
</tr>
332+
<tr>
333+
<td>KWin Screencast</td>
334+
<td>✅</td>
335+
<td>✅</td>
336+
<td>✅</td>
337+
<td>✅</td>
338+
</tr>
325339
</table>
326340

327341
**Legend:** ✅ Supported | 🟡 Partial Support | ❌ Not Yet Supported | ➖ Not Applicable

cmake/compile_definitions/linux.cmake

Lines changed: 30 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@ if(CUDA_FOUND)
7676
add_compile_definitions(SUNSHINE_BUILD_CUDA)
7777
endif()
7878

79-
# libdrm is required for both DRM (KMS) and Wayland
80-
if(${SUNSHINE_ENABLE_DRM} OR ${SUNSHINE_ENABLE_WAYLAND})
79+
# libdrm is required for DRM (KMS), KWin ScreenCast and Wayland
80+
if(${SUNSHINE_ENABLE_DRM} OR ${SUNSHINE_ENABLE_KWIN} OR ${SUNSHINE_ENABLE_WAYLAND})
8181
find_package(LIBDRM REQUIRED)
8282
else()
8383
set(LIBDRM_FOUND OFF)
@@ -122,8 +122,14 @@ endif()
122122

123123
# vulkan video encoding (via FFmpeg)
124124
if(${SUNSHINE_ENABLE_VULKAN})
125-
# use Vulkan headers from build-deps submodule (system headers may be too old, e.g. Ubuntu 22.04)
126-
set(VULKAN_HEADERS_DIR "${CMAKE_SOURCE_DIR}/third-party/build-deps/third-party/FFmpeg/Vulkan-Headers/include")
125+
if(NOT SUNSHINE_SYSTEM_VULKAN_HEADERS)
126+
# use Vulkan headers from build-deps submodule (system headers may be too old, e.g. Ubuntu 22.04)
127+
set(VULKAN_HEADERS_DIR "${CMAKE_SOURCE_DIR}/third-party/build-deps/third-party/FFmpeg/Vulkan-Headers/include")
128+
else()
129+
find_package(VulkanHeaders REQUIRED)
130+
get_target_property(VULKAN_HEADERS_DIR Vulkan::Headers INTERFACE_INCLUDE_DIRECTORIES)
131+
endif()
132+
127133
if(NOT EXISTS "${VULKAN_HEADERS_DIR}/vulkan/vulkan.h")
128134
message(FATAL_ERROR "Vulkan headers not found in build-deps submodule")
129135
endif()
@@ -243,7 +249,7 @@ if(GIO_FOUND)
243249
endif()
244250

245251
# Pipewire
246-
if(${SUNSHINE_ENABLE_PORTAL})
252+
if(${SUNSHINE_ENABLE_KWIN} OR ${SUNSHINE_ENABLE_PORTAL})
247253
pkg_check_modules(PIPEWIRE libpipewire-0.3 REQUIRED)
248254
else()
249255
set(PIPEWIRE_FOUND OFF)
@@ -264,13 +270,27 @@ if(PIPEWIRE_FOUND AND GIO_FOUND AND ${SUNSHINE_ENABLE_PORTAL})
264270
"${CMAKE_SOURCE_DIR}/src/platform/linux/portalgrab.cpp")
265271
endif()
266272

273+
# KWin ScreenCast (direct Wayland protocol, bypasses portal)
274+
set(KWIN_FOUND OFF)
275+
if(PIPEWIRE_FOUND AND WAYLAND_FOUND AND ${SUNSHINE_ENABLE_KWIN})
276+
set(KWIN_FOUND ON)
277+
add_compile_definitions(SUNSHINE_BUILD_KWIN)
278+
GEN_WAYLAND("${CMAKE_SOURCE_DIR}/third-party/plasma-wayland-protocols/src/protocols" "" kde-output-order-v1)
279+
GEN_WAYLAND("${CMAKE_SOURCE_DIR}/third-party/plasma-wayland-protocols/src/protocols" "" zkde-screencast-unstable-v1)
280+
list(APPEND PLATFORM_TARGET_FILES
281+
"${CMAKE_SOURCE_DIR}/src/platform/linux/kwingrab.cpp")
282+
elseif(${SUNSHINE_ENABLE_KWIN} AND NOT WAYLAND_FOUND)
283+
message(FATAL_ERROR "SUNSHINE_ENABLE_KWIN requires SUNSHINE_ENABLE_WAYLAND — KWin capture disabled")
284+
endif()
285+
267286
if(NOT ${CUDA_FOUND}
268-
AND NOT ${WAYLAND_FOUND}
269-
AND NOT ${X11_FOUND}
270-
AND NOT ${PORTAL_FOUND}
271287
AND NOT (${LIBDRM_FOUND} AND ${LIBCAP_FOUND})
272-
AND NOT ${LIBVA_FOUND})
273-
message(FATAL_ERROR "Couldn't find either cuda, libva, pipewire, wayland, x11, or (libdrm and libcap)")
288+
AND NOT ${LIBVA_FOUND}
289+
AND NOT ${KWIN_FOUND}
290+
AND NOT ${PORTAL_FOUND}
291+
AND NOT ${WAYLAND_FOUND}
292+
AND NOT ${X11_FOUND})
293+
message(FATAL_ERROR "Couldn't find either cuda, (libdrm and libcap), libva, kwin, pipewire, portal, wayland or x11")
274294
endif()
275295

276296
# tray icon

cmake/packaging/linux.cmake

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,10 @@ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_FQDN}.desktop"
173173
if(NOT ${SUNSHINE_BUILD_APPIMAGE} AND NOT ${SUNSHINE_BUILD_FLATPAK})
174174
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_FQDN}.terminal.desktop"
175175
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/applications")
176+
if(${SUNSHINE_ENABLE_KWIN})
177+
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_FQDN}.kwin.desktop"
178+
DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/applications")
179+
endif()
176180
endif()
177181

178182
# metadata file

0 commit comments

Comments
 (0)