summaryrefslogtreecommitdiff
path: root/servers/audio_server.h
diff options
context:
space:
mode:
Diffstat (limited to 'servers/audio_server.h')
-rw-r--r--servers/audio_server.h25
1 files changed, 11 insertions, 14 deletions
diff --git a/servers/audio_server.h b/servers/audio_server.h
index a1a3dde719..80e244aacd 100644
--- a/servers/audio_server.h
+++ b/servers/audio_server.h
@@ -42,7 +42,6 @@ class AudioStream;
class AudioStreamSample;
class AudioDriver {
-
static AudioDriver *singleton;
uint64_t _last_mix_time;
uint64_t _last_mix_frames;
@@ -81,9 +80,6 @@ public:
SPEAKER_SURROUND_71,
};
- static const int DEFAULT_MIX_RATE = 44100;
- static const int DEFAULT_OUTPUT_LATENCY = 15;
-
static AudioDriver *get_singleton();
void set_singleton();
@@ -125,12 +121,14 @@ public:
};
class AudioDriverManager {
-
enum {
MAX_DRIVERS = 10
};
+ static const int DEFAULT_MIX_RATE = 44100;
+ static const int DEFAULT_OUTPUT_LATENCY = 15;
+
static AudioDriver *drivers[MAX_DRIVERS];
static int driver_count;
@@ -146,7 +144,6 @@ public:
class AudioBusLayout;
class AudioServer : public Object {
-
GDCLASS(AudioServer, Object);
public:
@@ -184,7 +181,6 @@ private:
float global_rate_scale;
struct Bus {
-
StringName name;
bool solo;
bool mute;
@@ -237,7 +233,6 @@ private:
void _mix_step();
struct CallbackItem {
-
AudioCallback callback;
void *userdata;
@@ -258,10 +253,14 @@ protected:
public:
_FORCE_INLINE_ int get_channel_count() const {
switch (get_speaker_mode()) {
- case SPEAKER_MODE_STEREO: return 1;
- case SPEAKER_SURROUND_31: return 2;
- case SPEAKER_SURROUND_51: return 3;
- case SPEAKER_SURROUND_71: return 4;
+ case SPEAKER_MODE_STEREO:
+ return 1;
+ case SPEAKER_SURROUND_31:
+ return 2;
+ case SPEAKER_SURROUND_51:
+ return 3;
+ case SPEAKER_SURROUND_71:
+ return 4;
}
ERR_FAIL_V(1);
}
@@ -366,13 +365,11 @@ public:
VARIANT_ENUM_CAST(AudioServer::SpeakerMode)
class AudioBusLayout : public Resource {
-
GDCLASS(AudioBusLayout, Resource);
friend class AudioServer;
struct Bus {
-
StringName name;
bool solo;
bool mute;