Fix black video on non-Vulkan GPUs: bundle vulkan-1.dll with libmpv - #13888
Merged
Conversation
The shinchiro 20260814 libmpv (beta 17/18) carries a load-time import of vulkan-1.dll after upstream's 2026-08-04 "vulkan: disable static loader" change. That DLL is installed by GPU drivers, not Windows, so on machines with pre-Vulkan GPUs (or the Microsoft Basic Display driver) LoadLibrary fails outright: black video, no sound, waveform still fine (issue #13856, upstream shinchiro/mpv-winbuild-cmake#831). Repackaged the zips as support-files tag libmpv-2026-08-14b with the Authenticode-signed Khronos loader from the LunarG 1.4.357.0 runtime (x64 and ARM64) plus its license next to libmpv-2.dll; the libmpv DLLs are byte-identical to before. SE loads libmpv with LOAD_WITH_ALTERED_SEARCH_PATH + SetDllDirectory, so the adjacent loader is found; with zero Vulkan ICDs it no-ops and mpv's d3d11/OpenGL contexts work as before. Also copy the whole extracted zip in the Windows CI publish legs, and make the libmpv-update fallback mover carry every file in the folder instead of only libmpv-2.dll. Fixes #13856 Co-Authored-By: Claude Fable 5 <[email protected]>
Manual libmpv installs need vulkan-1.dll too: builds from August 2026 link the Vulkan loader dynamically, so libmpv-2.dll does not load at all without it. Note that in the third-party components list, and add the "black video, no sound, waveform works" symptom to the FAQ. BatchConvertStatusColor_StillFollowsTheErrorTextAfterItChanges used "is the result a brush at all" as a proxy for "is it the error brush". That proxy only held while non-error statuses returned UnsetValue - since the in-progress statuses were given the explicit theme text brush the test failed. Compare brush identity instead, which is what it was really asserting. Co-Authored-By: Claude Fable 5 <[email protected]>
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The regression
Since beta 17, users on GPUs without a Vulkan runtime get a black video with no sound (waveform still works) — reported in #13856 by a GeForce 9500 GT user, where beta 16 works fine.
The libmpv bump in #13761 (shinchiro 20260814) picked up upstream's 2026-08-04 "vulkan: disable static loader" change:
libmpv-2.dllnow has a load-time PE import ofvulkan-1.dll(both x64 and ARM64; the April DLL had none — Vulkan was statically linked).vulkan-1.dllis installed by GPU drivers, not by Windows, so on any machine whose driver predates Vulkan (or with the Microsoft Basic Display driver)LoadLibrary("libmpv-2.dll")fails outright — mpv never even initializes. Upstream ships no loader with their packages either; their open issue shinchiro/mpv-winbuild-cmake#831 says "install the LunarG runtime yourself".The repackaging in #13761 itself was clean — both DLLs verified byte-identical to upstream's non-v3 x86_64 / aarch64 archives.
The fix
New support-files release libmpv-2026-08-14b: the same libmpv DLLs (SHA256-verified unchanged) with the Authenticode-signed Khronos Vulkan loader from the LunarG 1.4.357.0 runtime (Apache-2.0, license text included) next to them — x64 loader in the x64 zip, ARM64 loader in the ARM64 zip.
This works because SE loads libmpv with
LOAD_WITH_ALTERED_SEARCH_PATH+SetDllDirectory, so the adjacentvulkan-1.dllresolves the import. On machines with no Vulkan drivers the loader simply enumerates zero ICDs and mpv's d3d11/OpenGL context probing works exactly as before; on Vulkan-capable machines nothing changes.Repo changes:
LibMpvDownloadService .cs— point both download URLs at thebtag (the in-app unpack already extracts every root-level.dll, sovulkan-1.dllflows through).build-ui.yml— point the CI download at thebtag and copy the whole extracted zip into both Windows publish folders instead of onlylibmpv-2.dll.MainViewModel.cs— thelibmpv-updatefallback (used when the old DLL is locked during an in-app update) now moves every file in the folder, not justlibmpv-2.dll.Docs
docs/third-party-components.md— manual libmpv installs need the loader too, so the MPV section now says where to getvulkan-1.dlland that SE's own download button already includes it.docs/faq.md— added the "black video, no sound, but the waveform works" symptom under Troubleshooting, since that combination is the tell-tale for libmpv failing to load.Unrelated test fix
BatchConvertStatusColor_StillFollowsTheErrorTextAfterItChangeswas failing onmainbefore this branch: #13883 and #13884 raced. The test used "is the result a brush at all" as a proxy for "is it the error brush", which only held while non-error statuses returnedUnsetValue; #13884 correctly changed those to the explicit theme text brush to fix black-on-dark status text. The test now compares brush identity, which is what it was actually asserting. All four test projects pass (3235 + 1399 + 251 + 376).Fixes #13856
🤖 Generated with Claude Code