Name
OpenAudio -- open audio hardware (V8.0)
Synopsis
OpenAudio()
Function
This function can be used to open the audio hardware. It is normally not necessary to call this command because Hollywood will automatically open the audio hardware as soon as it needs it. On AmigaOS and compatibles, however, there are situations where you might need fine-tuned control over the audio hardware, for example because another program tries to get exclusive access to the audio hardware, which means that your script has to release it first. In those situations you might want to call OpenAudio() and CloseAudio() manually. Apart from that particular situation, there is no need to call these functions at all.

Inputs
none

Example
OpenAudio()
OpenMusic(1, "Turrican2_Remix.mod")
PlayMusic(1)
WaitLeftMouse
StopMusic(1)
CloseAudio()
The code above plays "Turrican2_Remix.mod" and then closes the audio hardware, making it possible for other programs on AmigaOS aiming for exclusive audio hardware access to reserve it.

Show TOC