bilibili / bilibili/ijkplayer

Android使用硬解码时,播放视频,画面闪动

Open
#3,906 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C
Stars
33.2k
Forks
8.2k
PR merge metrics
No merged PRs in 30d

Description

![default](https://user-images.githubusercontent.com/18097997/34656743-2b41cd66-f459-11e7-993b-6e28e954c260.gif)

版本
ijkplayer:0.8.4
Android:4.2

设置:
```
/**
* 初始化ijkplayer
*/
private void initIjkPlayer() {
mMediaPlayer = new IjkMediaPlayer();
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_FORMAT,
"analyzemaxduration", 100L);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_FORMAT,
"flush_packets", 1L);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_PLAYER,
"packet-buffering", 1L);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_FORMAT,
"reconnect", 1);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_PLAYER,
"framedrop", 5L);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_PLAYER,
"mediacodec", 1);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_PLAYER,
"soundtouch", 1);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_PLAYER,
"mediacodec-auto-rotate", 1);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_PLAYER,
"mediacodec-handle-resolution-change", 1);
((IjkMediaPlayer) mMediaPlayer).setOption(IjkMediaPlayer.OPT_CATEGORY_CODEC,
"skip_loop_filter", 48);
}
```

Contributor guide

No contributing guide indexed for this repository

Research direction

No source file or test is named. Reproduce playback on Android 4.2 with ijkplayer 0.8.4 using the provided initIjkPlayer settings, especially mediacodec hardware decoding, then trace the relevant playback behavior. Done means identifying the cause of the flickering and verifying stable video playback.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, c
Domain
audio-video-rtc, mobile-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.