using initDesktopStream (capture screen and audio)

31 views
Skip to first unread message

Mike - Audrey Humeny

unread,
Oct 31, 2018, 9:23:11 AM10/31/18
to EasyRTC
Hi,
I'm having trouble capturing screen and audio using initDesktopStream.
I'm looking at the code desktop_capture_iframe_version.js (lines 85-96):
                    easyrtc._presetMediaConstraints = {
                        video: {
                            mandatory: {
                                chromeMediaSource:'desktop',
                                chromeMediaSourceId: event.data.chromeMediaSourceId,
                                maxWidth: 1920,
                                maxHeight: 1080,
                                minAspectRatio: 1.77
                            }
                        },
                        audio: false
                    };

the audio constraint is set to false. I've tried setting values but no luck. As soon as I set anything in the audio section, the screen sharing stops working altogether.
According to Muaz Khan, it is possible to also capture audio from screen share. So my question is: what should the audio constraints be set too? What is the correct configuration?
Please help me out!
Many thanks.
Mike.
Reply all
Reply to author
Forward
0 new messages