MoeClub 44971e114f Update Player.html il y a 6 ans
..
Player 44971e114f Update Player.html il y a 6 ans
README.MD a4efa0a2c8 Update README.MD il y a 6 ans
m3u8.sh 648bd22d91 Update m3u8.sh il y a 6 ans
media.sh 9eb58b489f Update media.sh il y a 6 ans
upload.sh 4b9ba9e7dc Update upload.sh il y a 6 ans
upload_yuque.sh 72cf2a0f81 Update upload_yuque.sh il y a 6 ans

README.MD

获取媒体文件时长

ffprobe -v error -show_entries format=duration -of default=noprint_wrappers=1:nokey=1 <File>

获取媒体文件大小

ffprobe -v error -show_entries format=size -of default=noprint_wrappers=1:nokey=1 <File>

获取媒体文件比特率

ffprobe -v error -show_entries format=bit_rate -of default=noprint_wrappers=1:nokey=1 <File>

视频文件直接切片

ffmpeg -i <File> -threads 2 -thread_type slice -vcodec copy -acodec aac -bsf:v h264_mp4toannexb -map 0 -f segment -segment_list output.m3u8 -segment_time 10 output_%03d.ts

分片时长计算(VBR, 大约)

分片时间 = (文件限制大小[M] * 1024 * 1024) / (媒体文件比特率[b] * 突发码率比率 / 8)
突发码率比率: 1.25 (视情况取值, 大于等于1)