m3u8视频格式播放设置

1.首先安装ffmpeg,code

2.运行命令:ffmpeg -threads 4 -i c:/1.mp4  -vcodec libx264 -f hls -hls_time 300 -hls_list_size n  c:/output.m3u8 ,视频

 hls -hls_time 300 是设置的每一个ts视频文件的时长(单位秒),通常最好不要设置太大thread

3.PC端需经过能播放m3u8的播放器进行播放(如:ckplayer等)ffmpeg

相关文章
相关标签/搜索