@iska@mstdn.starnix.network @cyberspook @fugger I think you're right! I still prefer youtube-dl though. Firefox wants pulseaudio for audio input to work, but as I hate pulse, I use this wrapper called apulse. It introduces some lag which makes audio and video out of sync. It's okay for video calls and such, but it pisses me off watching videos like this. With youtube-dl I can also keep the video if I like it — so youtube-dl is my weapon of choice when it comes to dealing with web video.
@mikuphile Yeah, I'm afraid giving exclusive sound card access to Firefox won't cut it for me, I often use mpv and other software, but always leave FF running. I'll look into reducing buffer size, thanks for the tip!
Do you remember which file these values are defined in?
@mikuphile Oh, I see! I think you've misunderstood me then. ALSA itself works perfectly for me — there is no latency issue. Firefox devs are assholes though and don't want have proper support for ALSA. When I use FF with ALSA directly there is no lag, but there's no input from the mic. I have to use this wrapper — apulse, so FF thinks I'm using Pulse, but it introduces a noticeable lag. It's no biggie, but if there is a fix for that it would be great.I thought this is what you were talking about
@mikuphile
> You can download the source of apulse, and in src/apulse-stream.c insert the lines "period_size = 16;" after line 353 and "buffer_size = 64;"
Yes, this is exactly what I wanted! I was browsing through apulse's sources, but I couldn't find it myself 🤭
I'm using Void so adding a patch and rebuilding is easy. I'll try that, thanks!
Actually, I think you can set the buffersize and periodsize of the dmix there, too, but I haven't tried to do it yet. I think it's buffer_size and period_size under slave.