forked from CarGuo/GSYVideoPlayer
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
4 changed files
with
107 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
...-exo_player2/src/main/java/tv/danmaku/ijk/media/exo2/ExoMediaSourceInterceptListener.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package tv.danmaku.ijk.media.exo2; | ||
|
||
import com.google.android.exoplayer2.source.MediaSource; | ||
|
||
import java.io.File; | ||
|
||
/** | ||
* 设置 ExoPlayer 的 MediaSource 创建拦截 | ||
* Created by guoshuyu | ||
* Date: 2018-08-22 | ||
*/ | ||
public interface ExoMediaSourceInterceptListener { | ||
/** | ||
* @param dataSource 链接 | ||
* @param preview 是否带上header,默认有header自动设置为true | ||
* @param cacheEnable 是否需要缓存 | ||
* @param isLooping 是否循环 | ||
* @param cacheDir 自定义缓存目录 | ||
* @return 返回不为空时,使用返回的自定义mediaSource | ||
*/ | ||
MediaSource getMediaSource(String dataSource, boolean preview, boolean cacheEnable, boolean isLooping, File cacheDir); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters