Example #1
0
 /// <summary>
 /// Extracts the bufferdata from an uncompressed wave-file.
 /// </summary>
 /// <param name="file">The file to load the data from.</param>
 /// <returns>A SoundBufferData object containing the data from the specified file.</returns>
 public static SoundBufferData FromWav(string file)
 {
     return(SoundBufferData.FromWav(File.OpenRead(file)));
 }
Example #2
0
 /// <summary>
 /// Loads a new soundfile from an uncompressed wave-file.
 /// </summary>
 /// <param name="file">The filename of the uncompressed wave-file that contains the sound effect.</param>
 public static SoundFile FromWav(string file)
 {
     return(new SoundFile(SoundBufferData.FromWav(file)));
 }
Example #3
0
 /// <summary>
 /// Loads a new soundfile from an uncompressed wave-file.
 /// </summary>
 /// <param name="stream">The filestream containing the sound effect in wave-format.</param>
 public static SoundFile FromWav(Stream stream)
 {
     return(new SoundFile(SoundBufferData.FromWav(stream)));
 }
Example #4
0
 /// <summary>
 /// Creates a new soundbuffer from an uncompressed wave-file.
 /// </summary>
 /// <param name="file">The file to load the data from.</param>
 /// <returns>A SoundBuffer object containing the data from the specified file.</returns>
 public static SoundBuffer FromWav(Stream file)
 {
     return(SoundBuffer.FromData(SoundBufferData.FromWav(file)));
 }