Jump to content
  • Advertisement
Sign in to follow this  
orpeus

[SlimDX] AudioBuffer garbage collection

This topic is 2632 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Just in case anyone else runs into this issue, I wanted to describe a problem that I ran into with XAudio2 in SlimDX. I am using looped AudioBuffers in a WPF app. When I started the audio, the tones would initially sound normal, but if I either started interacting with the app or waited for 15-30 seconds, they would start buzzing. On a hunch, I added a reference to the AudioBuffer that I was passing to my SourceVoices in a related object that I am keeping around. After doing so, the problem went away. I am assuming that the AudioBuffer was getting garbage collected in spite of the fact that the SourceVoice still needed it. I hope that this helps someone.

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!