PINK: changed way of getting sample

This commit is contained in:
Andrei Prykhodko 2018-06-23 09:54:33 +03:00 committed by Eugene Sandulenko
parent 81f60be7c8
commit c75e048d2c

View File

@ -24,6 +24,7 @@
#define PINK_SOUND_H
#include "audio/mixer.h"
#include "audio/timestamp.h"
#include "common/system.h"
@ -45,7 +46,7 @@ public:
void pause(bool paused) { g_system->getMixer()->pauseHandle(_handle, paused); }
uint64 getCurrentSample() { return (uint64)g_system->getMixer()->getSoundElapsedTime(_handle) * 22050 / 1000; }
uint32 getCurrentSample() { return g_system->getMixer()->getElapsedTime(_handle).totalNumberOfFrames(); }
private:
Audio::SoundHandle _handle;