Home

Awesome

biim

An example for Apple Low Lantency HLS Packager and Origin

Feature

Dependency

Usege

Ingest MPEG-TS Stream to biim's STDIN!

# mpegts (for H.264)
ffmpeg xxx -f mpegts - | ./main.py --port 8080
# fmp4 (for H.264/H.265)
ffmpeg xxx -f mpegts - | ./fmp4.py --port 8080

# watch http://localhost:8080/playlist.m3u8

Options

Example (Generate Test Stream H.265(libx265)/AAC With Timestamp)

ffmpeg -re \
  -f lavfi -i testsrc=700x180:r=30000/1001 \
  -f lavfi -i sine=frequency=1000 \
  -vf "settb=AVTB,setpts='trunc(PTS/1K)*1K+st(1,trunc(RTCTIME/1K))-1K*trunc(ld(1)/1K)',drawtext=fontsize=60:fontcolor=black:text='%{localtime}.%{eif\:1M*t-1K*trunc(t*1K)\:d\:3}'" \
  -c:v libx265 -tune zerolatency -preset ultrafast -r 30 -g 15 -pix_fmt yuv420p \
  -c:a aac -ac 1 -ar 48000 \
  -f mpegts - | ./fmp4.py -t 1 -p 0.15 -w 10 --port 8080
# watch http://localhost:8080/playlist.m3u8

Special Thanks