Name
StartAudioCapture -- start capturing sound samples (V11.0)
Synopsis
APTR handle = StartAudioCapture(int frequency, int channels, int bits,
                struct hwTagList *tags);
Function
This function is optional and must only be implemented if the HWEXT_AUDIOADAPTER_CAPTURE extension bit has been set. See Extension plugins for details. In that case, it must put the audio hardware in capture mode. Hollywood will pass the capture audio format in the frequency, channels, and bits parameters to this function. The function must return a handle that identifies this capture operation. Hollywood will then pass this handle to GetAudioCapture() to get the captured samples and to StopAudioCapture() to stop the capture.

If your plugin can't put the audio hardware in capture mode or there is another problem, you must return NULL.

Note that if you want Hollywood to call this function, you also must set the HWSAAFLAGS_CAPTURE flag in your call to hw_SetAudioAdapter(). See hw_SetAudioAdapter for details.

Inputs
frequency
audio capture frequency in Hertz (e.g. 44100)
channels
number of channels to capture (will be either 1 or 2)
bits
bit depth of captured audio (will be either 8 or 16)
tags
reserved for future use, will always be NULL currently
Results
handle
handle identifying this audio capture or NULL on error

Show TOC