Repository navigation
Accept CoreAudio slices on devices slower than 48 kHz - #9
Closed
thebornster wants to merge 1 commit into
Closed
thebornster wants to merge 1 commit into
thebornster wants to merge 1 commit into
Conversation
thebornster
marked this pull request as ready for review
October 27, 2026 10:57
The maximum frames per slice is reported in device frames, but the render callback checks it against 48 kHz client frames. On a 44.1 kHz output device the converter asks for about 279 client frames per 256-frame slice, so every callback was rejected. The audio ring never drained, the game's audio engine stalled, and the screen stayed black after the intro. Scale the limit by the guest-to-device rate ratio. Signed-off-by: thebornster
thebornster
force-pushed
the
fix-coreaudio-slow-device-slices
branch
from
October 27, 2026 10:58
2368c90 to
7dcffa6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On a 44.1 kHz output device the CoreAudio render callback rejected every slice. The limit it checks is in device frames, but it was compared against 48 kHz client frames, about 279 per 256-frame slice. The audio ring never drained, so the game stayed on a black screen with no sound after the intro. This scales the limit by the rate ratio.
Tested on an M1 MacBook Pro with the built-in speakers at 44.1 kHz: sound plays and the game gets past the intro. Before this fix, the only workaround was switching the device to 48 kHz.
thebornster