如何学习 websocket ?git
使用 HTML https://github.com/phoboslab/jsmpeg MPEG1 进行播放github
https://w3c.github.io/media-source/ 使用原始 APIweb
使用 canvas 绘制图像,经过 API URL.createObjectURL(Blob or ArrayBuffer) 拿到数据
ArrayBuffer
Blobcanvas
使用 https://socket.io/ 传输视频浏览器
// 检测浏览器是否支持 websocket window.onload=function(){ window.WebSocket = window.WebSocket || window.MozWebSocket; if (!window.WebSocket){ alert("WebSocket not supported by this browser"); }else{ alert("WebSocket supported by this browser"); } }
simplechat
简单的一对多 websocket 例子
一个服务端和多个客户端websocket
sslechoclient
wss://socket
chatclient学习
qmlwebsocketserverthis
standalonesocket.io
WebRTC 直接和摄像头进行交互
https://github.com/webrtc
HTTP Live Streaming