Пример #1
0
 private void Initialize(byte[] data, ALFormat format, int size, int frequency, float volume, bool looping)
 {
     Sound.InitilizeSoundServices();
     this.bufferID = AL.GenBuffer();
     this.sourceID = AL.GenSource();
     try
     {
         AL.BufferData <byte>(this.bufferID, format, data, size, frequency);
         AL.Source(this.sourceID, ALSourcei.Buffer, this.bufferID);
     }
     catch (Exception ex)
     {
         throw ex;
     }
     this.Volume  = volume;
     this.looping = looping;
 }