Prosody Audio Video Format (AVF): API: sm_avfrec_get_data

This function is deprecated.

Prototype Definition

int sm_avfrec_get_data(struct sm_avfrec_get_data_parms *datap)

Parameters

*datap
a structure of the following type:
typedef struct sm_avfrec_get_data_parms {
	tSMAVFrecId avfrec;					/* in */
	char *data;						/* in */
	tSM_INT max_length;					/* in */
	tSM_INT done_length;					/* out */
} SM_AVFREC_GET_DATA_PARMS;

Description

Attempt to read data from a AVF recorder. Less than the maximum will be read when either:

To permit maximum system throughput, this function refuses to read from a AVF recorder whose status has changed since it was last checked. This allows an application to avoid checking the status during bulk data transfer. The application only needs to check the status when a call to sm_avfrec_get_data() returns with done_length equal to zero. This also ensures that status changes are reported at the point in the data at which they occurred, which may be important for some applications.

If an error is reported, the done_length field indicates the amount of data which was read before the error occurred.

Any amount of data (up to max_length) may be returned.

Fields

avfrec (Deprecated)
The AVF recorder.
data (Deprecated)
A pointer to the buffer into which data should be read.
max_length (Deprecated)
The amount of space in the buffer.
done_length (Deprecated)
The amount of data actually read.

Returns

0 if call completed successfully, otherwise a standard error such as:


This function is part of the Prosody Audio Video Format (AVF) API.