[Mono-osx] Playing sounds on OS X
Miguel de Icaza
miguel at novell.com
Sun Feb 13 11:15:04 EST 2011
> I have a C# app that uses System.Media.SoundPlayer. It appears to work (no
> exceptions) but I get no sound from it when running on OS X (it plays fine
> on Windows). I am running on Mono 2.6.3, and built the app on Windows/VS2008
> (target .NET 2.0/x86). The app displays its window and in all other respects
> seems to run OK. Just no sound. I really searched here first, no luck or
> ancient Mono-1.1 related info. I even looked in the Mono 2.6 trunk
> sources... something about ALSA drivers? I then looked for ALSA for MAC OS X
> and found only a scary article on patching something into the kernel, which
> I am unwilling to do as a "shot in the dark" attempt - then what about my
> users' systems???.
> I must be barking up the wrong tree. Does anyone know what I am missing?
Mono does not currently have a backend for using
System.Media.SoundPlayer on OSX. It only has support for Linux at
If you are interested in working on this, the source code is in:
Alternatively, there are entire MacOS bindings in MonoMac, but I have
not used those to play any audio.
More information about the Mono-osx