BASS.NET API for the Un4seen BASS Audio LibraryIBaseEncoder InterfaceBASS.NET API for the Un4seen BASS Audio Library
Defines a generalized encoder class interface that a BaseEncoder class must implement.

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

public interface IBaseEncoder

The IBaseEncoder type exposes the following members.

Properties

  NameDescription
Public propertyChannelBitwidth
This property should return the actual bitwidth of the sample data BASS is using with the channel (e.g. 8, 16, 32).
Public propertyChannelHandle
This property should get or sets the channel handle which will be used to create the broadcast encoder class.
Public propertyChannelNumChans
This property should return the actual number of channles of the sample data BASS is using with the channel (e.g. 1=mono, 2=stereo, etc.).
Public propertyChannelSampleRate
This property should return the actual sample rate in Hz of the sample data BASS is using with the channel (e.g. 44100).
Public propertyDefaultOutputExtension
This property should return the default extension of an output file for this encoder (e.g. ".mp3" or ".ogg" etc.).
Public propertyEffectiveBitrate
Specifies the target effective bitrate of the encoder output (in kbps, e.g. 128 kbps).
Public propertyEncoderCommandLine
This property should return an encoder command-line string, which might be used with the BASS_Encode_Start(Int32, String, BASSEncode, ENCODEPROC, IntPtr) method in order to create and start the encoder.
Public propertyEncoderDirectory
This property should get and set the encoder's base directory. It might be used in the EncoderCommandLine implementation to return a fully qualified encoder command-line.
Public propertyEncoderExists
This property should return , if the encoder exists and is available - else should be returned.
Public propertyEncoderHandle
This property should get and set a HENCODE encoder handle as returned by the BASS_Encode_Start(Int32, String, BASSEncode, ENCODEPROC, IntPtr) method if the the encoder has been started (see Start(ENCODEPROC, IntPtr, Boolean)) or 0 (zero), if the encoder has not been started or was stopped (see Stop).
Public propertyEncoderType
This property should return a value indicating which type of content the broadcast encoder implements.
Public propertyForce16Bit
Gets or Sets if a encoding in 16-bit sample data should be forced (default is ).
Public propertyInputFile
Specifies the input file name to be processed by the encoder (null = STDIN).
Public propertyIsActive
This property should return , if the encoder has been started (see Start(ENCODEPROC, IntPtr, Boolean)) and is active - else must be returned.
Public propertyIsPaused
This property should return , only if the encoder has been paused (see Pause(Boolean)) - else must be returned.
Public propertyNoLimit
Gets or Sets if encoding should use the CAST_NOLIMIT flag (which is only needed, if the encoder is used for streaming).
Public propertyOutputFile
Specifies the output file name to be processed by the encoder (null = STDOUT).
Public propertySupportsSTDOUT
This property should return , if the base encoder implementation (resp. the underlying command-line tool being used) support STDOUT for output of the encoded data - else must be returned.
Public propertyTAGs
Gets or Sets the TAG_INFO structure associated with the encoder.
Public propertyUseAsyncQueue
Gets or Sets if encoding should use an async queue (i.e. the BASS_ENCODE_QUEUE flag).
Top
Methods

  NameDescription
Public methodPause
This method must implement the actual pauseing of the encoder. After the encoder was paused successfully the EncoderHandle must still return a valid HENCODE handle (non-zero).
Public methodStart
This method must implement the actual start of the encoder. After the encoder was started successfully the EncoderHandle must return a valid HENCODE handle.
Public methodStop
This method must implement the actual stop of the encoder. After the encoder was stopped successfully the EncoderHandle must return 0 (zero).
Top
Remarks

This interface is for example used in the constructor of a streaming server parameter class (e.g. SHOUTcast or ICEcast) to specify which encoder settings should be used.
See Also

Reference