allow optional mixes again; fix openal so it can *tell* when it fails to allocate sources, rather than just copying 400 bytes of ununitialized garbage into our managed space

This commit is contained in:
Chris Forbes
2010-02-05 13:05:03 +13:00
parent 20c631a7f9
commit 3b763d00fd
5 changed files with 26 additions and 13 deletions

View File

@@ -51,8 +51,14 @@ namespace OpenRa.Support
[DllImport("OpenAL32.dll")]
public static extern void alBufferData(int buffer, int format, byte[] data, int size, int freq);
//[DllImport("OpenAL32.dll")]
//public static extern void alGenSources(int n, IntPtr sources);
[DllImport("OpenAL32.dll")]
public static extern void alGenSources(int n, IntPtr sources);
public static extern void alGenSources(int one, out int source);
[DllImport("OpenAL32.dll")]
public static extern int alGetError();
[DllImport("OpenAL32.dll")]
public static extern void alSourcef(int source, int param, float value);