Intel® Collaboration Suite for WebRTC
Community support and discussions on the Intel® Collaboration Suite for WebRTC (Intel® CS for WebRTC).

Intel Webrtc For IE browser (Tip)

Nithin_P_
New Contributor I
227 Views

Hi,

                 This is an important tip,  If any user open intel webrtc solution in internet explorer ( old versions ) you can force them to download a plugin. which is the same webrtc app is loaded and iframe then build desktop exe using electron. so that user get a feel that he can successfully use intel webrtc if ie not supported.He get a feel that "download our plugin and run without using alternate browser"

advantage :

1.screen share working on such electron desktop app without any plugin

2.easy development because it reuses same web app in iframe

3. user get great feel that it support anywhere using our own solution ( browser independ)

disadvantage :

1. have to download and install 20mb exe file 

For supporting screen share we have to  override small code in the client side sdk  

on launching screen share in app in will race exception due to un availability of extension so we have to force screen capture on catch block

......................................................................

.................................

   if (a.video && "screen" === a.video.device) {
       if (k()) return void 0 !== h.video ? h.video.mediaSource = "window" : h.video = {
           mediaSource: "window"
       }, void q.apply(navigator, [h, o, r]);
       var s = a.video.extensionId || "pndohhifhheefbpeljcmnhnkphepimhe",
           t = ["screen", "window", "tab"];
       a.audio && t.push("audio");
       try {
           chrome.runtime.sendMessage(s, {
               getStream: t
           }, function(a) {
               if (void 0 === a) return void("function" == typeof b && b({
                   code: 1103,
                   msg: "screen sharing plugin inaccessible"
               }));
               h.audio = {
                   mandatory: {
                       chromeMediaSource: "desktop",
                       chromeMediaSourceId: a.streamId
                   }
               }, h.video.mandatory = h.video.mandatory || {}, h.video.mandatory.chromeMediaSource = "desktop", h.video.mandatory.chromeMediaSourceId = a.streamId, h.video.height && (h.video.mandatory.maxHeight = h.video.mandatory.minHeight = h.video.height, delete h.video.height), h.video.width && (h.video.mandatory.maxWidth = h.video.mandatory.minWidth = h.video.width, delete h.video.width), h.video.frameRate && ("object" == typeof h.video.frameRate ? (h.video.mandatory.minFrameRate = h.video.frameRate.min, h.video.mandatory.maxFrameRate = h.video.frameRate.max) : "number" == typeof h.video.frameRate ? (h.video.mandatory.minFrameRate = h.video.frameRate, h.video.mandatory.maxFrameRate = h.video.frameRate) : e.Logger.warning("Invalid frame rate value for screen sharing."), delete h.video.frameRate), q.apply(navigator, [h, o, r])
           })
       } catch (u) {

// edited part 
           if (window.location.href == window.top.location.href) {
               "function" == typeof b && b({
                   code: 1103,
                   msg: "screen sharing plugin inaccessible",
                   err: u
               })
           } else {
               h.audio = {
                   mandatory: {
                       chromeMediaSource: "window",
                       chromeMediaSourceId: a.streamId
                   }
               }, h.video.mandatory = h.video.mandatory || {}, h.video.mandatory.chromeMediaSource = "screen", h.video.mandatory.chromeMediaSourceId = a.streamId, h.video.height && (h.video.mandatory.maxHeight = h.video.mandatory.minHeight = h.video.height, delete h.video.height), h.video.width && (h.video.mandatory.maxWidth = h.video.mandatory.minWidth = h.video.width, delete h.video.width), h.video.frameRate && ("object" == typeof h.video.frameRate ? (h.video.mandatory.minFrameRate = h.video.frameRate.min, h.video.mandatory.maxFrameRate = h.video.frameRate.max) : "number" == typeof h.video.frameRate ? (h.video.mandatory.minFrameRate = h.video.frameRate, h.video.mandatory.maxFrameRate = h.video.frameRate) : e.Logger.warning("Invalid frame rate value for screen sharing."), delete h.video.frameRate), q.apply(navigator, [h, o, r])
           }

// edited part end
       }
   } else j() ? q.apply(navigator, [h, o, r]) : q.apply(navigator, [h, o, r])
   }

.......................................

..........................

 

0 Kudos
0 Replies
Reply