From 95692068392d1549a45e88bb985a78e8c0db9ad6 Mon Sep 17 00:00:00 2001 From: Joshua Granick Date: Wed, 15 Feb 2017 12:01:11 -0800 Subject: [PATCH] OpenAL uses total, not relative offset for current time --- lime/_backend/native/NativeAudioSource.hx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lime/_backend/native/NativeAudioSource.hx b/lime/_backend/native/NativeAudioSource.hx index 4346736e3..c748a6901 100644 --- a/lime/_backend/native/NativeAudioSource.hx +++ b/lime/_backend/native/NativeAudioSource.hx @@ -404,9 +404,8 @@ class NativeAudioSource { var ratio = (secondOffset / totalSeconds); var totalOffset = Std.int (dataLength * ratio); - var currentOffset = AL.getSourcei (handle, AL.BYTE_OFFSET); - AL.sourcei (handle, AL.BYTE_OFFSET, totalOffset - currentOffset); + AL.sourcei (handle, AL.BYTE_OFFSET, totalOffset); }