DarkPlaces
Game engine based on the Quake 1 engine by id Software, developed by LadyHavoc
 
snd_null.c
Go to the documentation of this file.
1/*
2Copyright (C) 1996-1997 Id Software, Inc.
3
4This program is free software; you can redistribute it and/or
5modify it under the terms of the GNU General Public License
6as published by the Free Software Foundation; either version 2
7of the License, or (at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12
13See the GNU General Public License for more details.
14
15You should have received a copy of the GNU General Public License
16along with this program; if not, write to the Free Software
17Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18
19*/
20// snd_null.c -- include this instead of all the other snd_* files to have
21// no sound code whatsoever
22
23#include "quakedef.h"
24
25cvar_t bgmvolume = {CF_CLIENT | CF_ARCHIVE, "bgmvolume", "1", "volume of background music (such as CD music or replacement files such as sound/cdtracks/track002.ogg)"};
26cvar_t snd_initialized = {CF_CLIENT | CF_READONLY, "snd_initialized", "0", "indicates the sound subsystem is active"};
27
28void S_Init (void)
29{
30}
31
32void S_Terminate (void)
33{
34}
35
36void S_Startup (void)
37{
38}
39
40void S_Shutdown (void)
41{
42}
43
44void S_ClearUsed (void)
45{
46}
47
48void S_PurgeUnused (void)
49{
50}
51
52
53void S_StaticSound (sfx_t *sfx, vec3_t origin, float fvol, float attenuation)
54{
55}
56
57int S_StartSound (int entnum, int entchannel, sfx_t *sfx, vec3_t origin, float fvol, float attenuation)
58{
59 return -1;
60}
61
62int S_StartSound_StartPosition_Flags (int entnum, int entchannel, sfx_t *sfx, vec3_t origin, float fvol, float attenuation, float startposition, int flags, float fspeed)
63{
64 return -1;
65}
66
67void S_StopChannel (unsigned int channel_ind, qbool lockmutex, qbool freesfx)
68{
69}
70
71qbool S_SetChannelFlag (unsigned int ch_ind, unsigned int flag, qbool value)
72{
73 return false;
74}
75
76void S_StopSound (int entnum, int entchannel)
77{
78}
79
81{
82}
83
84void S_SetChannelVolume (unsigned int ch_ind, float fvol)
85{
86}
87
88sfx_t *S_PrecacheSound (const char *sample, qbool complain, qbool levelsound)
89{
90 return NULL;
91}
92
93float S_SoundLength(const char *name)
94{
95 return -1;
96}
97
98qbool S_IsSoundPrecached (const sfx_t *sfx)
99{
100 return false;
101}
102
106
107sfx_t *S_FindName (const char *name)
108{
109 return NULL;
110}
111
112void S_Update(const matrix4x4_t *matrix)
113{
114}
115
117{
118}
119
120qbool S_LocalSound (const char *s)
121{
122 return false;
123}
124
125qbool S_LocalSoundEx (const char *s, int chan, float fvol)
126{
127 return false;
128}
129
131{
132 return 0;
133}
134
136{
137 return 0;
138}
139
140float S_GetChannelPosition (unsigned int ch_ind)
141{
142 return -1;
143}
144
145float S_GetEntChannelPosition(int entnum, int entchannel)
146{
147 return -1;
148}
149
151{
152}
#define CF_READONLY
cvar cannot be changed from the console or the command buffer, and is considered CF_PERSISTENT
Definition cmd.h:54
#define CF_CLIENT
cvar/command that only the client can change/execute
Definition cmd.h:48
#define CF_ARCHIVE
cvar should have its set value saved to config.cfg and persist across sessions
Definition cmd.h:53
float flags
float entnum
vector origin
GLsizei const GLfloat * value
Definition glquake.h:740
const GLchar * name
Definition glquake.h:601
void cmd(string command,...)
#define NULL
Definition qtypes.h:12
vec_t vec3_t[3]
Definition qtypes.h:71
bool qbool
Definition qtypes.h:9
void S_Terminate(void)
Definition snd_null.c:32
void S_Update(const matrix4x4_t *matrix)
Definition snd_null.c:112
void SndSys_SendKeyEvents(void)
if the sound system can generate events, send them
Definition snd_null.c:150
void S_StaticSound(sfx_t *sfx, vec3_t origin, float fvol, float attenuation)
Definition snd_null.c:53
void S_SetChannelVolume(unsigned int ch_ind, float fvol)
Definition snd_null.c:84
void S_StopAllSounds(void)
Definition snd_null.c:116
int S_StartSound(int entnum, int entchannel, sfx_t *sfx, vec3_t origin, float fvol, float attenuation)
S_StartSound returns the channel index, or -1 if an error occurred.
Definition snd_null.c:57
qbool S_LocalSoundEx(const char *s, int chan, float fvol)
Definition snd_null.c:125
cvar_t bgmvolume
Definition snd_null.c:25
void S_ClearUsed(void)
Definition snd_null.c:44
void S_PurgeUnused(void)
Definition snd_null.c:48
float S_GetChannelPosition(unsigned int ch_ind)
Definition snd_null.c:140
void S_Startup(void)
Definition snd_null.c:36
void S_StopChannel(unsigned int channel_ind, qbool lockmutex, qbool freesfx)
Definition snd_null.c:67
int S_GetSoundRate(void)
Definition snd_null.c:130
void S_PauseGameSounds(qbool toggle)
Definition snd_null.c:80
sfx_t * S_FindName(const char *name)
Definition snd_null.c:107
sfx_t * S_PrecacheSound(const char *sample, qbool complain, qbool levelsound)
Definition snd_null.c:88
cvar_t snd_initialized
Definition snd_null.c:26
float S_SoundLength(const char *name)
Definition snd_null.c:93
void S_Shutdown(void)
Definition snd_null.c:40
qbool S_SetChannelFlag(unsigned int ch_ind, unsigned int flag, qbool value)
Definition snd_null.c:71
int S_GetSoundChannels(void)
Definition snd_null.c:135
float S_GetEntChannelPosition(int entnum, int entchannel)
Definition snd_null.c:145
void S_Init(void)
Definition snd_null.c:28
qbool S_IsSoundPrecached(const sfx_t *sfx)
Definition snd_null.c:98
void S_UnloadAllSounds_f(cmd_state_t *cmd)
Definition snd_null.c:103
void S_StopSound(int entnum, int entchannel)
Definition snd_null.c:76
int S_StartSound_StartPosition_Flags(int entnum, int entchannel, sfx_t *sfx, vec3_t origin, float fvol, float attenuation, float startposition, int flags, float fspeed)
Definition snd_null.c:62
qbool S_LocalSound(const char *s)
Definition snd_null.c:120
command interpreter state - the tokenizing and execution of commands, as well as pointers to which cv...
Definition cmd.h:127
Definition cvar.h:66