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
Does not play with asset source and lowLatency mode (BUG) #1193
Comments
Plz use issue template! Also which platform you running the app? See also the parity table |
I have provided more info using bug form. This is on Android. |
Same issue with me |
This problem also exists for me |
Same, lowlatency just does not work. On real device and emulator. |
Same issue on Android 10 |
Looks like the same issue as #1176 ! |
Hi
I am only getting it on pixel 4 emulator. Works fine on pixel 5.
Also I do get an error, other user is not getting an error, just no sound.
D
From: ***@***.***>
Sent: Monday, July 4, 2022 10:53 PM
To: ***@***.***>
Cc: ***@***.***>; ***@***.***>
Subject: Re: [bluefireteam/audioplayers] Does not play with asset source and lowLatency mode (BUG) (Issue #1193)
Looks like the same issue as #1176<#1176> !
—
Reply to this email directly, view it on GitHub<#1193 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AA5N3HX6Y3C5K67U3OL7KYDVSK7BDANCNFSM5Z2FYE3A>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
has anyone found a solution to this issue? |
As a workaround you can remove the low latency mode. Hopefully it will get fixed one day |
As I am working on a percussion based system I need my sounds to overlay one another. Removing the low latency mode gives me lots of delays :( yeah hopefully we get an update soon |
@Gustl22 are you going to consider fixing this issue or not? Not much activity since your comment that the proper form should be used, which I have done... |
same . |
@under3415 I currently working on some tests which touches all implementations of the various platforms, and will also include tests for |
Can we get a new release on pub.dev with this fix ? |
yes please. Can we have an update release? I need this to be fixed desperately:( |
We still have some open Merge Requests which include fixes. In the mean time you can override your dependencies in pubspec.yaml, e.g.:
|
After overriding it doesnt seemed to work for me. In my pubspec.yaml: dependencies: audioplayers: ^1.0.1 dependency_overrides: The play audio function that i called:
Same issue, no sound after adding the PlayMode.lowLatency. May I know if I did something wrong here? |
@leongkeng I noticed you can play a file in lowLatency, but not reusing the player, or play a sample twice. There still seems to be something off. Let's track this in #1176 |
@leongkeng can you test again with current |
I did 'flutter clean' and 'flutter pub cache repair', then flutter pub get. Also I did overriding my dependencies following your previous comments but still did not work. I managed to play one sound then it stops playing, its the same issue. this is my console output after i tried to play a second audio D/CCodec (25605): allocate(c2.android.raw.decoder) |
@leongkeng can you recheck with our example. The tests run fine, so I'm not sure, why it shouldn't work Note that you have to call |
I tried running the example file and the output doesn't seem to be what I needed. It does allow me to play multiple audio but the first audio cuts when the second audio plays. Like you mentioned, I have to call 'stop' before play again means that I cannot have multiple audios playing concurrently? It used to work in This is what i want to achieve, https://drive.google.com/file/d/1bGp0TZdqE9qlamf0560m7pLq3J9I2G5y/view?usp=sharing This is the Github repo that I found and referrered to for my project https://github.com/kenreilly/flutter-drum-machine-demo |
@leongkeng I checked the old implementation. I think this was more a bug than a feature. For each concurrent sound you should use a different instance of an Back then (<= v0.20.x) you could not control the sound in LOW_LATENCY correctly or just pause / stop the last of the sounds which were played concurrently with only one player. This was caused by overwriting the streamId inside the player, although the stream of the old id was still playing. This worked but as soon as the streamId is replaced you could not control the old stream anymore with the player or properly release it. @luanpotter @spydon correct me if I'm wrong |
Low Latency mode does not work on Android
Full Description
Using sound player with
AssetSource
andlowLatency
mode does not work. No sound is played. No error either, it just doesn't do anything.Code to Reproduce
Log Errors
No errors, just does not play sound
Files/URLs/Sources
N/A
Screenshots
N/A
Platforms
Android
** workaround**
Commenting out
PlayerMode
resolves the issue.The text was updated successfully, but these errors were encountered: