Commit Graph
100 Commits
Author SHA1 Message Date
Cameron Gutman 2e29ef8d74 Simplify codec selection and prioritization logic 2024-07-06 00:50:32 -05:00
Cameron Gutman 34fa7167b1 Force AV_CODEC_CAP_HARDWARE set for OMX decoders
There are at least 2 out-of-tree OMX decoder implementations
that both lack AV_CODEC_CAP_HARDWARE, so they trick us into
thinking that neither of them is hardware accelerated.

Fixes false decoder warnings when linked against the patched
FFmpeg builds shipping on VisionFive 2 and LicheePi 4A SBCs.
2024-07-05 23:04:10 -05:00
Cameron Gutman 27b173b76b Add a GenericHwAccelRenderer for unknown hwaccels
This will get us limited hardware acceleration even for hwaccels
that we don't know about yet.
2024-07-05 22:49:52 -05:00
Cameron Gutman d73df12367 Don't precompile QML files with disable-prebuilts
This binds us against the exact compile-time version of Qt with no
forwards or backwards compatibility, so it must not be used when we
could load Qt libraries from a location outside of our app bundle.
2024-07-04 15:45:48 -05:00
Cameron Gutman 17a2548480 Fix changelog typo 2024-06-29 19:56:31 -05:00
Cameron Gutman 753deb915f Prepare for v6.0.1 2024-06-29 19:55:10 -05:00
Cameron Gutman 7d6f4135d5 Show Hungarian in the language list
The translation is nearly complete now (89%)
2024-06-29 17:19:35 -05:00
Cameron Gutman 622ec843ff Add Lithuanian and rerun lupdate/lrelease 2024-06-29 17:17:45 -05:00
Cameron Gutman 5c18bf1608 Merge remote-tracking branch 'origin/weblate' 2024-06-29 17:07:02 -05:00
Cameron Gutman d184730a82 Switch over to the new code signing certificate 2024-06-29 17:02:33 -05:00
Cameron Gutman 335ed0e8e6 Only sample directly from the video decoder output texture on Intel GPUs
This technique seems to actually make performance worse on some AMD GPUs (RX 480)
and causes rendering errors on others (HD 5570). These might be AMD-specific bugs
but let's not risk a behavior change for AMD/NVIDIA where nobody was having perf
issues with the old copy method anyway.
2024-06-29 14:44:08 -05:00
Cameron Gutman 0abb9fd7c2 Revert "Avoid using D3D11VA on older AMD TeraScale GPUs"
This reverts commit 93408386ae.
2024-06-29 14:12:03 -05:00
Cameron Gutman 1a1ce05959 Revert "Use a Texture2DArray in HLSL to match the SRVs"
This reverts commit d389f9a6e9.
2024-06-29 14:07:41 -05:00
Cameron Gutman 93408386ae Avoid using D3D11VA on older AMD TeraScale GPUs 2024-06-28 20:24:47 -05:00
Cameron Gutman 415b512c75 Require FL 11.0 for the D3D11VA renderer
We would probably be okay with 10.0 (SM4), but let's not risk
encountering GPU driver bugs like we do on old AMD cards.
2024-06-28 19:56:00 -05:00
Cameron Gutman d389f9a6e9 Use a Texture2DArray in HLSL to match the SRVs 2024-06-27 19:46:27 -05:00
Cameron Gutman dff02eab7d Fix DrmRenderer build 2024-06-25 23:29:37 -05:00
Cameron Gutman ecfcedad58 Fix window resizing on Windows with software decoding 2024-06-25 23:21:08 -05:00
Cameron Gutman e76780e105 Add a new prepareToRender() callback for renders to perform their initial window clears
This consolidates all the clearing that was strewn across the codebase.
2024-06-25 23:12:18 -05:00
Cameron Gutman 1d1fa0577b Don't flush window events after the KMSDRM modeset operation
We will flush the initial window shown event that we require to start decoding.
2024-06-25 22:28:23 -05:00
Cameron Gutman a9d7c8e495 Move forced KMSDRM modesetting operation into Session init code
Performing this each time DrmRenderer is initialized leads to long
delays when choosing a decoder on embedded platforms, particularly
those like TH1520/JH7110 which lack accelerated GL drivers.
2024-06-25 21:57:02 -05:00
Cameron Gutman ffdf683597 Output log messages to an attached debugger 2024-06-24 19:24:06 -05:00
Cameron Gutman ac0e1098b9 Take COLOR_ENCODING values into account when choosing a colorspace
Replace the generic starfive hack with proper logic to examine the
supported enum values to select a colorspace. This fixes incorrect
colors with vs-drm on the TH1520.
2024-06-23 19:33:37 -05:00
Cameron Gutman 35695642d5 Use the first available plane that meets the zpos requirement
Planes seem to be listed in descending order of capabilities
with later planes sometimes lacking scaling capabilities, which
is the case with vs-drm on the TH1520.
2024-06-23 19:03:35 -05:00
Cameron Gutman e458682a23 Refactor plane property loop to avoid leak 2024-06-23 18:13:20 -05:00
Cameron Gutman fbe5e6f01f Build Windows ARM64 with Qt 6.7 in CI 2024-06-23 17:58:22 -05:00
Cameron Gutman 52756e7f45 Update AppImage dependencies
dav1d -> 1.4.3
SDL2 -> ab5740bd
2024-06-23 17:57:42 -05:00
Cameron Gutman 0f57abf6f8 Don't select an overlay plane with a lower zpos than the primary plane 2024-06-23 17:55:27 -05:00
Cameron Gutman 94943d2865 Clamp chroma texcoords to avoid sampling alignment padding
This resolves #885 without the massive perf hit on lower end Intel GPUs.
2024-06-22 16:19:26 -05:00
Cameron Gutman c3bd7edc4e Revert "Use a separate texture for rendering to avoid blending in the alignment padding"
This kills performance on some Intel iGPUs (particularly Atom chips like N100),
so let's remove the copy and solve this issue a different way instead.

This reverts commit a6fccf93d1.
2024-06-22 12:35:00 -05:00
Cameron Gutman b6bb96223d Revert "Remove manual hwframe ctx setup for D3D11VA"
We need this back to avoid the copy that's tanking performance on Intel iGPUs.

This reverts commit 2cef09471b.
2024-06-22 12:34:10 -05:00
Cameron Gutman 3aaa09bb7d Disable CUDA/NVDEC in AppImage builds
These are only really useful for Wayland scenarios, but:
- Wayland is explicitly disabled for AppImage due to EGL issues
- VDPAU now works under XWayland with 545 and later drivers
- Moonlight now has a Vulkan Video backend which works with 535 and later drivers

Fixes #1314
2024-06-19 10:29:03 -05:00
Cameron Gutman 377abf2155 Remove verbose flag from tar invocation 2024-06-19 10:25:15 -05:00
Cameron Gutman d3219ae24a Don't use VAAPI fallback driver names on libva 2.20+
libva 2.20 is good enough at detecting driver names (even under XWayland)
that we don't need to use the fallback name list anymore. This saves time
probing drivers, avoids excessive log output from failed probes, and avoids
tickling bugs in VAAPI drivers that are installed but unused.
2024-06-18 00:31:59 -05:00
Cameron Gutman bd60b873ec Add missing check for no Vulkan devices 2024-06-18 00:12:08 -05:00
Cameron Gutman 640ac3f9fe Don't bundle libs into the final app package if disable-prebuilts is set 2024-06-10 22:57:58 -05:00
Cameron Gutman 83811e2a07 Add 'CONFIG+=disable-prebuilts' qmake option
When specified, qmake uses pkg-config for libraries on macOS instead of the prebuilts in the libs submodule.
2024-06-10 22:51:45 -05:00
Cameron Gutman 31641f5246 Update readme with new packages and Qt 6 recommendations 2024-06-09 20:54:17 -05:00
Cameron Gutman d7bc735edc Allow use of old fullscreen mode on macOS by setting I_WANT_BUGGY_FULLSCREEN=1 2024-06-09 15:46:24 -05:00
Cameron Gutman b59de38e0b Revert "Only use SDL_HINT_VIDEO_MAC_FULLSCREEN_SPACES=0 for native notched resolution"
Users want to control when the notch is and is not included for display scaling.

Fixes #1301

This reverts commit e25d9b0da2.
2024-06-09 15:42:39 -05:00
Cameron Gutman 17af71fe7a Allow the Vulkan renderer to accept HDR input even without HDR output capability
In addition to resolving issues with mixing HDR and SDR displays and moving
between them while streaming, it also allows streaming HDR content to an SDR
display with tone mapping handled transparently by libplacebo.
2024-06-09 15:00:56 -05:00
Cameron Gutman a0c77d0ad8 Filter SDL_WINDOWEVENT_SHOWN after initial renderer creation
This case exists to handle the initial bringup of the renderer when
the window appears on screen. We can ignore these if we already
created a renderer, to avoid renderer re-creation if a spurious
SDL_WINDOWEVENT_SHOWN event arrives later.
2024-06-09 14:34:34 -05:00
Cameron Gutman ec7137e693 Flush window events in MMAL and DRM renderers 2024-06-09 14:26:26 -05:00
Cameron Gutman 486c46781b Increase computer seeking timeout for 'stream' and 'list' actions
The host may take some time to wake up from sleep.
2024-06-08 16:18:06 -05:00
Cameron Gutman 6397031e46 Expand allowed range for --fps option 2024-06-08 00:17:17 -05:00
Cameron Gutman e7a2d9f44d Prepare for v6.0.0 2024-06-05 22:42:28 -05:00
Cameron Gutman ee5d0acc1f Rerun lupdate and lrelease 2024-06-05 00:28:11 -05:00
Cameron Gutman 6a5a69cabd Merge remote-tracking branch 'origin/weblate' 2024-06-05 00:26:59 -05:00
Cameron Gutman d6d28f1afd Remove unused libplacebo libraries 2024-06-02 21:52:35 -05:00
Cameron Gutman 5a6620a9ae Fix missing installer window icon with WiX 5 2024-06-02 21:40:40 -05:00
Cameron Gutman 5a47ddca33 Use EGL on X11 for non-x86 platforms
In theory we could do this everywhere, but I'd rather not risk major behavior changes on x86 right before a release.
2024-06-02 14:01:54 -05:00
Cameron Gutman b58f021fc8 Only set QT_SSL_USE_TEMPORARY_KEYCHAIN on macOS
It's useless on other platforms.
2024-06-02 13:58:42 -05:00
Cameron Gutman 12b93337d1 Fix SDL_VIDEODRIVER override when the Qt platform plugin was manually set 2024-06-01 22:43:52 -05:00
Cameron Gutman 807fc6b31c Opt out of macOS Game Mode due to various OS bugs
Fixes #1170
Fixes #1297
2024-06-01 16:36:24 -05:00
Cameron Gutman 959080aa95 Update moonlight-common-c with higher IPv6 MTU 2024-06-01 16:30:45 -05:00
Cameron Gutman 18a772aeba Update prebuilt libraries
opus -> 1.5.2
FFmpeg -> 7.0.1
dav1d -> 1.4.2
2024-06-01 16:30:20 -05:00
Cameron Gutman 9bdd17f1c3 Properly clean libavformat files with clean-libs.sh 2024-06-01 16:25:46 -05:00
Cameron Gutman 469bd32bde Update AppImage to FFmpeg 7.0.1 and dav1d 1.4.2 2024-05-31 20:43:03 -05:00
Cameron Gutman a0a8b70bc1 Strip session keys and IVs from the logs
Logging these isn't a major issue because they change each session and
the privilege level to access the logs is the same as those to access the
private key of Moonlight client itself, but there's also no good reason to
log them either.
2024-05-27 22:02:02 -04:00
Cameron Gutman e07f069222 Always use the custom logger
It was already used everywhere except macOS Debug builds.
2024-05-27 21:40:18 -04:00
Cameron Gutman 96fba43186 Add missing AV1 option in CLI video codec options
Fixes #1290
2024-05-27 13:06:49 -04:00
Cameron Gutman 9e7c212c6d Update moonlight-common-c 2024-05-25 18:32:58 -05:00
Cameron Gutman e67d83e097 Move declaration under ifdef to eliminate unused variable warning 2024-05-25 17:01:46 -05:00
Cameron Gutman 4474f815af Only use fallback VDPAU/VAAPI driver paths on AppImages
Native packages and Flatpak/Snap packages both have properly set
driver path values embedded in libva.so/libvdpau.so. Let's not go
splunking for drivers in random folders on those systems.
2024-05-25 14:39:09 -05:00
Cameron Gutman e130a15037 Remove dependency on AV_VAAPI_DRIVER_QUIRK_SURFACE_ATTRIBUTES for VDPAU wrapper identification
These quirks may be deprecated and no longer populated in an upcoming FFmpeg version.
2024-05-25 14:24:31 -05:00
Cameron Gutman 845ef147c9 Add new libva driver path values for Fedora 40 2024-05-25 14:22:43 -05:00
Cameron Gutman fb17c15cfd Update VCRedist 2024-05-25 11:54:29 -05:00
Cameron Gutman cf3ff32340 Rerun lupdate and lrelease 2024-05-23 00:28:10 -07:00
Cameron Gutman 2c98deeae3 Merge remote-tracking branch 'origin/weblate' 2024-05-23 00:26:16 -07:00
Cameron Gutman a572681737 Add --hdr and --no-hdr command-line arguments
Fixes #1287
2024-05-22 23:28:14 -07:00
Cameron Gutman e78b389bc0 Fix passing incorrect 'this' pointer to quitRunningApp()
This worked before due to Qt behavior that was changed in https://codereview.qt-project.org/c/qt/qtdeclarative/+/450393
to generate a warning in this situation. The old behavior remains the default, but this change avoids a warning in the logs.
2024-05-22 23:11:52 -07:00
Cameron Gutman 9117f6565e Don't clobber existing std handles when attaching to the parent console
Fixes #1270
2024-05-11 23:38:32 -05:00
Cameron Gutman aa33432c81 Detect whether to log to file based upon whether stderr was redirected 2024-05-11 23:24:36 -05:00
Cameron Gutman e25d9b0da2 Only use SDL_HINT_VIDEO_MAC_FULLSCREEN_SPACES=0 for native notched resolution
Full-screen and borderless windowed are now fully indistinguishable on macOS to avoid user confusion.

Fixes #861
2024-05-11 19:58:36 -05:00
Cameron Gutman 0dfa8a7b53 Override fullscreen mode if necessary for native resolutions to work as expected
Fixes #1244
2024-05-11 19:55:08 -05:00
Cameron Gutman 85a9f85c54 Add support for listing notch and notchless native resolution options 2024-05-11 19:48:01 -05:00
Cameron Gutman ed68f920f1 Avoid polluting source tree with NuGet cache files during WiX build 2024-05-11 15:08:30 -05:00
Cameron Gutman f9a4498f9b Upgrade to WiX v5.0.0 2024-05-11 15:08:10 -05:00
Cameron Gutman 4d1acf2e30 Don't invoke signal handlers directly
This generates a runtime warning on Qt 6.7
2024-05-06 19:16:10 -07:00
Cameron Gutman db4739b82d Remove warn_off configuration for moonlight-common-c subproject
We can just turn off unused parameter warnings instead of all warnings.
2024-05-05 18:52:21 -05:00
Cameron Gutman 364093aef8 Prevent a deadlock if the audio device stops consuming data 2024-05-04 21:22:38 -05:00
Cameron Gutman 6d220a9062 Allow audio to recover if no audio devices were present during stream start 2024-05-04 21:13:00 -05:00
Cameron Gutman 93ed985043 Rerun lupdate and lrelease 2024-04-30 22:53:23 -05:00
Cameron Gutman 23c737cab9 Split details dialog into multiple lines for easier translation 2024-04-30 22:53:23 -05:00
Cameron Gutman cb850f013a Add Central Kurdish language (disabled until it's completed) 2024-04-30 22:53:15 -05:00
Cameron Gutman 6bd964a094 Merge remote-tracking branch 'origin/weblate' 2024-04-30 22:27:09 -05:00
Cameron Gutman 419c788ab5 Remove save() call that is no longer necessary since d1ccd19 2024-04-30 21:42:38 -05:00
Cameron Gutman 0531666f38 Apply some minor cosmetic improvements to the details dialog 2024-04-30 21:36:59 -05:00
Cameron Gutman 1cd588f25c Don't set relative warp mode based on absolute/relative mouse mode
This breaks pointer capture on Wayland when we start in absolute mouse
mode (since warp is not supported on Wayland). It's also confusing to
users because it leads to different relative mouse acceleration curves
based on whether you start a stream in relative mode or not.
2024-04-27 17:13:02 -05:00
Cameron Gutman ebfe035a18 Set SDL_VIDEO_WAYLAND_EMULATE_MOUSE_WARP=0 to resolve pointer lock issue on Wayland
SDL will try to lock the mouse cursor on Wayland if it's not visible in order to
support applications that assume they can warp the cursor (which isn't possible on
Wayland). We don't want this behavior because it interferes with seamless mouse
mode when toggling between windowed and fullscreen modes by unexpectedly locking
the mouse cursor.
2024-04-27 16:49:51 -05:00
Cameron Gutman 4aa2b8570c Autorelease the system default Metal device 2024-04-19 00:29:51 -05:00
Cameron Gutman fe6562e31c Allow forcing Metal renderer on or off via VT_FORCE_METAL=1 and VT_FORCE_METAL=0 respectively 2024-04-19 00:27:45 -05:00
Cameron Gutman 654e386263 Only pace presentation if display sync is enabled 2024-04-19 00:17:13 -05:00
Cameron Gutman 76d0eb6b63 Avoid trying VDPAU when Vulkan is preferred
The VDPAU renderer causes interoperability issues with Vulkan.
2024-04-18 00:41:24 -05:00
Cameron Gutman 76ff53f09f Move warning dialog checks into the Window's onCompleted() function
The old issue with dialogs appearing behind the main window only impacts the old non-QC2 dialogs,
which we haven't used for several years.
2024-04-14 14:49:35 -05:00
Cameron Gutman 37d92dee16 Revert "Fix hiding the main UI window while streaming on Qt 6.7"
The original issue on Qt 6.7 was caused by conflicts with the window state set in main.qml
which was addressed by afbc49e39a.

The remaining issue with Qt 6.7 clobbering window state and position when hiding a window
looks like a legitimate Qt bug.

This reverts commit ebe270bec5.
2024-04-14 14:08:53 -05:00
Cameron Gutman afbc49e39a Apply the main window visibility property only at startup
Otherwise it can affect the state of the window when showing again streaming
2024-04-14 13:35:41 -05:00
Cameron Gutman d1ccd19fcc Make StreamingPreferences a proper singleton
This removes the need for several hacks in SettingsView to force updates and improves performance by not reloading preferences all over the place.
2024-04-14 13:01:30 -05:00
Cameron Gutman ebe270bec5 Fix hiding the main UI window while streaming on Qt 6.7 2024-04-13 00:05:49 -05:00
Cameron Gutman 784234c857 Fix updating bitrate text upon language change on Qt 6.7 2024-04-13 00:05:11 -05:00