I have an instance of AVQueuePlayer
and I've initialised it with a collection of videos using AVPlayerItem
(let's say I have 10 items), On a button event, I need to play the item of nth index from the collection.
I've used - (void)replaceCurrentItemWithPlayerItem:(AVPlayerItem *)item
but it replaces the current playing item with the passed AVPlayerItem
.
I need to play nth AVPlayerItem
of the AVQueuePlayer
. Any help will be appreciated.