WASM audio problem #1716
Replies: 1 comment
-
I think this has been fixed in the latest version. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi!
I'm getting an exception when playing a SoundEffect with WASM, and the SoundEffect seems to be loading properly (at least I got no exception). Do I need to do something extra with WASM to get sounds played? (eg asking for permission, .... It's my first port to WASM so I'm a bit lost)
at nkast.Wasm.Audio.AudioBufferSourceNode.set_Buffer(AudioBuffer value) at Microsoft.Xna.Platform.Audio.ConcreteSoundEffectInstance.PlatformPlay(Boolean isLooped) at Microsoft.Xna.Framework.Audio.SoundEffectInstance.Play() at Microsoft.Xna.Platform.Audio.AudioService.Play(SoundEffect effect, Single volume, Single pitch, Single pan) Microsoft.Xna.Framework.Audio.SoundEffect.Play(Single volume, Single pitch, Single pan) MyGame.Sound.playSfx(SoundEffect effect) in Sound.cs:line 71
Thanks!
p.s. I'm loading the audio with SoundEffect.FromStream, just in case it's important. (it's a wav)
EDIT: Actually, loading the sound from the content builder works (although I'd prefer not to use the content builder if possible)
Beta Was this translation helpful? Give feedback.
All reactions