Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent ALSA audio corruption #43928

Merged
merged 1 commit into from
Nov 28, 2020
Merged

Commits on Nov 27, 2020

  1. Prevent ALSA audio corruption

    When using the ALSA driver, corruption would occur if `snd_pcm_writei`
    was unable to consume the entire sound buffer. This would occur
    frequently on the Raspberry Pi 3 which uses the `snd_bcm2835` audio
    driver.
    
    This bug resulted from incorrect pointer math on line 187, resulting in
    the sample source pointer being advanced by `total * ad->channels` bytes
    instead of `total * ad->channels` samples. In my opinion, the best fix
    is to change `*src` to type `int16_t`, since that is the sample type in
    use.
    
    Fixes godotengine#43927.
    charasyn committed Nov 27, 2020
    Configuration menu
    Copy the full SHA
    25b2f82 View commit details
    Browse the repository at this point in the history