flash.media.SoundMixer: All your sound belong to us

Seems the SoundMixer class is a singleton. And a big one - it exists across multiple swfs and domains. Which leads to a bit of a problem.

For example, open the following urls in separate tabs in Firefox (allow the first to fully load before opening the second):

AFC Components: Reflection
Joe Satriani

That’s what I did, and (assuming you’ve got the Flash 9.0.115 player installed) you should see the same thing I did: a big security error stating that:

SoundMixer.computeSpectrum: http://www.satriani.com/2004/SatrianiPlayer4.swf cannot access http://www.afcomponents.com/flv/vid/sample.flv.

Seems to be a bit of a problem. Really, you would expect that SoundMixer would isolate itself to sound playing in the current .swf, or at least on the domain. Or, if it is going to grab the sound data from all swfs playing, it should do it without worrying about security and domain boundaries…

Incidentally, this security error doesn’t occur only when it’s cross-domain. I had the same problem when putting two swfs on a page that both attempted to grab computeSpectrum data.

Share me: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • del.icio.us
  • Reddit
  • StumbleUpon
  • Technorati