libao documentation

libao version 1.2.0 - 201401271

ao_initialize

declared in "ao/ao.h";

This function initializes the internal libao data structures and loads all of the available plugins. The system and user configuration files are also read at this time if available. ao_initialize() must be called in the main thread and before any other libao functions can be used.

More background on initialization in the main thread: ao_initialize() must be called in the main thread because several sound system interfaces used by libao must be initialized in the main thread. One example is the system aRts interface, which stores some global state in thread-specific keys that it fails to delete on shutdown. If aRts is initialized in a non-main thread that later exits, these undeleted keys will cause a segmentation fault.


void ao_initialize();

Notes

Do not invoke this function more than once before calling ao_shutdown(). If you want to reload the configuration files without restarting your program, first call ao_shutdown(), then call ao_initialize() again.


copyright © 2001-2003 Stan Seibert, 2010-2011 Monty

xiph.org
monty@xiph.org

libao documentation

libao version 1.2.0 - 201401271