[Bug 294627] devel/raylib: Fix high audio latency on FreeBSD (OSS backend)
Date: Sun, 19 Apr 2026 23:29:23 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=294627
--- Comment #4 from commit-hook@FreeBSD.org ---
A commit in branch main references this bug:
URL:
https://cgit.FreeBSD.org/ports/commit/?id=911cc855499b3a20e84f13c44104fead37734663
commit 911cc855499b3a20e84f13c44104fead37734663
Author: Martin Filla <freebsd@sysctl.cz>
AuthorDate: 2026-04-19 23:12:48 +0000
Commit: Vladimir Druzenko <vvd@FreeBSD.org>
CommitDate: 2026-04-19 23:21:07 +0000
devel/raylib: Switch to SDL backend, Fix high audio latency on FreeBSD (OSS
backend)
SDL has better Gamepad Support.
On FreeBSD, raylib (via miniaudio) defaults to a massive buffer size
when using the OSS backend. My logs show a "Periods size" of 32768
samples, which creates a latency of ~680ms at 48kHz. This makes the
library unusable for real-time applications and games on FreeBSD.
Patch the bundled src/external/miniaudio.h to force a lower latency
specifically for the OSS driver. By setting the default period size to
10ms and the period count to 2, the latency is reduced to ~10ms without
audio dropouts.
PR: 294647 294627
Tested by: Chédotal Julien <rjdi@wanadoo.fr>
Sponsored by: UNIS Labs
Co-authored-by: Chédotal Julien <rjdi@wanadoo.fr>
Co-authored-by: Vladimir Druzenko <vvd@FreeBSD.org>
MFH: 2026Q2
devel/raylib/Makefile | 12 ++++++------
devel/raylib/files/patch-src_external_miniaudio.h (new) | 11 +++++++++++
2 files changed, 17 insertions(+), 6 deletions(-)
--
You are receiving this mail because:
You are the assignee for the bug.