BASS.NET API for the Un4seen BASS Audio Library

BassEncBASS_Encode_UserOutput Method

BASS.NET API for the Un4seen BASS Audio Library
Receives the output from a user encoder.

Namespace:  Un4seen.Bass.AddOn.Enc
Assembly:  Bass.Net (in Bass.Net.dll) Version: 2.4.17.5
Syntax

[DllImportAttribute("bassenc")]
public static bool BASS_Encode_UserOutput(
	int handle,
	long offset,
	IntPtr buffer,
	int length
)

Parameters

handle
Type: SystemInt32
The encoder.
offset
Type: SystemInt64
The file offset of the data... -1 = the current end position.
buffer
Type: SystemIntPtr
Pointer to the encoded data.
length
Type: SystemInt32
The amount of data in bytes.

Return Value

Type: Boolean
If successful, is returned, else is returned. Use BASS_ErrorGetCode to get the error code.
Remarks

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(Int32, String, String, String, String, String, String, String, String, Int32, BASSEncodeCast) or BASS_Encode_ServerInit(Int32, String, Int32, Int32, BASSEncodeServer, ENCODECLIENTPROC, IntPtr), 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(Int32, BASSEncodeCount) with BASS_ENCODE_COUNT_OUT.

ERROR CODEDescription
BASS_ERROR_HANDLEhandle is not valid.
BASS_ERROR_NOTAVAILThe encoder was not started with BASS_Encode_StartUser(Int32, String, BASSEncode, ENCODERPROC, IntPtr).
BASS_ERROR_POSITIONoffset is beyond the end of the file.
BASS_ERROR_UNKNOWNSome other mystery problem!

See Also

Reference