Screen Sharing plugin: adding audio cast streaming

1,068 views
Skip to first unread message

Eric CHALOIN

unread,
Sep 21, 2015, 8:14:11 AM9/21/15
to meetecho-janus
Hi all,

Today there is no support for audio in Screen Sharing plugin, is it planned to add audio cast streaming? I mean casting desktop sound (mixed or not).
I know how to add input audio streaming with AudioBridge but it only features audio from capture devices, not desktop nor app sound capture.

It would be perfect casting to share desktop screen & desktop audio.

Is it a WebRTC limitation? Could you tell me more about it?

Regards,

Eric

Lorenzo Miniero

unread,
Sep 21, 2015, 8:26:44 AM9/21/15
to meetecho-janus
Some time ago you couldn't add an audio track to a video track associated with a screen sharing stream. You can try modifying janus.js to allow for audio to be negotiated. Anyway, if you want to have screensharing + audiobridge, you'll have to use different handles, as they use different plugins.

L.

Eric CHALOIN

unread,
Sep 21, 2015, 9:00:04 AM9/21/15
to meetecho-janus
Do you mean I can select audio source from audiobridge? I mean select my PC sound output, not my mic input source.

I would like to be able to choose my audio source as I do with screensharing when I select the display/window to share. I would like to select e.g my vlc outupt or any application audio output or my whole PC mixed output.

Do you know if I can do it from janus chrome plugin?

Lorenzo Miniero

unread,
Sep 21, 2015, 9:08:38 AM9/21/15
to meetecho-janus
That extension is only for screensharing. It think you're looking for this:

L.

Eric CHALOIN

unread,
Sep 21, 2015, 10:11:24 AM9/21/15
to meetecho-janus
Thanks a lot for your pointer, exactly what I was looking for :)

Cheers,
Eric

Nolan Darilek

unread,
Sep 21, 2015, 10:15:06 AM9/21/15
to meetech...@googlegroups.com
On a related note, if I'm using the videoroom plugin and want to publish
my screen and mic, so I can talk about what is on my screen, how would I
go about that? Do I need a handle for the screen and a second for the
audio send?

Lorenzo Miniero

unread,
Sep 21, 2015, 10:17:47 AM9/21/15
to meetecho-janus
If screensharing and audio can still not be sent over the same PeerConnection, yes. If this can be done, you'll need to edit janus.js, as at the time we disabled audio when screensharing because of that limitation.

L.

fm.mag...@campus.fct.unl.pt

unread,
Jul 20, 2016, 9:19:10 AM7/20/16
to meetecho-janus
How should I edit janus.js in order to enable audio when screensharing?

Lorenzo Miniero

unread,
Jul 20, 2016, 11:59:19 AM7/20/16
to meetecho-janus
I don't think we have any specific code for that. Just add audio:true when capturing the screen and it should work. We probably just have audio:false in the screen sharing demo, which is why there's no audio there.

L.

fm.mag...@campus.fct.unl.pt

unread,
Jul 22, 2016, 8:03:36 AM7/22/16
to meetecho-janus
I've already tried that. I get "WebRTC error... {"name":"ScreenCaptureError","message":""}" just by changing to audio:true on the offer, in the screensharing demo

Lorenzo Miniero

unread,
Jul 22, 2016, 9:58:15 AM7/22/16
to meetecho-janus
Then it might be the browser that doesn't allow audio tracks along screen sharing, not sure about that.

L.

gao....@mydreamplus.com

unread,
Apr 10, 2018, 10:13:07 PM4/10/18
to meetecho-janus

Hi Eric,
     I am doing screen sharing with desktop sound on pc/mac to peer, but I fail to capture desktop sound. I don't know how to attach built-in output audio to screen sharing stream after read the webrtc samples input-output source code at https://github.com/webrtc/samples/tree/gh-pages/src/content/devices/input-output. Could you give me some suggests. thank you in advance.


在 2015年9月21日星期一 UTC+8下午8:14:11,Eric CHALOIN写道:
Reply all
Reply to author
Forward
0 new messages