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

play audio The sound sounds strange #795

Open
butoften opened this issue Aug 17, 2023 · 1 comment
Open

play audio The sound sounds strange #795

butoften opened this issue Aug 17, 2023 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@butoften
Copy link

butoften commented Aug 17, 2023

Flutter 3.10.5
Platform : iOS or macos

when use this code ,it's ok,the sound is ok.

AssetsAudioPlayer audioPlayer = AssetsAudioPlayer();
await audioPlayer.open(
  Audio("assets/s.mp3"),
  autoStart: false,
);
audioPlayer.play();

When i use this ,let it auto play ,the sound becomes muffled

AssetsAudioPlayer audioPlayer = AssetsAudioPlayer();
audioPlayer.open(
      Audio("assets/s.mp3"),
);

s.mp3 is the sound of a drum,relatively short
you can download the s.mp3 file to assets folder and test.
https://github.com/butoften/assets/blob/main/s.mp3

thanks

@butoften butoften added the bug Something isn't working label Aug 17, 2023
@nohli
Copy link
Contributor

nohli commented Aug 24, 2023

Does it make a difference if you await open() in the second version?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants