ios - Changing playback rate of AVPlayer produces choppy Audio -


i using avplayer in app. app supports change of speed of playback of audio , video. initializing player follows.

 avplayeritem * playeritem= [avplayeritem playeritemwithurl:self.audiourl];      playeritem.audiotimepitchalgorithm = avaudiotimepitchalgorithmspectral;      self.player = [avplayer playerwithplayeritem:playeritem];         self.player.allowsexternalplayback= yes; [self.player.currentitem addobserver:self                                   forkeypath:@"status"                                      options:0                                      context:nil]; 

and when have change playback rate of audio follows

self.player.rate = 2.0f; 

it working fine. when change rate property of avplayer start producing choppy voice. have set audiotimepitchalgorithm

avaudiotimepitchalgorithmspectral 

but still producing choppy voice. can tell me doing wrong, or have avoid choppy voice , produce smooth sound.


Comments

Popular posts from this blog

magento2 - Magento 2 admin grid add filter to collection -

Android volley - avoid multiple requests of the same kind to the server? -

Combining PHP Registration and Login into one class with multiple functions in one PHP file -