fix vorbis play region issues
parent
90d71b2c0d
commit
eea6e82e4e
|
@ -944,7 +944,7 @@ static void FAudioGMS_INTERNAL_SoundInstance_AddBuffer(FAudioGMS_SoundInstance*
|
||||||
{
|
{
|
||||||
if (instance->loop)
|
if (instance->loop)
|
||||||
{
|
{
|
||||||
stb_vorbis_seek_frame(instance->soundData.streamingSound.fileHandle, instance->playBegin);
|
stb_vorbis_seek(instance->soundData.streamingSound.fileHandle, instance->playBegin);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -1116,7 +1116,7 @@ static void FAudioGMS_INTERNAL_SoundInstance_Stop(FAudioGMS_SoundInstance* insta
|
||||||
|
|
||||||
if (!instance->isStatic)
|
if (!instance->isStatic)
|
||||||
{
|
{
|
||||||
stb_vorbis_seek_frame(instance->soundData.streamingSound.fileHandle, instance->playBegin); /* back to the start */
|
stb_vorbis_seek(instance->soundData.streamingSound.fileHandle, instance->playBegin); /* back to the start */
|
||||||
FAudioGMS_INTERNAL_SoundInstance_AddBuffer(instance); /* preload so we dont stutter on play */
|
FAudioGMS_INTERNAL_SoundInstance_AddBuffer(instance); /* preload so we dont stutter on play */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1313,7 +1313,7 @@ void FAudioGMS_SoundInstance_SetPlayRegion(double soundInstanceID, double startI
|
||||||
else if (!instance->isStatic)
|
else if (!instance->isStatic)
|
||||||
{
|
{
|
||||||
FAudioSourceVoice_FlushSourceBuffers(instance->voice.handle);
|
FAudioSourceVoice_FlushSourceBuffers(instance->voice.handle);
|
||||||
stb_vorbis_seek_frame(instance->soundData.streamingSound.fileHandle, instance->playBegin);
|
stb_vorbis_seek(instance->soundData.streamingSound.fileHandle, instance->playBegin);
|
||||||
FAudioGMS_INTERNAL_SoundInstance_AddBuffer(instance);
|
FAudioGMS_INTERNAL_SoundInstance_AddBuffer(instance);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue