MediaRecorder.ondataavailable - data size is always 0

泪湿孤枕 提交于 2019-12-01 13:08:50

OK I figured it out!

The reason the recording wasn't working was because I didn't have Chrome's experimental Web Platform Features enabled.

I learnt this by stumbling across this WebRTC Media Recorder samples site https://webrtc.github.io/samples/src/content/getusermedia/record/ - where recording also wasn't working. So I knew it wasn't to do with my specific code.

To enable the flag, go to chrome://flags/ in your Chrome browser, enable the flag and relaunch.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!