BASS.NET API for the Un4seen BASS Audio LibraryICEcast Constructor (IBaseEncoder)BASS.NET API for the Un4seen BASS Audio Library
Creates an instance for an ICEcast configuration parameter setting.

Namespace: Un4seen.Bass.Misc
Assembly: Bass.Net (in Bass.Net.dll) Version:

public ICEcast(
	IBaseEncoder encoder


Type: Un4seen.Bass.MiscIBaseEncoder
The output encoder instance to be used.

ArgumentExceptionInvalid EncoderType (only OGG, MP3, AAC or FLAC_OGG is supported)!

An instance of this class is needed in order to create a BroadCast instance.

Please note, that you need an appropriate encoder for ICEcast streaming. For MP3 streaming we recommend using the latest stable version of LAME (see EncoderLAME). For OGG streaming we recommend using the latest stable version of oggenc2 (see EncoderOGG).

When streaming in AACplus format an external encoder is needed as well, which accepts pcm data from STDIN and is able to send it's encoded data to STDOUT. As of today the only 'free' AACplus encoders comes with Winamp - you might use the 'enc_aacPlus.exe' (see EncoderWinampAACplus) or 'fhgaacenc.exe' (see EncoderFHGAACplus) with it.

Also take care of all neccessary patent and license issues when streaming or broadcasting!

Use the UseBASS property to decide, whether you want to use the BASS build-in streaming support (default) or if you want to use the BASS.NET internal implementation. The major difference is, that the BASS.NET implementation allows you to use SendData(IntPtr, Int32) manually.


Creates an ICEcast configuration instance.
' create an encoder instance
Dim lame As New EncoderLAME(_recHandle)
lame.LAME_Bitrate = CInt(EncoderLAME.BITRATE.kbps_56)
lame.LAME_Mode = EncoderLAME.LAMEMode.Mono
lame.LAME_TargetSampleRate = CInt(EncoderLAME.SAMPLERATE.Hz_22050)
lame.LAME_Quality = EncoderLAME.LAMEQuality.Quality

' now create the ICEcast instance using LAME
Dim icecast As New ICEcast(lame)
icecast.ServerAddress = ""
icecast.ServerPort = 8000
icecast.Password = "password"
icecast.Mountpoint = "/mystream"
// create an encoder instance
EncoderLAME lame = new EncoderLAME(_recHandle);
lame.LAME_Bitrate = (int)EncoderLAME.BITRATE.kbps_56;
lame.LAME_Mode = EncoderLAME.LAMEMode.Mono;
lame.LAME_TargetSampleRate = (int)EncoderLAME.SAMPLERATE.Hz_22050;
lame.LAME_Quality = EncoderLAME.LAMEQuality.Quality;

// now create the ICEcast instance using LAME
ICEcast icecast = new ICEcast(lame);
icecast.ServerAddress = "";
icecast.ServerPort = 8000;
icecast.Password = "password";
icecast.Mountpoint = "/mystream";
See Also