Oolite 1.91.0.7677-250528-09ed63a
All Classes Files Functions Variables Typedefs Enumerations Enumerator Properties Macros Modules Pages
OOOpenALController Class Reference

#include <OOOpenALController.h>

Inheritance diagram for OOOpenALController:
Collaboration diagram for OOOpenALController:

Instance Methods

(void) - setMasterVolume:
(ALfloat) - masterVolume
(void) - shutdown
(id) - init

Class Methods

(OOOpenALController *) + sharedController

Private Attributes

ALCdevice * device
ALCcontext * context

Detailed Description

Definition at line 35 of file OOOpenALController.h.

Method Documentation

◆ masterVolume

- (ALfloat) masterVolume

Definition at line 94 of file OOOpenALController.m.

95{
96 ALfloat fraction = 0.0;
97 OOAL(alGetListenerf(AL_GAIN,&fraction));
98 return fraction;
99}
#define OOAL(cmd)
Definition OOOpenAL.h:40

References masterVolume, and OOAL.

Referenced by OOSound::masterVolume, masterVolume, and OOSound::setMasterVolume:.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setMasterVolume:

- (void) setMasterVolume: (ALfloat) fraction

Definition at line 89 of file OOOpenALController.m.

89 :(ALfloat) fraction
90{
91 OOAL(alListenerf(AL_GAIN,fraction));
92}

References OOAL.

Referenced by OOSound::setMasterVolume:.

Here is the caller graph for this function:

◆ sharedController

+ (OOOpenALController *) sharedController

Definition at line 34 of file OOOpenALController.m.

35{
36 if (sSingleton == nil)
37 {
38 sSingleton = [[self alloc] init];
39 }
40
41 return sSingleton;
42}
static OODebugMonitor * sSingleton
return nil

References nil, sharedController, and sSingleton.

Referenced by OOSound::masterVolume, OOSound::setMasterVolume:, OOSound::setUp, and sharedController.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ shutdown

- (void) shutdown

Definition at line 103 of file OOOpenALController.m.

104{
105 [[OOSoundMixer sharedMixer] shutdown];
106 OOAL(alcMakeContextCurrent(NULL));
107 OOAL(alcDestroyContext(context));
108 OOAL(alcCloseDevice(device));
109}

References context, device, OOAL, OOSoundMixer::sharedMixer, and shutdown.

Referenced by shutdown.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ context

- (ALCcontext*) context
private

Definition at line 39 of file OOOpenALController.h.

Referenced by init, and shutdown.

◆ device

- (ALCdevice*) device
private

Definition at line 38 of file OOOpenALController.h.

Referenced by init, and shutdown.


The documentation for this class was generated from the following files: