Remove legacy sound code and simplify platform init.

This commit is contained in:
Paul Chote
2016-08-01 17:39:06 +01:00
parent de85a76c90
commit 9437a86e7e
9 changed files with 38 additions and 92 deletions

View File

@@ -12,20 +12,18 @@
using System.Drawing;
using OpenRA;
[assembly: Platform(typeof(OpenRA.Platforms.Default.DeviceFactory))]
namespace OpenRA.Platforms.Default
{
public class DeviceFactory : IDeviceFactory
public class DefaultPlatform : IPlatform
{
public IGraphicsDevice CreateGraphics(Size size, WindowMode windowMode)
{
return new Sdl2GraphicsDevice(size, windowMode);
}
public ISoundEngine CreateSound()
public ISoundEngine CreateSound(string device)
{
return new OpenAlSoundEngine();
return new OpenAlSoundEngine(device);
}
}
}