3

YouTube uses ExoPlayer in Android to play their Videos/Audios but you may have noticed , once you played a video , the next time it plays from the Cache, not from the server stream. I need to add this functionality on my Player, where should I do the customization to get that? OR anyone else (Except YouTube) did that? Proper link or suggestion would be helpful. Thanks

Pralgomathic
  • 108
  • 7

1 Answers1

0

I believe the ExoPlayer does not support caching or saving the video. At least thats what this issue in Sept 2015 says.

You might be able to grab the output buffer and write that as a file.

Safest method probably is to persist the video on your own in the background (means double bandwidth usage) and then do a check whether it was downloaded yet before starting streaming.

Oliver Metz
  • 2,712
  • 2
  • 20
  • 32