Audio playback frequency on Ubuntu 21.10 - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33) +--- Forum: General Support (https://forum.kodi.tv/forumdisplay.php?fid=111) +---- Forum: Linux (https://forum.kodi.tv/forumdisplay.php?fid=52) +---- Thread: Audio playback frequency on Ubuntu 21.10 (/showthread.php?tid=365057) |
Audio playback frequency on Ubuntu 21.10 - jmansion - 2021-10-20 It seems that Kodi is playing at 48kHz - my USB DAC displays the current rate (but sadly not the bit depth). I'd rather have straight-through without resampling and fix at 44.1 - is there a way to do that? I did try to download the source and poke around but there are some build issues, I'll post about that separately. RE: Audio playback frequency on Ubuntu 21.10 - Buschel - 2021-10-20 (2021-10-20, 12:25)jmansion Wrote: It seems that Kodi is playing at 48kHz - my USB DAC displays the current rate (but sadly not the bit depth).Didi you try to configure the Audio output via Kodi`s settings (System > Audio)? 1. Option (hardcoding to 44.1 kHz): System > Audio > Output configuration > Fixed System > Audio > Limit sampling rate (kHz) > 44.1 2. Option (Kodi tries to maintain the sampling frequence of the item played): System > Audio > Output configuration > Best match RE: Audio playback frequency on Ubuntu 21.10 - jmansion - 2021-10-20 (2021-10-20, 17:46)Buschel Wrote:Actually I hadn't because I was unaware - previously I had forced things through asound.conf. However - these settings seem to have made no difference.(2021-10-20, 12:25)jmansion Wrote: It seems that Kodi is playing at 48kHz - my USB DAC displays the current rate (but sadly not the bit depth).Didi you try to configure the Audio output via Kodi`s settings (System > Audio)? This is Ubuntu 21.10, and its switched to pipewire, which I assume is causing the issue. RE: Audio playback frequency on Ubuntu 21.10 - Buschel - 2021-10-20 (2021-10-20, 19:51)jmansion Wrote: Actually I hadn't because I was unaware - previously I had forced things through asound.conf. However - these settings seem to have made no difference. Then it looks like you should configure this in pipewire.conf (config). I personally avoid such kind of frameworks which resample back and forth. Also I am not sure if pipewire will skip resampling if you set the global samplerate to your desired frequency. With aloop I have seen a lot of problems with mismatching clocks and resampling. For audio purposes I am still preferring plain alsa. RE: Audio playback frequency on Ubuntu 21.10 - jmansion - 2021-10-21 (2021-10-20, 20:54)Buschel Wrote:(2021-10-20, 19:51)jmansion Wrote: Actually I hadn't because I was unaware - previously I had forced things through asound.conf. However - these settings seem to have made no difference. It gets stranger. I have disabled pipewire globally in systemd. Pulseaudio is not installed. I have added ~/.asoundrc like this: pcm.!default { type plug slave.pcm "fixed" } ctl.!default { type hw card 0 } pcm.fixed { format S32_LW rate 44100 type hw card 0 } Now if I use speaker-test, I always get the DAC showing 44.1kHz. But, when I start kodi (as me) the DAC immediately shows 48.0kHz - despite having configured for fixed output, limit to 44100. I changed to the 'fixed' alias and now its working at 44.1 now, but why was it trying to use 48000 - all the source material is ripped from standard CDs, and it selected 48000 before I start any playback. Still - working now, and now to see if I can replay through CamillaDSP. RE: Audio playback frequency on Ubuntu 21.10 - Buschel - 2021-10-21 (2021-10-21, 18:58)jmansion Wrote: I changed to the 'fixed' alias and now its working at 44.1 nowGood to hear you already found a solution. What happens if you go for the Kodi seeting "System > Audio > Output configuration > Best match"? This should use the samplerate of your file for the playback. (2021-10-21, 18:58)jmansion Wrote: but why was it trying to use 48000 - all the source material is ripped from standard CDs, and it selected 48000 before I start any playback.I guess (but do not know) this is the default samplerate for Kodi. Video material typically uses a samplerate of 48 kHz (or the 48 kHz family). RE: Audio playback frequency on Ubuntu 21.10 - fritsch - 2021-10-24 Kodi uses 44.1 by defaulf if the sink supports it. Kodi will furthermore exactly state what it found during startup. So - simply post a Debug Log and it can be found out. |