Index

Package: Audio_Players

Description

package Audio_Players is

Classes

Audio_Player

type Audio_Player is new Limited_Object and Event_Listener with private;

Ancestors:

Primitive operations:

Construct
Delete (overriding Objects.Delete)
Events.Listeners.To_String (Inherited)
Handle_Event (overriding Events.Listeners.Handle_Event)
Objects.Construct (Inherited)
Objects.To_String (Inherited)
Audio_Player objects listen for certain audio events and play sound effects or music on command. The player contains an internal task for playing audio in the background.

Types

A_Audio_Player

type A_Audio_Player is access all Audio_Player'Class;

Subprograms & Entries

Create_Audio_Player

function Create_Audio_Player
( corral: not null A_Corral ) return A_Audio_Player;
Creates a new Audio_Player that will listen for audio events in 'corral'.

Start

procedure Start
( this: not null access Audio_Player'Class );
Starts the Audio_Player's internal task. This must be called before any audio can be played.

Stop

procedure Stop
( this: not null access Audio_Player'Class );
Stops the audio player's internals task. The destructor will automatically call Stop on deletion if the player hasn't already been stopped.

Delete

procedure Delete
( this: in out A_Audio_Player );
Deletes the Audio_Player.