Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

播放H265编码ts格式视频链接失败 #30

Open
yuyingfeng1989 opened this issue Oct 7, 2023 · 0 comments
Open

播放H265编码ts格式视频链接失败 #30

yuyingfeng1989 opened this issue Oct 7, 2023 · 0 comments

Comments

@yuyingfeng1989
Copy link

主要按demo调用以下方法播放视频:
mVideoPlayer.setOnPlayerActionListener(new OnPlayerEventListener() {
@OverRide
public AbstractMediaPlayer createMediaPlayer() {
Log.e("TAG","mCurrentMediaCore="+mCurrentMediaCore+" url="+mUrl);
if (1 == mCurrentMediaCore) {
return IjkPlayerFactory.create().createPlayer(context);//IJK解码器
} else if (2 == mCurrentMediaCore) {
return ExoPlayerFactory.create().createPlayer(context);//EXO解码器
} else {
return null;//播放器内部默认的
}
}

public void start(String url) {
if (null != mVideoPlayer) {
this.mUrl=url;
mVideoPlayer.setLoop(false);
mVideoPlayer.setZoomModel(IMediaPlayer.MODE_ZOOM_CROPPING);
mVideoPlayer.setProgressCallBackSpaceTime(300);
mVideoPlayer.getController().setTitle("测试播放地址");//视频标题(默认视图控制器横屏可见)
mVideoPlayer.setDataSource(TextUtils.isEmpty(url)? PATH :url);//播放地址设置
mVideoPlayer.prepareAsync();//开始异步准备播放
}
}

报错信息如下:
E/IJKMEDIA: SDL_JNI_ThreadDestroyed: [28526] didn't call SDL_JNI_DetachThreadEnv() explicity
E/IJKMEDIA: error:00000000:lib(0):func(0):reason(0)
E/IJKMEDIA: https://service.easytaxi.hk:9085/live/00000000018003466468_2.live.ts: I/O error
E/tv.danmaku.ijk.media.player.IjkMediaPlayer: Error (-10000,0)
E/IVideoPlayer: onError,what:-10000,extra:0,reCount:1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant