Closed ECO1AI closed 1 year ago
until i noticed that any audio processed with easyeffects has a latency grater than 5ms .
This is the latency that the audio application is requesting to the audio server. PipeWire is free to use it or not. What it is going to do depends on the situation.
it seems like 5ms is the lowest value and easyeffects is unable to find the correct latency so it sets it to the lowest.
EasyEffects does not try to set any latency. As the game is requesting a low latency PipeWire is switching to it. By default it tries to please the client requesting the lower latency.
You can have a better idea about what Pipewire is doing running pw-top
. But based on my experience whenever games are running too low quantum sizes (latency)
are used. Your EasyEffects logs is showing quantum sizes as low as 256
. For some apps this is fine but with games I almost always hear a crackling.
When I am playing I usually launch the game with the environmental variable PULSE_LATENCY_MSEC
set to something reasonable so that the game does not force PipeWire to use a too low latency.
i see
PULSE_LATENCY_MSEC
did the trick
although, the number that you write is not equal to latency in ms
but that solved the issue
thanks
EasyEffects Version
6.3.0
What package are you using?
Arch (easyeffects)
Distribution
manjaro gnome
Describe the bug
i have seen audio cracking issue #1058 which is similar to what i have except that my issue is with some steam games.
Expected Behavior
no audio cracking , easyeffects sets the correct latency
Debug Log
Debug Log
``` G_MESSAGES_DEBUG=easyeffects easyeffects ✔ 4m 34s (process:13935): easyeffects-DEBUG: 16:44:03.250: easyeffects.cpp:35 easyeffects version: 6.3.0 (process:13935): easyeffects-DEBUG: 16:44:03.253: easyeffects.cpp:45 locale directory: /usr/share/locale (easyeffects:13935): easyeffects-DEBUG: 16:44:03.259: presets_manager.cpp:49 system input presets directory: "/etc/easyeffects/input"; (easyeffects:13935): easyeffects-DEBUG: 16:44:03.259: presets_manager.cpp:49 system input presets directory: "/etc/xdg/easyeffects/input"; (easyeffects:13935): easyeffects-DEBUG: 16:44:03.259: presets_manager.cpp:52 system output presets directory: "/etc/easyeffects/output"; (easyeffects:13935): easyeffects-DEBUG: 16:44:03.259: presets_manager.cpp:52 system output presets directory: "/etc/xdg/easyeffects/output"; (easyeffects:13935): easyeffects-DEBUG: 16:44:03.259: presets_manager.cpp:194 user presets directory already exists: /home/yassen/.config/easyeffects/ (easyeffects:13935): easyeffects-DEBUG: 16:44:03.260: presets_manager.cpp:194 user presets directory already exists: /home/yassen/.config/easyeffects/input (easyeffects:13935): easyeffects-DEBUG: 16:44:03.260: presets_manager.cpp:194 user presets directory already exists: /home/yassen/.config/easyeffects/output (easyeffects:13935): easyeffects-DEBUG: 16:44:03.260: presets_manager.cpp:194 user presets directory already exists: /home/yassen/.config/easyeffects/autoload/input (easyeffects:13935): easyeffects-DEBUG: 16:44:03.260: presets_manager.cpp:194 user presets directory already exists: /home/yassen/.config/easyeffects/autoload/output (easyeffects:13935): easyeffects-DEBUG: 16:44:03.721: pipe_manager.cpp:1409 compiled with PipeWire: 0.3.56 (easyeffects:13935): easyeffects-DEBUG: 16:44:03.721: pipe_manager.cpp:1410 linked to PipeWire: 0.3.57 (easyeffects:13935): easyeffects-DEBUG: 16:44:03.742: pipe_manager.cpp:1380 core version: 0.3.57 (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1381 core name: pipewire-0 (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1294 found metadata: settings (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1294 found metadata: default (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1294 found metadata: route-settings (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1149 Audio/Sink 59 alsa_output.pci-0000_00_1f.3.analog-stereo with serial 60 has been added (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1149 Audio/Source 60 alsa_input.pci-0000_00_1f.3.analog-stereo with serial 61 has been added (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1149 Audio/Sink 133 bluez_output.28_52_E0_E6_FA_BE.a2dp-sink with serial 822 has been added (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1149 Audio/Sink 77 easyeffects_sink with serial 832 has been added (easyeffects:13935): easyeffects-DEBUG: 16:44:03.743: pipe_manager.cpp:1149 Audio/Source/Virtual 70 easyeffects_source with serial 833 has been added (easyeffects:13935): easyeffects-DEBUG: 16:44:03.745: pipe_manager.cpp:895 new metadata property: 0, default.configured.audio.sink, Spa:String:JSON, {"name":"bluez_output.28_52_E0_E6_FA_BE.a2dp-sink"} (easyeffects:13935): easyeffects-DEBUG: 16:44:03.745: pipe_manager.cpp:895 new metadata property: 0, default.configured.audio.source, Spa:String:JSON, {"name":"alsa_input.pci-0000_00_1f.3.analog-stereo"} (easyeffects:13935): easyeffects-DEBUG: 16:44:03.745: pipe_manager.cpp:895 new metadata property: 0, default.audio.sink, Spa:String:JSON, {"name":"bluez_output.28_52_E0_E6_FA_BE.a2dp-sink"} (easyeffects:13935): easyeffects-DEBUG: 16:44:03.745: pipe_manager.cpp:895 new metadata property: 0, default.audio.source, Spa:String:JSON, {"name":"alsa_input.pci-0000_00_1f.3.analog-stereo"} (easyeffects:13935): easyeffects-DEBUG: 16:44:03.745: pipe_manager.cpp:1500 easyeffects_sink node successfully retrieved with id 77 and serial 832 (easyeffects:13935): easyeffects-DEBUG: 16:44:03.745: pipe_manager.cpp:1505 easyeffects_source node successfully retrieved with id 70 and serial 833 (easyeffects:13935): easyeffects-DEBUG: 16:44:03.767: plugin_base.cpp:289 soe: output_level successfully connected to PipeWire graph (easyeffects:13935): easyeffects-DEBUG: 16:44:03.771: plugin_base.cpp:289 soe: spectrum successfully connected to PipeWire graph lilv_world_add_plugin(): warning: Duplicate plugin
Additional Information
after a heavy researches i have noticed the the following :
when govnor is sat to power saving and under load >25 the audio cracking appears ( not every time ), but when i change govnor to performance the cracking disappears. so, i tried to set both easyeffects and pipewire to the highest priority but got minor improvement . i also changed maximum buffer size to 64 but no luck.
i have disabled all plugins and ran audio on easyeffects , but the audio is still cracking despite that it has no modifications to do on audio. ( literally no change in cracking )
until i noticed that any audio processed with easyeffects has a latency grater than 5ms . here is audacious as an example also, this is a game ( open GL ) running from steam
but when i run a game with cracking i get i 5ms only ( as shown below )
which is to quick for my cpu to handel unless i change govnor to performance despite easyeffects taking 15% of the cpu
it seems like 5ms is the lowest value and easyeffects is unable to find the correct latency so it sets it to the lowest. i am running xwayland as compositor which might have something to do with this issue . also, i am setting frame limit to 30fps via goverlay ,but i dont thing that has relation to the issue .
the easiest fix is to somehow manually adjust latency
thank you for your hard work in advance