Receives the output from a user encoder.

BOOL BASS_Encode_UserOutput(
    HENCODE handle,
    QWORD offset,
    void *buffer,
    DWORD length


handleThe encoder handle.
offsetThe file offset of the data... -1 = the current end position.
bufferPointer to the encoded data.
lengthThe amount of data in bytes.

Return value

If successful, TRUE is returned, else FALSE is returned. Use BASS_ErrorGetCode to get the error code.

Error codes

BASS_ERROR_HANDLEhandle is not valid.
BASS_ERROR_NOTAVAILThe encoder was not started with BASS_Encode_StartUser.
BASS_ERROR_POSITIONoffset is beyond the end of the file.
BASS_ERROR_UNKNOWNSome other mystery problem!


This function should only be called from within the encoder's ENCODERPROC callback function.

If a server has been set on the encoder via BASS_Encode_CastInit or BASS_Encode_ServerInit, the server will not receive the data when offset is behind the current end position. The current end position is available from BASS_Encode_GetCount with BASS_ENCODE_COUNT_OUT.

See also