Having problem with AudioCVT on Android

Hello guys,

I was porting a old game to Android using SDL2, but when I tested it, some sfx sounded noisy. It worked well on Linux and Windows. I’ve tried to find out what happened and I’ve discovered that the problem is on audio conversion. The audio is a U8 22050hz 1 channel and is converted to S16LSB 22050hz 2 channels, but when it used ARM NEON to convert, some audios got noisy like it’s playing on a old radio. I’ve forced SDL to use SCALAR conversion and it worked well.

Here is a small project that play a damaged audio. I’ve tested on a Motorola One.

Hello,

Did you try with latest SDL sources ? there are a few fix for this:




(take latest file at: https://hg.libsdl.org/SDL/file/f4bfe36ed496/src/audio/SDL_audiocvt.c )

Thank you, it worked. I forgot to look on old bugs :sweat_smile: