ukasz123 / soundpool

Soundpool plugin for Flutter
87 stars 64 forks source link

Doesn't play full sound in Android #45

Open jacksonw765 opened 4 years ago

jacksonw765 commented 4 years ago

Playing a sound works perfectly in iOS but on android when I play a longer sound like > 20 seconds the audio just cuts off sharply.

Pixel 3XL Android 11 (didn't work on Android 10 either)

brunoleomont commented 3 years ago

Really, don't playing full audio on Android. (J5 Pro - Android 9)

eximius313 commented 11 months ago

Specification od SoundPool states:

Soundpool sounds are expected to be short as they are predecoded into memory. Each decoded sound is internally limited to one megabyte storage, which represents approximately 5.6 seconds at 44.1kHz stereo (the duration is proportionally longer at lower sample rates or a channel mask of mono). A decoded audio sound will be truncated if it would exceed the per-sound one megabyte storage space.

so as far as I understand - only sounds up to 5.6 sec are supported