Seeking in arsd.simpleaudio?

Adam D Ruppe destructionator at gmail.com
Sun Nov 20 23:03:49 UTC 2022


On Sunday, 20 November 2022 at 20:23:28 UTC, TheZipCreator wrote:
> and it appears that arsd.simpleaudio doesn't have a seek 
> function. Is there a way to do this via other means? I want 
> something like:

Here's the patch for ogg, you can download those two files off 
git master too (i can't tag yet since i have a lot of pending 
stuff before regression testing but you can copy them into your 
current dir or replace the dub cache if you're using that 
directly and it will work)

https://github.com/adamdruppe/arsd/commit/1f6ead0a178a8cfbb284d7719fe38863610165e2

It looks like:

auto controller = aot.playOgg("myAudio.ogg");
controller.seek(5.0); // a float that is seconds in the file


Looking at doing it for mp3 is why I didn't put it in the 
interface yet... my mp3 code ported to D doesn't have a seek 
function! But ogg did, it was just buggy.


More information about the Digitalmars-d-learn mailing list