Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/audio/libs/snd_ctl_read.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/audio/libs/snd_ctl_read.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/audio/libs/snd_ctl_read.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/audio/libs/snd_ctl_read.html on line 8

snd_ctl_read()

Read pending control events

Synopsis:

#include <sys/asoundlib.h>

int snd_ctl_read( snd_ctl_t *handle, 
                  snd_ctl_callbacks_t *callbacks );

Arguments:

handle
The handle for the control connection to the card. This must be a handle created by snd_ctl_open().
callbacks
A pointer to a snd_ctl_callbacks_t structure that defines the callbacks for the events.

Library:

libasound.so

Description:

The snd_ctl_read() function reads pending control events from the control handle. As each event is read, the list of callbacks is checked for a handler for this event. If a match is found, the callback is invoked. This function is usually called on the return of the select() library call (see the QNX Library Reference).


Note: If you register to receive notification of events (e.g. by using select()), it's very important that you clear the event queue by calling snd_ctl_read(), even if you don't want or need the information. The event queues are open-ended and may cause trouble if allowed to grow in an uncontrolled manner. The best practice is to read the events in the queues as you receive notification, so that they don't have a chance to accumulate.

Returns:

The number of events read from the handle, or a negative value on error.

Errors:

-EBADF
Invalid file descriptor. Your handle may be corrupt.
-EINTR
The read operation was interrupted by a signal, and either no data was transferred, or the resource manager responsible for that file doesn't report partial transfers.
-EIO
An event I/O error occurred.

Classification:

QNX Neutrino

Safety:
Cancellation point No
Interrupt handler No
Signal handler Yes
Thread Yes

See also:

snd_ctl_callbacks_t, snd_ctl_file_descriptor(), snd_ctl_open()

select() in the QNX Library Reference


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/audio/libs/snd_ctl_read.html on line 161

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/audio/libs/snd_ctl_read.html on line 161