source: golgotha/src/i4/sound/sound.cc @ 608

Last change on this file since 608 was 80, checked in by Sam Hocevar, 15 years ago
  • Adding the Golgotha source code. Not sure what's going to be interesting in there, but since it's all public domain, there's certainly stuff to pick up.
File size: 1.5 KB
Line 
1/********************************************************************** <BR>
2  This file is part of Crack dot Com's free source code release of
3  Golgotha. <a href="http://www.crack.com/golgotha_release"> <BR> for
4  information about compiling & licensing issues visit this URL</a>
5  <PRE> If that doesn't help, contact Jonathan Clark at
6  golgotha_source@usa.net (Subject should have "GOLG" in it)
7***********************************************************************/
8
9#include "sound/sound.hh"
10#include "main/main.hh"
11#include "string/string.hh"
12
13i4_sound_manager_class i4_null_sound;
14i4_sound_manager_class *i4_sound_man = &i4_null_sound;
15
16static i4_sound_manager_class *i4_disabled_sound_man = &i4_null_sound;
17
18
19void i4_sound_manager_class::init()
20{
21  for (int i=1; i<i4_global_argc; i++)
22    if (i4_global_argv[i]=="-no_sound")
23      return;
24
25  if (this!=&i4_null_sound)
26    i4_sound_man=this;   
27}
28
29
30i4_sound_manager_class::sound_parameters::sound_parameters
31     (i4_frequency  _frequency,
32      w32           _channels,
33      w32           _sample_size,
34      i4_volume     _volume,
35      i4_pan        _pan,
36      i4_bool       _looping,
37      i4_bool       _reverb,
38      i4_bool       _streaming,
39      i4_bool       _capable_3d)
40{
41  frequency   = _frequency;
42  channels    = _channels;
43  sample_size = _sample_size;
44  volume      = _volume;
45  pan         = _pan;
46  looping     = _looping;
47  reverb      = _reverb;
48  streaming   = _streaming;
49  capable_3d  = _capable_3d;
50}
Note: See TracBrowser for help on using the repository browser.