Commit Graph
477 Commits
Author SHA1 Message Date
Carlos BarreroandClaude Opus 5 bfb7645cd1 fix(linux/audio): capture in the canonical channel layout
The PulseAudio backend built the capture stream's channel map from the Opus
channel mapping. That mapping is applied by the multistream encoder in
audio.cpp and undone by the client when it decodes, so the two cancel out.
Using it as the capture channel map makes PulseAudio reorder the samples as
well, and that second reordering is never undone.

It is invisible with the built-in mappings, which are all identities, so it
went unnoticed until custom surround-params arrived in #2424. A client that
requests its own mapping gets permuted channels: the webOS Moonlight client
asks for 0,1,4,5,2,3 and ends up with centre on rear left, rear left on
centre, LFE on rear right and rear right on the subwoofer.

Capture in the canonical layout instead, which is what the WASAPI and macOS
backends already do by ignoring the mapping argument entirely. Since
map_stereo, map_surround51 and map_surround71 are all the identity over
speaker_e, the canonical position of channel i is position_mapping[i], so
the map is now filled directly from the channel index.

Clients that do not send surroundParams are unaffected: the resulting
pa_channel_map is identical to the current one for every layout in
stream_configs. No other Moonlight client sends surroundParams today;
android, ios, qt, embedded and tizen send only the standard
surroundAudioInfo.

The map construction moves into fill_canonical_channel_map() so it can be
tested without a running PulseAudio server, and position_mapping becomes a
std::array bounded by speaker::MAX_SPEAKERS so the parallel-array
relationship with speaker_e is enforced by the compiler. Out-of-range
channel counts are now rejected rather than read past the end.

Refs: https://github.com/mariotaku/moonlight-tv/issues/575

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-10-09 15:51:12 -04:00
Raphael Derosso Pereira 899095522a fix(linux): close the DRM render-node fd owned by wl::dmabuf_t (#5764)
Signed-off-by: Raphael Derosso Pereira <raphael@insignis.com.br>
2026-10-09 12:52:40 -04:00
Alex Ford fd45d2dd85 feat(windows): add externally managed audio capture (#5647) 2026-10-09 09:21:47 -04:00
eastginza 31da0d8db9 fix(windows): correct shader selection for sRGB-encoded FP16 framebuffer (Win11 SDR) (#5106) 2026-10-09 00:38:48 -04:00
Dave Lane db1e08d5b7 fix(input): target mouse input at the streamed display (#5739) 2026-10-08 22:54:42 -04:00
neatnoise 3f2e767a7b feat(linux/wlr): enable Vulkan encoding for wlroots capture (#5734) 2026-10-07 12:20:41 -04:00
Conn O'Griofa 5e13eb6799 fix(linux): radv: don't force video_encode on autoprobe (#5849) 2026-10-03 18:16:27 -04:00
Conn O'Griofa efe624ffc7 fix(linux/vaapi): adjust balanced preset; don't try to override default quality (#5847) 2026-10-03 11:12:22 -04:00
neatnoise d41a2a32ca feat(vulkan): add vk_quality config option (#5783) 2026-09-28 23:44:53 -04:00
Dave Lane 2435fb421d fix(input): honor extended keyboard modifier (#5821) 2026-09-28 21:43:24 -04:00
Dave Lane 052b413216 feat(permissions): expose platform access and restart after grants (#5820) 2026-09-28 21:42:59 -04:00
Conn O'Griofa 1222ff62ab fix(linux/portalgrab): don't use TaskPool for xdg_worker thread. (#5822) 2026-09-28 09:35:35 -04:00
Dave Lane 8fc40974c9 feat(macos): add gamepad support using libvirtualhid (#5807) 2026-09-27 16:20:34 -04:00
Conn O'Griofa e1e6700bbb feat(linux/pipewire): add pts passthrough whitelist, cleanups (#5791) 2026-09-25 16:24:14 -04:00
Conn O'Griofa 55d6c0f878 feat(linux): Portal capture fallback support, misc fixes (#5774) 2026-09-25 14:47:58 -04:00
Dave LaneandAndy Grundman 6d4a95955e build(macOS): remove zero-initialization (#5744)
Co-authored-by: Andy Grundman <105828+andygrundman@users.noreply.github.com>
2026-09-17 14:56:47 -04:00
Dave Lane f54f9dfc57 chore(deps): move boost to CPM and bump to 1.92 (#5730) 2026-09-15 20:14:58 -04:00
Conn O'Griofa 7a987eecf1 feat(linux): use privileged EGL worker thread (#5709) 2026-09-14 19:34:24 -04:00
Conn O'Griofa 3745a35930 fix(pipewire): gate variable rate to KWin 5.x.x - 6.7.79 (up to stable 6.7 series) (#5705) 2026-09-13 21:07:25 -04:00
Dave Lane d64016a464 fix(linux): repair privileged DRM worker build (#5706) 2026-09-13 19:34:04 -04:00
c553565b98 Merge commit from fork
Sanitize GUI loader and plugin environment variables before privileged initialization, failing closed when the environment cannot be cleaned.

Retain CAP_SYS_ADMIN only on a dedicated DRM worker, route KMS and CUDA DRM access through it, reject queued work safely during overflow or shutdown, and drop the worker privileges when DRM access is no longer needed.

Add Linux regression coverage for the sanitizer and document the new privileged-worker interfaces.

Co-authored-by: Conn O'Griofa <749000+psyke83@users.noreply.github.com>
Co-authored-by: Kishi <41839133+Kishi85@users.noreply.github.com>
2026-09-13 16:37:49 -04:00
Conn O'Griofa 8c74826f2e fix(pipewire): extend KWin version check to handle 6.8 beta/RC versions (#5704) 2026-09-13 11:51:08 -04:00
Dave Lane fb925302d0 fix(linux): export all Wayland DMA-BUF planes (#5699) 2026-09-13 09:31:45 -04:00
Dave Lane 2ebaae37d2 fix(linux): handle NVENC in builds without CUDA (#5698) 2026-09-12 16:30:01 -04:00
Cameron Gutman fbf12d019c fix: missing initializers and incorrect default for native_pen_touch (#5693) 2026-09-12 10:32:04 -04:00
Cameron Gutman 48fca7ab64 fix(nvapi,nvenc): Load ARM64 DLLs on RTX Spark (#5682) 2026-09-10 22:57:13 -04:00
solidv a903885281 fix(linux/vulkan): use vkGetDeviceQueue2 with FFmpeg 9.0 queue flags (#5675) 2026-09-10 14:59:09 -04:00
Dave Lane f7e550d4ab feat(config): add gamepad_driver option (#5653) 2026-09-08 19:27:07 -04:00
Conn O'Griofa cb72dffa32 feat(linux/pipewire): add support for unpaced capture when appropriate (#5629) 2026-09-06 18:25:25 -04:00
Dave Lane 73ccd68f3c fix(macOS): enable microphone permission flow (#5621) 2026-09-06 08:37:08 -04:00
Dave Lane aa92000dc6 refactor: pairing flow, pairing tests, and inline struct comments (#5602) 2026-09-03 08:51:02 -04:00
tonyctalopeandReenigneArcher f111d6a4af fix(windows): capture the configured audio sink instead of the default device (#5408)
Co-authored-by: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com>
2026-09-01 15:27:48 -04:00
Conn O'Griofa 22310da7d9 fix(linux/pipewire): try variable rate for non-KWin compositors (#5569) 2026-08-30 07:51:51 -04:00
Dave Lane c75d5d769b feat(input): update libvirtualhid integration (#5563) 2026-08-29 21:09:02 -04:00
Conn O'GriofaandKishi85 f273ce8f45 fix(pipewire): gate variable rate capture and fix fractional framerates (#5538)
Co-authored-by: Kishi85 <41839133+Kishi85@users.noreply.github.com>
2026-08-25 20:18:04 -04:00
nikzasel e5759171f1 fix(linux/publish): release the Avahi client when the poll loop stops (#5545) 2026-08-23 23:03:05 -04:00
Dave Lane 05b49f0d87 chore: update Virtual HID requirements and mouse refresh (#5547) 2026-08-23 14:44:37 -04:00
Zach DentonandReenigneArcher 3dfbfe0906 fix(wayland): use the current wl_output mode (#5150)
Signed-off-by: Zach Denton <z@chdenton.com>
Co-authored-by: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com>
2026-08-20 23:00:50 -04:00
Dave Lane d3c5e2c85e fix(input): preserve aux gamepad data and bump libvirtualhid (#5531) 2026-08-20 17:00:44 -04:00
Eduardo Mozart de Oliveira f0a46d759d fix(macOS): System tray icon disappears when restarting Sunshine (#5504) 2026-08-20 12:51:31 -04:00
Conn O'Griofa 9e1f089e1f fix(linux/freebsd): truncate thread names to 15 characters (#5527) 2026-08-19 23:31:03 -04:00
luanweslley77andluanweslley77 6ad5f9735d fix(linux/pipewire): restore dummy buffer for software encoders and fix buffer ownership (#5495)
Co-authored-by: luanweslley77 <luanweslley77@users.noreply.github.com>
2026-08-18 11:59:30 -04:00
Dave Lane 687e12d013 feat(input): implement libvirtualhid adding new gamepad styles (#5368) 2026-08-16 15:24:58 -04:00
Kishi 3cba9baeba fix(linux/kms)!: Use connector type index from KMS instead of self calculation (#5489) 2026-08-10 14:38:43 -04:00
dependabot[bot]andReenigneArcher 965c91a428 build(deps): bump third-party/lizardbyte-common from 06cd442 to 011ad2b (#5457)
* build(deps): bump third-party/lizardbyte-common

Bumps [third-party/lizardbyte-common](https://github.com/LizardByte/lizardbyte-common) from `06cd442` to `011ad2b`.
- [Release notes](https://github.com/LizardByte/lizardbyte-common/releases)
- [Commits](https://github.com/LizardByte/lizardbyte-common/compare/06cd442b808f02f1674f3192a84d25b9a503c482...011ad2bb139083dcf4ec21f9c09f07470891a668)

---
updated-dependencies:
- dependency-name: third-party/lizardbyte-common
  dependency-version: 011ad2bb139083dcf4ec21f9c09f07470891a668
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

* style: run clang-format across C++ sources

Reformatted conditionals, loops, and long function calls across core, platform, NVENC, and test helper code to match updated formatting rules, including minor spacing normalization in type declarations. These are style-only edits with no intended behavior changes.

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com>
2026-07-28 08:08:12 -04:00
Dave Lane fb3d85cff4 fix(nvenc): dynamic nv codec sdk selection (#5451) 2026-07-26 21:06:28 -04:00
Kishi 4b74548578 fix(linux/kms): use same methodology for display name matching and list generation (#5448) 2026-07-25 20:06:33 -04:00
Kishi a55d2d99c4 feat(linux): use connector name as default display name on linux (#5423) 2026-07-21 20:11:30 -04:00
Conn O'Griofa 71acfc57ec feat(linux/vaapi): VAAPI encoder improvements (#5388) 2026-07-15 10:41:22 -04:00
Dave Lane 24cbf6f833 chore(sonar): change NOSONAR comment style (#5410) 2026-07-13 17:31:55 -04:00