diff options
author | dec05eba <dec05eba@protonmail.com> | 2025-02-09 19:35:15 +0100 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2025-02-10 17:04:31 +0100 |
commit | d088586296f6bba924b0cc65676dd7da4558fbdc (patch) | |
tree | 10a04f7dedd5889de4f8ccad86048200bb29c65a | |
parent | ddc3871b27fe9fc086453e3c61b96ae4783e4035 (diff) |
Make plasmashell check work in flatpak
-rw-r--r-- | TODO | 6 | ||||
-rw-r--r-- | src/main.cpp | 9 |
2 files changed, 13 insertions, 2 deletions
@@ -221,4 +221,8 @@ Use explicit sync in pipewire video code: https://docs.pipewire.org/page_dma_buf Support vaapi rotation. Support for it is added in mesa here: https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32919. Replay (and recording?) fails to save properly sometimes (especially for long videos). This is noticable with mp4 files since they get corrupt and become unplayable. - The entire video does seem to get saved (it's a large video file) and it seems to have the correct headers but it's not playable.
\ No newline at end of file + The entire video does seem to get saved (it's a large video file) and it seems to have the correct headers but it's not playable. + +Make it possible to save a shorter replay clip remotely. Maybe implement ipc first, to then also allow starting recording/stream while a replay is running. + +Add an option to pass http headers when streaming. Some streaming services require streaming keys to be passed in a http header instead of in the url as a parameter.
\ No newline at end of file diff --git a/src/main.cpp b/src/main.cpp index 6a8d0c4..64f8952 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -3007,7 +3007,14 @@ static AudioDeviceData create_application_audio_audio_input(const MergedAudioInp #endif static bool is_kde_plasma_version_greater_than_6_1_90() { - FILE *f = popen("plasmashell -v 2> /dev/null", "r"); + const bool inside_flatpak = getenv("FLATPAK_ID") != NULL; + const char *cmd = nullptr; + if(inside_flatpak) + cmd = "flatpak-spawn --host -- plasmashell -v 2> /dev/null"; + else + cmd = "plasmashell -v 2> /dev/null"; + + FILE *f = popen(cmd, "r"); if(!f) return false; |