simplewebrtc / SimpleWebRTC

Simplest WebRTC ever
Other
4.65k stars 1.19k forks source link

Feature request: Please add support of constraints in shareScreen #700

Open lawlietmester opened 6 years ago

lawlietmester commented 6 years ago

I am developing chrome extension and it gets stream another way:

Using this API: https://developer.chrome.com/extensions/desktopCapture

Then navigator.mediaDevices.getUserMedia with specific properties: chromeMediaSource, chromeMediaSourceId;

Right now there is no way to directly append stream

fippo commented 6 years ago

what do you mean by "directly append stream"? Screensharing is supported via https://github.com/otalk/getscreenmedia and its extension

lawlietmester commented 6 years ago

This library also gives you stream. How to add this stream to SimpleWebRTC object?

fippo commented 6 years ago

have you already read the documentation at https://simplewebrtc.com/notsosimple.html#screenshare ?

lawlietmester commented 6 years ago

Ok. Now I understand. The problem is: on the main page in the documentation said: shareScreen(callback)

In code I see: LocalMedia.prototype.startScreenShare = function( constraints, cb )

Code in simplewebrtc.js does not support constraints

JakeTrock commented 6 years ago

can we close this issue?