基本原理
- 服務(wù)端
使用 [websockify](https://github.com/kanaka/websockify) wrap 一個(gè) rtmp 服務(wù)器地址。 ([yingDev的fork](https://github.com/yingDev/websockify) 增加了base64子協(xié)議檢查)
從rtmp中提取h264流,通過(guò)websocket傳送;rtmp服務(wù)器采用的是AdobeMediaServer
啟動(dòng)websocket代理:./websockify.py 1999 <rtmp_server>:1935
- 瀏覽器
使用 [node-rtmpapi](https://github.com/delian/node-rtmpapi) 解析 RTMP 協(xié)議,完成握手和通信。 ([yingDev的fork](https://github.com/yingDev/node-rtmpapi) 增加了瀏覽器支持、修正了幾個(gè)錯(cuò)誤)
使用webpack打包js