Example #1
0
 public ALListener(IAudioErrors errors, IAudioBackend backend)
 {
     _errors   = errors;
     _backend  = backend;
     Volume    = 0.5f;
     _location = new AGSLocation();
 }
Example #2
0
 public ALListener(IAudioErrors errors, IAudioBackend backend)
 {
     _errors   = errors;
     _backend  = backend;
     Volume    = 0.5f;
     _position = new Position();
 }
Example #3
0
        public ALListener(IAudioErrors errors, IAudioBackend backend)
		{
			_errors = errors;
            _backend = backend;
			Volume = 0.5f;
			_location = new AGSLocation ();
		}
Example #4
0
        public ALAudioClip(string id, ISoundData soundData, IAudioSystem system, IAudioErrors errors, IAudioBackend backend)
		{
			_soundData = soundData;
			_errors = errors;
            _backend = backend;
			ID = id;
			_buffer = new Lazy<int> (() => generateBuffer());
			_system = system;
			Volume = 1f;
			Pitch = 1f;
		}
Example #5
0
 public ALAudioClip(string id, ISoundData soundData, IAudioSystem system, IAudioErrors errors, IAudioBackend backend)
 {
     _soundData = soundData;
     _errors    = errors;
     _backend   = backend;
     ID         = id;
     _buffer    = new Lazy <int> (() => generateBuffer());
     _system    = system;
     Volume     = 1f;
     Pitch      = 1f;
 }
Example #6
0
        public ALSound(int source, float volume, float pitch, bool isLooping, float panning, IAudioErrors errors, IAudioBackend backend)
		{
			_tcs = new TaskCompletionSource<object> (null);
            _backend = backend;
			_source = source;
			_volume = volume;
			_pitch = pitch;
			_panning = panning;
			IsLooping = isLooping;
			_errors = errors;
		}
Example #7
0
 public ALSound(int source, float volume, float pitch, bool isLooping, float panning,
                IAudioErrors errors, IAudioBackend backend)
 {
     _tcs      = new TaskCompletionSource <object> (null);
     _backend  = backend;
     _source   = source;
     _volume   = volume;
     _pitch    = pitch;
     _panning  = panning;
     IsLooping = isLooping;
     _errors   = errors;
 }
Example #8
0
 public ALAudioClip(string id, ISoundData soundData, IAudioSystem system, IAudioErrors errors, IAudioBackend backend)
 {
     _soundData     = soundData;
     _errors        = errors;
     _backend       = backend;
     ID             = id;
     _buffer        = new Lazy <int> (() => generateBuffer());
     Duration       = getDuration(soundData.DataLength, soundData.Channels, soundData.BitsPerSample, soundData.SampleRate);
     _playingSounds = new AGSConcurrentHashSet <ISound>();
     _system        = system;
     Volume         = 1f;
     Pitch          = 1f;
 }
Example #9
0
        public ALSound(int source, float duration, float volume, float pitch, bool isLooping, float panning,
                       IConcurrentHashSet <string> tags, IAudioErrors errors, IAudioBackend backend)
        {
            //Using delegates to avoid heap allocations
            modifierChangeCallback = onModifierChanged;

            SoundModifiers = new AGSBindingList <ISoundModifier>(3);
            SoundModifiers.OnListChanged.Subscribe(onModifiersChanged);
            Tags      = tags;
            _tcs      = new TaskCompletionSource <object> (null);
            _backend  = backend;
            _source   = source;
            _volume   = volume;
            Duration  = duration;
            _pitch    = pitch;
            _panning  = panning;
            IsLooping = isLooping;
            _errors   = errors;
        }
Example #10
0
        public ALAudioSystem(IAudioBackend backend, IAudioListener listener, IAudioErrors errors)
		{
            _backend = backend;
            Listener = listener;
			_errors = errors;
		}
Example #11
0
 public ALAudioSystem(IAudioBackend backend, IAudioListener listener, IAudioErrors errors)
 {
     _backend = backend;
     Listener = listener;
     _errors  = errors;
 }