[Solved] Chrome native messaging: can I stream a MediaStream to a native program?

I am writing a web application which needs to show a native window in the host window system. That window must display a video which is being streamed to the web application.

I have written a native program for OS X which displays a video in the way I need, and in the web application I have a MediaStream being sent via WebRTC. I need to connect these together.

I would like to use Chrome’s native messaging, which lets me stream JSON objects to a native program. If I can access the raw data stream from the MediaStream, I should be able to transform this into JSON objects, stream those to the native application, where I can reconstruct the raw video stream.

Is something like this possible?

Read more here: Source link