Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mixing op_raw_seek() and op_pcm_seek() #50

Open
ringtailsoftware opened this issue Jul 24, 2024 · 0 comments
Open

Mixing op_raw_seek() and op_pcm_seek() #50

ringtailsoftware opened this issue Jul 24, 2024 · 0 comments

Comments

@ringtailsoftware
Copy link

I'm working with opusfile on a microcontroller and am trying to speed up seek operations.

My application needs to seek to a known PCM sample so uses op_pcm_seek(). I can see that op_raw_seek() is much faster but it isn't behaving as I'd expect.

My application is looping an audio clip, I am doing something like the following:

op_pcm_seek(of, pcmStartIndex);
rawIndex = op_pcm_tell(of);
...
op_raw_seek(rawIndex)

However, after op_raw_seek() I notice that the first fraction of a second of audio is missing in playback.

Should this work, or is there something else I need to do to work with op_raw_seek()?

Is there a better way of achieving a fast PCM accurate seek?

Thanks.

@ringtailsoftware ringtailsoftware changed the title Mising op_raw_seek() and op_pcm_seek() Mixing op_raw_seek() and op_pcm_seek() Jul 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant