Using cache in ExoPlayer

后端 未结 10 2179
暖寄归人
暖寄归人 2020-11-29 18:29

I\'m looking for any example of implementing cache in ExoPlayer.

ExoPlayer has in its library different classes concerning cache and Google explain in this video th

10条回答
  •  自闭症患者
    2020-11-29 18:34

    Here is an example which replaces demo data source with OkHttp, default is no cache https://github.com/b95505017/ExoPlayer/commit/ebfdda8e7848a2e2e275f5c0525f614b56ef43a6 https://github.com/b95505017/ExoPlayer/tree/okhttp_http_data_source So, you just need to configure OkHttp cache properly and requests should be cached.

提交回复
热议问题