2020-04-22 00:30:55 +02:00
|
|
|
using System.IO;
|
|
|
|
using Microsoft.Xna.Framework.Audio;
|
|
|
|
|
2020-09-16 23:39:01 +02:00
|
|
|
namespace MLEM.Data.Content {
|
2020-05-21 12:53:42 +02:00
|
|
|
/// <inheritdoc />
|
2020-04-22 00:30:55 +02:00
|
|
|
public class SoundEffectReader : RawContentReader<SoundEffect> {
|
|
|
|
|
2020-05-21 12:53:42 +02:00
|
|
|
/// <inheritdoc />
|
2020-04-22 00:30:55 +02:00
|
|
|
protected override SoundEffect Read(RawContentManager manager, string assetPath, Stream stream, SoundEffect existing) {
|
|
|
|
return SoundEffect.FromStream(stream);
|
|
|
|
}
|
|
|
|
|
2020-05-21 12:53:42 +02:00
|
|
|
/// <inheritdoc />
|
2020-04-22 00:30:55 +02:00
|
|
|
public override string[] GetFileExtensions() {
|
|
|
|
return new[] {"ogg", "wav", "mp3"};
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|