Prechádzať zdrojové kódy

Fix NativeChannel with Lime (#208)

starburst997 8 rokov pred
rodič
commit
77f0ae313a
1 zmenil súbory, kde vykonal 5 pridanie a 3 odobranie
  1. 5 3
      hxd/snd/NativeChannel.hx

+ 5 - 3
hxd/snd/NativeChannel.hx

@@ -17,13 +17,15 @@ private class ChannelMapper extends sdl.SoundChannel {
 }
 #elseif lime_openal
 import lime.audio.openal.AL;
+import lime.audio.openal.ALBuffer;
+import lime.audio.openal.ALSource;
 
 private class ALChannel {
 	var native : NativeChannel;
 	var samples : Int;
 
-	var buffers : Array<lime.audio.openal.ALBuffer>;
-	var src : Int;
+	var buffers : Array<ALBuffer>;
+	var src : ALSource;
 
 	var fbuf : haxe.io.Bytes;
 	var ibuf : haxe.io.Bytes;
@@ -56,7 +58,7 @@ private class ALChannel {
 		}
 	}
 
-	@:noDebug function onSample( buf : Int ) {
+	@:noDebug function onSample( buf : ALBuffer ) {
 		@:privateAccess native.onSample(haxe.io.Float32Array.fromBytes(fbuf));
 
 		// Convert Float32 to Int16