Unknown
From BASS WMA
BASS_WMA_EncodeOpenNetworkMulti
Initializes WMA encoding to the network, using multiple bitrates.
HWMENCODE BASS_WMA_EncodeOpenNetworkMulti(
DWORD freq,
DWORD chans,
DWORD flags,
DWORD *bitrates,
DWORD port,
DWORD clients
);
Parameters
| freq | The sample rate, or a BASS channel handle if the BASS_WMA_ENCODE_SOURCE flag is specified. | ||||||||||||||||
| chans | The number of channels. More than stereo requires WMA Pro or PCM. | ||||||||||||||||
| flags | A combination of these flags.
| ||||||||||||||||
| bitrates | Array of encoding bitrates to use, terminated with a 0. | ||||||||||||||||
| port | The port number for clients to connect to... 0 = let the system choose a port. | ||||||||||||||||
| clients | The maximum number of clients (up to 50) that can be connected. |
Return value
If successful, the new encoder's handle is returned, else FALSE is returned. Use BASS_ErrorGetCode to get the error code.Error codes
| BASS_ERROR_WMA | The Windows Media modules (v9 or above) are not installed. |
| BASS_ERROR_ILLPARAM | clients is invalid. |
| BASS_ERROR_NOTAVAIL | No codec could be found to support the requested sample format and bitrate. |
| BASS_ERROR_UNKNOWN | Some other mystery problem! |
Remarks
This function is identical to BASS_WMA_EncodeOpenNetwork, but with the additional ability to specify multiple bitrates.When encoding/broadcasting in multiple bitrates, the user will automatically get the best available bitrate for their bandwidth.
Example
Initialize encoding 44100hz 16-bit stereo sample data at 128kb/s and 64kb/s, using a system-chosen port, and allowing up to 5 clients.DWORD bitrates[3]={128000,64000,0}; // the bitrates
HWMENCODE encoder=BASS_WMA_EncodeOpenNetworkMulti(44100, 2, 0, bitrates, 0, 5);