RobotWebTools / webrtc_ros

Streaming of ROS Image Topics using WebRTC
Other
131 stars 52 forks source link

WebRTC goal #1

Closed megawac closed 9 years ago

megawac commented 9 years ago

@rctoris out of curiousity whats the goal here?

I'm currently in the middle of implementing a serverside WebRTC node to stream RTP video from a webcam to clients (using Janus).

Are you thinking of making peers other browsers or the robot?

rctoris commented 9 years ago

We are hoping to use this to stream data (image streams, point clouds possibly) to and from the browser. We currently have ROS image streams being sent to and from the browser with <video> tags.

One of our awesome students @mitchellwills is in-charge of the project.

megawac commented 9 years ago

Cool, ping me on gchat (gyeates@clearpathrobotics.com) if you need any help @mitchellwills I've been muddling with the openwebrtc and Janus since Monday afternoon. I decided to go with Janus for Hydro support as I was having some trouble configuring gstreamer 1.4 to work as expected in precise.

As I mentioned I'm mostly interested in RTP video but passing RTMP messages are the easiest part of the spec to work with. As far as ROS transports are concerned are you envisioning a node that passes/fuses topics and a service to get the port?

mitchellwills commented 9 years ago

Yah i've been building this based on Google's WebRTC implementation. Basically the idea was to have a single node that you could connect to to stream video from the robot just like mjpeg_server, etc. The ROS node operates as an HTTP server and accepts websockets. Once a websocket is established it is used as the signaling channel (with no intermediate server).

While I have been developing this for use in my senior project, I have been developing a more general server. The server currently supports streaming a ROS image topic to a web browser and streaming media from the browser (getUserMedia) to a ROS topic. I will hopefully be adding support for bi-directional audio streams as well in the future. too. Additionally, I have been thinking about the ability to use a data channel for the rosbridge protocol (could also extend it to support unreliable transport). Also could look into a more efficient way of transporting pointclouds over the unreliable transport. A client application could also theoretically be developed to stream video to another ROS topic. Right now your limited to one video stream in each direction per peerconnection, but the server supports multiple connections at once.

You can check out my progress here: https://github.com/mitchellwills/webrtc_ros. It should build without issue right now under 14.04 + indigo and will build under 12.04 + hydro if you install the latest version of libvpx from source (see the .travis.yml file). This may be fixable by building against an older version of the webrtc source (currently builds against master). Right now it also builds libusrsctp, libyuv, and libopus from source because they do not appear to be installable through apt.

Not sure what you mean by service to get the port.