rodio
rodio copied to clipboard
Few questions regarding ogg playback
Hey,
At first glance I could not figure if this is possible so I decided to ask here. Does rodio support simple calls for achieving these things:
- Start playing ogg file at a specific point in seconds
- Get the current position of the ogg file that is playing in seconds (real-time)
Thanks!
Start playing ogg file at a specific point in seconds
The source trait allows this https://docs.rs/rodio/0.14.0/rodio/source/trait.Source.html#method.skip_duration but its not ideal, see #176
Get the current position of the ogg file that is playing in seconds (real-time)
Not that I know of, but it can probably be done by creating an std::time::Instant when you play the file and manually adding on any skipped Durations. You can then call .elapsed() on the original Instant to get current position in seconds.