Node.js support
It'd be nice if this was available as a Node.js library.
It would probably also be fine if the video/audio wasn't supported directly and there was only support for the RTCDataCHannel and RTCPeerConnection
Actually it may be quite simple to get OpenWebRTC running in a Node server. We have a daemon running on Linux (and OS X as well) that can communicate over localhost to the Node server similarly to how our browser extension do, see:
https://github.com/EricssonResearch/openwebrtc-browser-extensions http://www.openwebrtc.io/blog/2014/10/31/webrtc-in-safari-using-openwebrtc
I'm not sure exactly how to do this in Node, but all you would need to do after starting the daemon is to inject this script http://localhost:10717/owr.js in to Node's JavaScript runtime. That should add WebRTC capabilities to it.
There is also https://github.com/cfsghost/node-gcontext if it's interesting.
Yeah, I was thinking that it'd be more like Node.js being just another environment that has bindings to OpenWebRTC. @superdump's link seems like the direction I was thinking.
Sadly my C/C++ skills are kinda rusty these days so I'll probably either wait for someone else to do it, or brush up when I have time.
Also, out of curiosity, where is the source code for that owr.js file?
It is in the OpenWebRTC repo: https://github.com/EricssonResearch/openwebrtc/blob/master/bridge/client/webrtc.js
Thanks!
@RangerMauve more specifically it's a concatenation of a few files. See here: https://github.com/EricssonResearch/openwebrtc/blob/master/bridge/worker/bridgeserver.js#L225 wbjsonrpc.js is in bridge/shared/ and the others are in bridge/client/.
Any news about this? I'm working on a Node.js distributed system for my research, and I have seen a lot of webrtc library but not any suitable support for Node.js. I found some modules that basically download the chromium project and binds the module to the webrtc layer using node-gyp, it is a huge overhead and not really practical if we need to distributed our system. Its possible to create a simple webrtc client module for node.js using OpenWebrtc? It will be fine if we can have prebuild binaries of the library for OS X, Linux and Windows, and not a 400MB Chromium browser just for using datachannel etc.
Thanks so much for your attention, any help is really appreciated.
For Node it seems that if you just want data channels, then the wrtc module is the standard right now. Doesn't seem to be supporting Windows any time soon, though.
@RangerMauve , thats one of the modules that downloads the Chromium source and compiles everything, it ends in a huge 400MB binary just to use the DataChannel, I don't think that is practical. I think that we would end downloading the web core standard library and creating a full binding for ourselves, that would be the ideal case :(
Oh, really? I didn't know that it was embedding all of chromium in it! That's pretty suboptimal, then.
No news from us. We don't have any plans ourselves to implement the Node.js GObject Introspection support. We would welcome it though.
How to run Openwebrtc Deamon in Linux?
@SrujithPoondla https://github.com/EricssonResearch/openwebrtc/wiki/Running-and-Testing#step-2---running-the-daemon
I am getting like this
srujith@PC:~/cerbero/sources/linux_x86_64/openwebrtc-0.3.0/bridge$ ./openwebrtc-daemon
** (gst-plugin-scanner:29399): CRITICAL **: Couldn't g_module_open libpython. Reason: /usr/lib/libpython2.7.so: cannot open shared object file: No such file or directory {"line":24,"column":32,"sourceURL":"/opt/openwebrtc-0.3/share/seed-gtk3/extensions/Seed.js"}
issue resolved thanks @stefanalund
@SrujithPoondla : please don't ask questions on issues that are unrelated to your problem. Create a new issue instead.
sure @superdump