Commit Graph

196 Commits

Author SHA1 Message Date
Jonas Kvinge b16bec704a GstEnginePipeline: Use "source-setup" instead of "notify::source" signal
This works with both playbin 2 and 3.

Possible fix for #1148
2023-03-19 22:28:12 +01:00
Jonas Kvinge 664a8c79a1 GstEnginePipeline: Check for ssl-strict property 2023-03-19 22:13:16 +01:00
Jonas Kvinge c42b1f5548 GstEnginePipeline: Cast guint to int 2023-03-19 19:38:36 +01:00
Jonas Kvinge a6d10b1fa7 GstEnginePipeline: Check that audio bin exists before unref 2023-02-27 18:50:09 +01:00
Jonas Kvinge dd72fb4ca5 Use C++11 enum class 2023-02-18 14:09:30 +01:00
Jonas Kvinge d406a1c341 GstEnginePipeline: Use playbin3 with GStreamer 1.22.0 and higher 2023-02-10 22:43:55 +01:00
Jonas Kvinge 6671d97b4a GstEnginePipeline: Free audio bin in destructor
When the audio bin failed to initialize, we tried to disconnect signals and probes after the audio bin was already freed.
Instead, free the audio bin in the destructor after disconnecting signals and probes.

Fixes #1133 and #1123
2023-02-10 22:42:37 +01:00
Jonas Kvinge 7aac741571 GstEnginePipeline: Fix setting initial volume
Fixes #1104
2023-01-11 18:52:14 +01:00
Jonas Kvinge 41f2710dea GstEnginePipeline: Use linear volume 2023-01-08 15:25:24 +01:00
Jonas Kvinge 1dfe07003f GstEnginePipeline: Set and notify volume only when changed
Another fix for #1089
2023-01-03 21:32:20 +01:00
Jonas Kvinge 4ec028e736 GstEnginePipeline: Change callback ID's to long 2023-01-03 19:51:23 +01:00
Jonas Kvinge 6d05bb2de5 GstEnginePipeline: Remove upstream events and buffer probes
Also rename some variables and callback functions

Possible fix for #1090
2023-01-02 00:06:18 +01:00
Jonas Kvinge 1a2ab19ab4 GstEnginePipeline: Ignore core error when next song is set
Fixes #958
2023-01-01 20:25:57 +01:00
Jonas Kvinge 205b7f2401 Split utilities functions into separate files 2022-12-28 22:53:59 +01:00
Jonas Kvinge c756346357 GstEnginePipeline: Add audio converter for sink 2022-12-11 01:14:17 +01:00
Jonas Kvinge 44970c3321 GstEnginePipeline: Use converter for event probe 2022-12-11 00:21:16 +01:00
Jonas Kvinge b2073df3c3 GstEnginePipeline: Detect if autoaudiosink has volume
Fixes #1037
2022-12-04 08:37:33 +01:00
Jonas Kvinge 292f2de3e6 GstEnginePipeline: Add more info when ignoring error 2022-12-04 03:18:04 +01:00
Jonas Kvinge b92ec71810 Use system volume when possible
Fixes #1037
2022-12-03 04:33:22 +01:00
Jonas Kvinge c16396a690 GstEnginePipeline: Log pipeline initialized 2022-11-09 22:42:43 +01:00
Jonas Kvinge 32f9c4e670 GstEnginePipeline: Parse album from stream title tag
Fixes #1023
2022-08-30 16:56:08 +02:00
Jonas Kvinge 2b24ac54a0 Remove unused includes 2022-08-28 03:09:33 +02:00
Jonas Kvinge d82fd421ed Replace use of C-style casts 2022-06-13 00:23:42 +02:00
Jonas Kvinge 2414eb2598 GstEnginePipeline: Replace char with int8_t in HandoffCallback 2022-05-06 17:42:08 +02:00
Jonas Kvinge c246b8f164 GstEngine: Show debug information in error dialog 2022-04-14 20:56:57 +02:00
Jonas Kvinge f6b70fda71 Formatting 2022-03-22 21:09:05 +01:00
Jonas Kvinge 5a35099043 Add support for bs2b
Improve headphone listening of stereo audio records
2022-03-05 01:30:49 +01:00
Jonas Kvinge eee3445d2f Silence some conversion warnings 2022-02-06 04:19:45 +01:00
Jonas Kvinge 7caeb47637 GstEnginePipeline: Use std::shared_ptr with deleteLater() for fader timeline
Fixes #890
2022-02-05 19:33:21 +01:00
Jonas Kvinge 6a8c1af5f9 GstEnginePipeline: Set port-pattern for jackaudiosink 2021-11-11 00:58:00 +01:00
Jonas Kvinge c6c53548ac GstEnginePipeline: Return true from BusCallback 2021-10-30 17:55:18 +02:00
Jonas Kvinge 79ac53b2d9 Fix narrowing conversions 2021-10-30 02:21:29 +02:00
Jonas Kvinge c3ce6cff72 GstEngine: Move CreateElement() to GstEnginePipeline 2021-10-16 21:28:56 +02:00
staticssleever668 b38ad81928 Remove use of C-style casts 2021-10-12 18:50:17 +02:00
Jonas Kvinge 637772f8f0 GstEnginePipeline: Convert S24_32LE for analyzer 2021-10-12 18:46:12 +02:00
Jonas Kvinge 0093eb6c2c GstEnginePipeline: Refactor code 2021-10-12 18:36:58 +02:00
Jonas Kvinge f3b70d1cb2 GstEnginePipeline: Rename variable 2021-10-12 18:36:13 +02:00
Jonas Kvinge fd74bbc868 Remove unused GstElementDeleter 2021-10-10 16:33:07 +02:00
Jonas Kvinge d0f1522f0d GstEnginePipeline: Use gst_bus_remove_watch to remove bus watch 2021-10-08 23:39:29 +02:00
Jonas Kvinge ea2bfbda44 Formatting 2021-08-23 21:21:08 +02:00
Jonas Kvinge e48b7d83a3 Formatting 2021-07-11 09:49:38 +02:00
Jonas Kvinge a6742d401c Formatting 2021-07-11 07:40:57 +02:00
Jonas Kvinge cd82b0a669 Fix spelling and typos 2021-07-02 18:45:53 +02:00
Jonas Kvinge 8c2b907ff5 Make static 2021-06-22 14:04:42 +02:00
Jonas Kvinge ed09627fdb Use std::make_unique 2021-06-21 15:40:44 +02:00
Jonas Kvinge 3a3305c020 Uppercase literal suffix 2021-06-20 23:49:04 +02:00
Jonas Kvinge 1295033fae Clang-Tidy and Clazy fixes 2021-06-20 19:04:08 +02:00
Jonas Kvinge f786a17014 Formatting 2021-06-12 20:53:23 +02:00
jonas@jkvinge.net 5d96ee5492 Add ALSA PCM devices and option to set channels
Fixes #262
2021-05-11 19:14:00 +02:00
Jonas Kvinge 9d3000498b Add setting for setting reply gain fallback gain 2021-04-22 21:55:26 +02:00
Jonas Kvinge 14fb647647 Fix uninitialized variables 2021-03-26 21:30:13 +01:00
Jonas Kvinge 59bffed47f Use static_cast 2021-03-21 18:53:02 +01:00
Jonas Kvinge 54f2aa5f77 Update copyrights 2021-03-20 21:14:47 +01:00
Jonas Kvinge 2695169514 Add type to metadata bundle to avoid updating previous song when it shouldn't 2021-03-13 03:14:30 +01:00
Jonas Kvinge 7b2411eec5 Change to info log 2021-03-04 01:14:06 +01:00
Jonas Kvinge bf7c8df353
Connection syntax migration (#637) 2021-01-26 16:48:04 +01:00
Jonas Kvinge b4c614edbf Set volume bit 2020-11-14 04:36:38 +01:00
Jonas Kvinge 914dee8571 Pass network proxy settings to gstreamer
Fixes #558
2020-11-04 22:16:20 +01:00
Jonas Kvinge f7b36ac4c7 Replace use of QVariant::type() with Qt 6 2020-10-24 03:32:40 +02:00
Jonas Kvinge eb1344fcec Unref caps in HandoffCallback 2020-10-22 17:49:13 +02:00
Jonas Kvinge 63135b9c54 Engine will never be in playing state on error 2020-10-21 23:27:15 +02:00
Jonas Kvinge 617179f0c6 Always set state to NULL in destructor 2020-10-21 00:32:55 +02:00
Jonas Kvinge 95ac85f642 Move stream discoverer from pipeline to engine
Fixes #491
2020-10-21 00:07:58 +02:00
Jonas Kvinge ca8877ad47 Revert gst_discoverer_stop 2020-10-20 18:47:40 +02:00
Jonas Kvinge 6d8f31048c Add call to gst_discoverer_stop
Stream discoverer currently only works on Linux
2020-10-20 18:28:09 +02:00
Jonas Kvinge dbb8ec0290 Remove debug in bus callbacks 2020-10-19 19:09:48 +02:00
Jonas Kvinge b6693a71f9 Rename initialise to initialize 2020-10-17 17:29:09 +02:00
Jonas Kvinge 5b21118a8c Replace gst_tag_list_free with gst_tag_list_unref 2020-10-17 04:54:46 +02:00
Jonas Kvinge 24286dbe9d Use QtConcurrent::run directly 2020-10-14 22:49:37 +02:00
Jonas Kvinge 4a53d4f043 Ignore "IDirectSoundBuffer_GetStatus The operation completed successfully"
Fixes #557
2020-10-13 00:49:34 +02:00
Jonas Kvinge b6ff7e6b47 Fix transition to next song in CUE files
Fixes #552
2020-10-10 01:57:02 +02:00
Jonas Kvinge 74a5233b5d Replace use of deprecated gstreamer low-percent
- Add settings for low-watermark and high-watermark
- Add button to reset buffer settings to defaults
2020-10-07 20:29:26 +02:00
Jonas Kvinge 61ffb7d97a Unref bus 2020-10-03 13:09:09 +02:00
Jonas Kvinge cdcfd64ec4 Possible fix for WASAPI crashes 2020-10-03 01:58:52 +02:00
Jonas Kvinge 08f32d1de6 Refactor playlist view/header code
- Don't reload all settings when changing playlists
- Fix initial playlist header columns sizes
- Properly reset header state when resetting columns
2020-08-29 19:55:00 +02:00
Jonas Kvinge b1099e6974 Handle metadata with tilde in title 2020-08-07 00:52:09 +02:00
Jonas Kvinge 638998a861 Replace QTimeLine::CurveShape with QEasingCurve 2020-07-18 17:53:14 +02:00
Jonas Kvinge 7fd5c058be Fix buffer overflow when coverting S24LE 2020-07-04 01:55:36 +02:00
Jonas Kvinge b22e8b4702 Convert S24LE and F32LE for analyzer
Fixes #155
2020-07-04 00:29:11 +02:00
Jonas Kvinge 72ede666d4 Replace use of C style casts 2020-06-15 17:59:02 +02:00
Jonas Kvinge 13b60351a6 Replace use of deprecated C++ headers 2020-06-14 23:54:18 +02:00
Jonas Kvinge 082c9097e4 Fix parameter name mispatches 2020-06-14 18:58:24 +02:00
Jonas Kvinge 732be5a34f Use g_free 2020-05-24 23:22:18 +02:00
Jonas Kvinge a2c0e4d4b1 Improve album cover loader, lyrics search and streaming support
- Improve album cover loader
- Add album cover loader result struct
- Move album cover thumbnail scaling to album cover loader
- Make init art manual look for album cover images in song directory
- Make album cover search work for songs outside of collection and
  streams
- Make album cover search work based on artist + title if album is not
  present
- Update art manual in playlist for local files, devices and CDDA
- Make lyrics search work for streams
- Add stream dialog to menu
- Remove dead code in InternetSearchModel
- Simplify code in InternetSearchView
2020-04-20 18:03:18 +02:00
Jonas Kvinge 1851f26e3f Reduce includes 2020-02-09 02:29:35 +01:00
Jonas Kvinge c141df6b86 Remove low-latency setting for wasapisink 2019-11-26 22:30:56 +01:00
Jonas Kvinge c0a2ad5f50 Change comment 2019-11-18 17:16:58 +01:00
Jonas Kvinge 1b65dcd7df Fix comparison between signed/unsigned 2019-11-15 00:23:06 +01:00
Jonas Kvinge 89b06ae7c7 Mulitply samples by channels, dont hardcode to 2 2019-11-09 16:34:17 +01:00
Jonas Kvinge 834877c503 Refactor gstreamer engine code, equalizer and fix stereo balancer 2019-11-08 23:07:21 +01:00
Jonas Kvinge d033b79af4 Remove exclusive for wasapisink
Fixes #283
2019-11-07 20:26:25 +01:00
Jonas Kvinge 4e593cebab Add const 2019-11-06 21:53:09 +01:00
Jonas Kvinge 6a430b441e Remove debug line 2019-11-03 19:56:01 +01:00
Jonas Kvinge 7b977ea839 Rename EngineDevice --> DeviceFinders, Add MMDeviceFinder 2019-11-03 19:53:08 +01:00
Jonas Kvinge e800b236aa Simplify the pipeline
Fix issue where bitrate is updated incorrectly by stream discoverer
Fixes issue #282
Also make it possible to enable stereo balancer without enabling the
equalizer
2019-10-27 23:48:54 +01:00
Jonas Kvinge d9c703d944 Add gst/audio/audio.h include 2019-10-20 20:04:23 +02:00
Jonas Kvinge 364b650033 Convert S32LE to S16LE for analyzer 2019-10-20 18:52:58 +02:00
Jonas Kvinge 156eb874db Fix analyzer and cleanup old pipeline code
- Move HandoffCallback to audio queue
- Add new callback for detecting source format
- Remove old decodebin stuff
2019-10-20 02:56:47 +02:00
Jonas Kvinge abeb580228 Disable analyzer for other bit depths than 16
This removes the splitting of the pipeline with the tee.
Move HandoffCallback to the source, which makes it possible to convert the audio buffer in HandoffCallback later.
Until then just disable analyzer for other formats.

Removes tee and probe queue converter and sink
2019-10-19 01:45:24 +02:00
Jonas Kvinge 9821b70c38 Dont use gst_caps_to_string as it causes hang with some formats 2019-10-12 01:58:01 +02:00