Skip to content

Mixing op_raw_seek() and op_pcm_seek() #50

@ringtailsoftware

Description

@ringtailsoftware

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions