Jump in the sound file at certain time using trigger

Hi,

I want to be able to jump in a sound file at a certain position.
This is my current code:
_onPlaybackStatusUpdate = playbackStatus => {
const { positionMillis } = playbackStatus;

if (positionMillis >= 76500) {

… await this.soundObject.setPositionAsync(195000);
}
};

The problem with this is that _onPlaybackStatusUpdate only updates every set interval, if I set the interval to 10ms the jump won’t happen when i want it to. It just doesnt work consistently.

Is there a way to add a trigger to do this?

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.