Type Alias

AudioFile_ReadProc

Reads audio data when used in conjunction with the AudioFileOpenWithCallbacks or AudioFileInitializeWithCallbacks functions.)

Declaration

typedef OSStatus (*AudioFile_ReadProc)(void *inClientData, SInt64 inPosition, UInt32 requestCount, void *buffer, UInt32 *actualCount);

Parameters

inClientData

A pointer to the client data as set in the inClientData parameter to AudioFileOpenWithCallbacks or AudioFileInitializeWithCallbacks.

inPosition

An offset into the data from which to read.

requestCount

The number of bytes to read.

buffer

A pointer to the buffer in which to put the data read.

actualCount

On output, the callback should set this parameter to a pointer to the number of bytes successfully read.

Return Value

A result code. See Result Codes.

Discussion

If you named your function MyAudioFile_ReadProc, you would declare it like this:

Discussion

This callback function is called when Audio File Services needs to read data.

See Also

Callbacks

AudioFile_WriteProc

A callback for writing file data when used in conjunction with the AudioFileOpenWithCallbacks or AudioFileCreateWithURL functions.

AudioFile_GetSizeProc

Gets file data size.

AudioFile_SetSizeProc

Sets file data size.