media permission for videoroom subscriber

39 views
Skip to first unread message

ionic

unread,
Aug 2, 2022, 5:24:12 AM8/2/22
to meetecho-janus
I used videoroom plugin to make this scenario :

like as Instagram live service there are 3 sides :

- 1 main (video/audio/data) publisher
- 1 invited [guest] (video/audio/data) publisher
- many viewers with video/audio/data subscriber of main and invited feeds, and just data publisher additionally 

currently project worked as fine 

Just at the viewer side I have UX and privacy problem !

problem is bad User Experience in viewer side cause of media permission, hence they are just stream watcher they no need to release media permission in their browser but when new remote feed received it need to grant media permission ! 

and I try to change somethings in createOffer and createAnswer attributes.

I find out when new remote feed received in createAnswer offer section if I change "audioSend" and "videoSend" attributes to false then problem is solved and no need to release media permission by viewers but there are no publisher video/audio feeds too . just data channel worked .

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, "data": true},  // We want recvonly audio/video
                        success: function (jsep) {
                            Janus.debug("Got SDP!", jsep);
                            var body = {"request": "start", "room": "1234"};
                            remoteFeed.send({"message": body, "jsep": jsep});
                        },
                        error: function (error) {
                            Janus.error("WebRTC error:", error);
                        }
                    });


Any suggestions ? 
How can I solve this problem ? 
Really viewers (just subscribing) no need to have media permission !
Thank you Janus community 
Reply all
Reply to author
Forward
0 new messages