Skip to content

Commit

Permalink
Update TODO-List.md
Browse files Browse the repository at this point in the history
  • Loading branch information
hauk0101 committed Aug 9, 2017
1 parent e3ecd32 commit 22cfc79
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions TODO-List.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,13 @@ TODO LIST
* 利用node中与FFmpeg相关的第三方插件实现相关需求
* 美化界面

## ffmpeg命令
* ffmpeg -i oceans.mp4 -hls_time 10 -hls_key_info_file file.keyinfo stream.m3u8
* ffmpeg -i oceans.mp4 -c copy -bsf:v h264_mp4toannexb -hls_time 10 -hls_key_info_file file.keyinfo playlist.m3u8
ffmpeg转mp4为加密后的hls
ffmpeg -i oceans.mp4 -hls_time 10 -hls_key_info_file key_info.key ../output/m3u8_encrypt/playlist.m3u8

说明: oceans.mp4 为转换前的文件
-hls_key_info_file key_info.key 为加密相关的文件设置
key_info.key为同视频同级的key信息文件,其中key_info.key文件包含有2个必要的内容:
URI:XXX.key 即在服务器端存放key文件的地址
KEY_PATH:即在视频压缩端存放的key文件地址,应该是用作在播放时服务端进行比较时使用,必须与服务端存放的key文件内容一致
IV:可选值
(暂时只能通过videojs + videojs-contrib-hls进行播放)

0 comments on commit 22cfc79

Please sign in to comment.