4 ms·
What kind of video sources provide output via websockets to be proxied to RTMP? OBS and other streaming video tools usually support RTMP themselves and browsers
by difosfor 6y ago
What kind of video sources provide output via websockets to be proxied to RTMP? OBS and other streaming video tools usually support RTMP themselves and browsers only support WebRTC out of the box as far as I know. I'm curious what kind custom browser video streaming solution you're using on the client side.
- Linkd 6y agoI think the inverse of this (RTMP to Websockets) would be more interesting.
- mgamache 6y agoThere is no provision for decompressing raw encoded video frames outside of WebRTC. Yes you can use Media Extensions, but that requires boxing the video. There is also Broadway.js, but that is limited to h264 baseline.
- emmelaich 6y agoLook up there :-) https://news.ycombinator.com/item?id=22921564 https://news.ycombinator.com/item?id=22921564
- iameli 6y agoThis appears to use the MediaStream Recording API (https://developer.mozilla.org/en-US/docs/Web/API/MediaStream_Recording_API https://developer.mozilla.org/en-US/docs/Web/API/MediaStream...) to produce a WebM H.264 stream, which can be sent to the WebSocket. The server then transmuxes this to a FLV H.264 stream for RTMP output.
- giantrobot 6y agoA...WebM H.264 stream? Again, with feeling. This time, try something that's a thing.
- iameli 6y agoThat's what I always assumed you got back when you create a MediaRecorder like so: new MediaRecorder(stream, { mimeType: 'video/webm;codecs=h264' }) Which is what this project does. Is it actually returning something else behind the scenes?
- half-kh-hacker 6y agoWhile WebM usually contains VP8 or VP9, it isn't impossible to throw an h264 stream in there
- microcolonel 6y agoWebM is Matroška, and it can contain H.264 as far as I'm aware. Not sure precisely what browsers decide to do here, but apparently it's something.
- giantrobot 6y agoWebM is a subset of Matroska, if something is returning h.264 inside a WebM container...that's not conforming to the WebM subset. But I guess nothing matters.
- mgamache 6y agoYou get Nal h264 packets from MediaStream. Note MediaStream only supports h264 baseline on Chrome (you can request other profiles, but that's all you get). Not sure about FireFox. https://en.wikipedia.org/wiki/Network_Abstraction_Layer https://en.wikipedia.org/wiki/Network_Abstraction_Layer