在 ff_ffplay_options.h 开启 { "mediacodec-mpeg4", "MediaCodec: enable MPEG4", OPTION_OFFSET(mediacodec_mpeg4), OPTION_INT(1, 0, 1) },使用ijkplay-example 用例播放mpeg4 格式的视频,无图像,有声音, 1.使用的版本 git checkout -B latest k0.7.5
Activity
xinzhengzhang commentedon Jan 5, 2017
ffprobe your video stream and paste the output
peterhuang007 commentedon Jan 5, 2017
@xinzhengzhang
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'A1.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2mp41
encoder : Lavf57.40.101
Duration: 00:00:02.84, start: 0.000000, bitrate: 724 kb/s
Stream #0:0(und): Video: mpeg4 (Simple Profile) (mp4v / 0x7634706D), yuv420p, 480x640 [SAR 1:1 DAR 3:4], 601 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 30k tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(zho): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 126 kb/s (default)
Metadata:
handler_name : SoundHandler
xinzhengzhang commentedon Jan 5, 2017
add
-enable-decoder=mpeg4
peterhuang007 commentedon Jan 5, 2017
@xinzhengzhang
编译已经配置 --enable-decoders(这个是软件解码的应该和硬件解码没关系吧) 已经开启所有的解码器了,在编译日志里也出现了 Enabled decoders: mpeg4
peterhuang007 commentedon Jan 5, 2017
@xinzhengzhang
A1.mp4.zip
raymond1012 commentedon Jan 5, 2017
不是所有的机器都支持mpeg4的硬解,请直接使用软解。
yuazhen commentedon Jan 6, 2017
not all mpeg4 is supported by MediaCodec. please see #1875
9 remaining items