convert wav to compressed format like ogg

Is there a way to convert a wav to something like ogg or other compressed format in unity using .net routines or libraries on osx or iphone. I have a program that generates large wav files and I need to convert them to a compressed format that is the similar in quality as mp3. I need to do while the project is running.

OK so you want to store as Wav and convert to mp3 when the applictaion is running.

See with lame.exe and these threads

it is for ASP.NET but you might be able to convert the code as it is C# and lame seems to be part of .NET.