Skip to content

Commit

Permalink
Allow Streaming plugin to relay datachannels, and VideoRoom to forwar…
Browse files Browse the repository at this point in the history
…d them
  • Loading branch information
lminiero committed Jan 30, 2017
1 parent 543cffc commit 25d3a82
Show file tree
Hide file tree
Showing 4 changed files with 411 additions and 94 deletions.
3 changes: 3 additions & 0 deletions conf/janus.plugin.streaming.cfg.sample.in
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
; audio = yes|no (do/don't stream audio)
; video = yes|no (do/don't stream video)
; The following options are only valid for the 'rtp' type:
; data = yes|no (do/don't stream text via datachannels)
; audioport = local port for receiving audio frames
; audiomcast = multicast group port for receiving audio frames, if any
; audiopt = <audio RTP payload type> (e.g., 111)
Expand All @@ -29,6 +30,8 @@
; videortpmap = RTP map of the video codec (e.g., VP8/90000)
; videobufferkf = yes|no (whether the plugin should store the latest
; keyframe and send it immediately for new viewers, EXPERIMENTAL)
; databuffermsg = yes|no (whether the plugin should store the latest
; message and send it immediately for new viewers)
; url = RTSP stream URL (only for restreaming RTSP)
;
; To test the [gstreamer-sample] example, check the test_gstreamer.sh
Expand Down
5 changes: 4 additions & 1 deletion html/videoroomtest.js
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,8 @@ function publishOwnFeed(useAudio) {
$('#publish').attr('disabled', true).unbind('click');
sfutest.createOffer(
{
media: { audioRecv: false, videoRecv: false, audioSend: useAudio, videoSend: true}, // Publishers are sendonly
// Add data:true here if you want to publish datachannels as well
media: { audioRecv: false, videoRecv: false, audioSend: useAudio, videoSend: true }, // Publishers are sendonly
success: function(jsep) {
Janus.debug("Got publisher SDP!");
Janus.debug(jsep);
Expand Down Expand Up @@ -433,6 +434,8 @@ function newRemoteFeed(id, display) {
remoteFeed.createAnswer(
{
jsep: jsep,
// Add data:true here if you want to subscribe to datachannels as well
// (obviously only works if the publisher offered them in the first place)
media: { audioSend: false, videoSend: false }, // We want recvonly audio/video
success: function(jsep) {
Janus.debug("Got SDP!");
Expand Down
Loading

0 comments on commit 25d3a82

Please sign in to comment.