@webex/plugin-meetings 1.156.1 → 1.156.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/meetings/util.js
CHANGED
|
@@ -116,7 +116,7 @@ MeetingsUtil.hasH264Codec = /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__P
|
|
|
116
116
|
_context.prev = 10;
|
|
117
117
|
_context.t0 = _context["catch"](1);
|
|
118
118
|
|
|
119
|
-
_loggerProxy.default.logger.
|
|
119
|
+
_loggerProxy.default.logger.warn('Meetings:util#hasH264Codec --> Error creating peerConnection for H.264 test.');
|
|
120
120
|
|
|
121
121
|
case 13:
|
|
122
122
|
return _context.abrupt("return", hasCodec);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["util.js"],"names":["MeetingsUtil","getMeetingAddedType","type","_LOCUS_ID_","_INCOMING_","_CREATED_","handleRoapMercury","envelope","meetingCollection","data","eventType","LOCUSEVENT","MESSAGE_ROAP","meeting","getByKey","CORRELATION_ID","correlationId","roap","roapEvent","checkForCorrelationId","deviceUrl","locus","devices","self","foundDevice","find","device","url","hasH264Codec","hasCodec","pc","window","RTCPeerConnection","createOffer","offerToReceiveVideo","offer","sdp","match","close","LoggerProxy","logger","
|
|
1
|
+
{"version":3,"sources":["util.js"],"names":["MeetingsUtil","getMeetingAddedType","type","_LOCUS_ID_","_INCOMING_","_CREATED_","handleRoapMercury","envelope","meetingCollection","data","eventType","LOCUSEVENT","MESSAGE_ROAP","meeting","getByKey","CORRELATION_ID","correlationId","roap","roapEvent","checkForCorrelationId","deviceUrl","locus","devices","self","foundDevice","find","device","url","hasH264Codec","hasCodec","pc","window","RTCPeerConnection","createOffer","offerToReceiveVideo","offer","sdp","match","close","LoggerProxy","logger","warn","checkH264Support","options","firstChecked","disableNotifications","delay","maxDuration","shouldTrigger","undefined","shouldStopChecking","Trigger","trigger","file","function","EVENT_TRIGGERS","MEDIA_CODEC_LOADED","log","error","ME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A;AAAA;;AAU5BjB,YAAAA,YAAY;AAVgB;;AAAA;AAAA;AAAA,mBAgBpBA,YAAY,EAhBQ;;AAAA;AAAA;AAAA;AAAA;AAAA;;AAiB5BuB,kCAAQC,OAAR,CACE,IADF,EAEE;AACEC,cAAAA,IAAI,EAAE,eADR;AAEEC,cAAAA,QAAQ,EAAE;AAFZ,aAFF,EAMEC,0BAAeC,kBANjB;;AAQAjB,iCAAYC,MAAZ,CAAmBiB,GAAnB,CAAuB,oEAAvB;;AAzB4B;;AAAA;AAAA,iBA+B1BP,kBA/B0B;AAAA;AAAA;AAAA;;AAgC5BX,iCAAYC,MAAZ,CAAmBkB,KAAnB,CAAyB,8EAAzB;;AAhC4B;;AAAA;AAqC9B;AACA,gBAAIV,aAAJ,EAAmB;AACjBG,oCAAQC,OAAR,CACE,IADF,EAEE;AACEC,gBAAAA,IAAI,EAAE,eADR;AAEEC,gBAAAA,QAAQ,EAAE;AAFZ,eAFF,EAMEC,0BAAeI,mBANjB;;AAQApB,mCAAYC,MAAZ,CAAmBiB,GAAnB,CAAuB,2DAAvB;AACD,aAhD6B,CAkD9B;;;AACA1B,YAAAA,MAAM,CAAC6B,UAAP,CAAkB,YAAM;AACtB,kBAAMC,SAAS,GAAGjB,YAAY,IAAI,mBAAlC;AAEA5C,cAAAA,YAAY,CAAC0C,gBAAb,CAA8BoB,IAA9B,CAAmC,KAAnC,EAAyC;AAAClB,gBAAAA,YAAY,EAAEiB;AAAf,eAAzC;AACD,aAJD,EAIGf,KAJH;;AAnD8B;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GAAhC;;AAAA,WAA+CJ,gBAA/C;AAAA;AAAA;;AAAA,SAA+CA,gBAA/C;AAAA;;eA0De1C,Y","sourcesContent":["/* globals window */\n\nimport {\n _LOCUS_ID_,\n _INCOMING_,\n _CREATED_,\n LOCUSEVENT,\n CORRELATION_ID,\n EVENT_TRIGGERS\n} from '../constants';\nimport LoggerProxy from '../common/logs/logger-proxy';\nimport Trigger from '../common/events/trigger-proxy';\n\n/**\n * Meetings Media Codec Missing Event\n * Emitted when H.264 codec is not\n * found in the browser.\n * @event media:codec:missing\n * @instance\n * @memberof MeetingsUtil\n */\n\n/**\n * Meetings Media Codec Loaded Event\n * Emitted when H.264 codec has been\n * loaded in the browser.\n * @event media:codec:loaded\n * @instance\n * @memberof MeetingsUtil\n */\n\nconst MeetingsUtil = {};\n\nMeetingsUtil.getMeetingAddedType = (type) => (type === _LOCUS_ID_ ? _INCOMING_ : _CREATED_);\n\nMeetingsUtil.handleRoapMercury = (envelope, meetingCollection) => {\n const {data} = envelope;\n const {eventType} = data;\n\n if (eventType === LOCUSEVENT.MESSAGE_ROAP) {\n const meeting = meetingCollection.getByKey(CORRELATION_ID, data.correlationId);\n\n if (meeting) {\n meeting.roap.roapEvent(data);\n }\n }\n};\n\nMeetingsUtil.checkForCorrelationId = (deviceUrl, locus) => {\n let devices = [];\n\n if (locus) {\n if (locus && locus.self && locus.self.devices) {\n devices = locus.self.devices;\n }\n\n const foundDevice = devices.find((device) => device.url === deviceUrl);\n\n if (foundDevice && foundDevice.correlationId) {\n return foundDevice.correlationId;\n }\n }\n\n return false;\n};\n\n\n/**\n * Will check to see if the H.264 media codec is supported.\n * @async\n * @private\n * @returns {Promise<boolean>}\n */\nMeetingsUtil.hasH264Codec = async () => {\n let hasCodec = false;\n\n try {\n const pc = new window.RTCPeerConnection();\n const offer = await pc.createOffer({offerToReceiveVideo: true});\n\n if (offer.sdp.match(/^a=rtpmap:\\d+\\s+H264\\/\\d+/m)) {\n hasCodec = true;\n }\n pc.close();\n }\n catch (error) {\n LoggerProxy.logger.warn('Meetings:util#hasH264Codec --> Error creating peerConnection for H.264 test.');\n }\n\n return hasCodec;\n};\n\n\n/**\n * Notifies the user whether or not the H.264\n * codec is present. Will continuously check\n * until max duration.\n * @async\n * @private\n * @param {object} options\n * @param {Number} options.firstChecked Timestamp in milliseconds\n * @param {boolean} options.disableNotifications Default is false. Boolean to enable/disable notification and events\n * @returns {undefined}\n */\nMeetingsUtil.checkH264Support = async function checkH264Support(options) {\n const {hasH264Codec} = MeetingsUtil;\n const {firstChecked, disableNotifications} = options || {};\n const delay = 5e3; // ms\n const maxDuration = 3e5; // ms\n const shouldTrigger = (firstChecked === undefined);\n const shouldStopChecking = firstChecked && (Date.now() - firstChecked) >= maxDuration;\n\n // Disable notifications and start H.264 download only\n if (disableNotifications) {\n hasH264Codec();\n\n return;\n }\n\n // Codec loaded trigger event notification\n if (await hasH264Codec()) {\n Trigger.trigger(\n this,\n {\n file: 'meetings/util',\n function: 'checkH264Support'\n },\n EVENT_TRIGGERS.MEDIA_CODEC_LOADED\n );\n LoggerProxy.logger.log('Meetings:util#checkH264Support --> H264 codec loaded successfully.');\n\n return;\n }\n\n // Stop checking if past the timelimit\n if (shouldStopChecking) {\n LoggerProxy.logger.error('Meetings:util#checkH264Support --> Timed out waiting for H264 codec to load.');\n\n return;\n }\n\n // Trigger only once\n if (shouldTrigger) {\n Trigger.trigger(\n this,\n {\n file: 'meetings/util',\n function: 'checkH264Support'\n },\n EVENT_TRIGGERS.MEDIA_CODEC_MISSING\n );\n LoggerProxy.logger.log('Meetings:util#checkH264Support --> H264 codec is missing.');\n }\n\n // Keep checking in intervals to see if codec loaded\n window.setTimeout(() => {\n const timestamp = firstChecked || Date.now();\n\n MeetingsUtil.checkH264Support.call(this, {firstChecked: timestamp});\n }, delay);\n};\n\nexport default MeetingsUtil;\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webex/plugin-meetings",
|
|
3
|
-
"version": "1.156.
|
|
3
|
+
"version": "1.156.2",
|
|
4
4
|
"description": "",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"contributors": [
|
|
@@ -24,18 +24,18 @@
|
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@babel/runtime-corejs2": "^7.14.8",
|
|
27
|
-
"@webex/webex-core": "1.156.
|
|
28
|
-
"@webex/internal-plugin-mercury": "1.156.
|
|
27
|
+
"@webex/webex-core": "1.156.2",
|
|
28
|
+
"@webex/internal-plugin-mercury": "1.156.2",
|
|
29
29
|
"webrtc-adapter": "^7.7.0",
|
|
30
30
|
"lodash": "^4.17.21",
|
|
31
31
|
"uuid": "^3.3.2",
|
|
32
32
|
"global": "^4.4.0",
|
|
33
33
|
"ip-anonymize": "^0.1.0",
|
|
34
|
-
"@webex/common": "1.156.
|
|
34
|
+
"@webex/common": "1.156.2",
|
|
35
35
|
"bowser": "^2.11.0",
|
|
36
36
|
"sdp-transform": "^2.12.0",
|
|
37
37
|
"readable-stream": "^3.6.0",
|
|
38
|
-
"@webex/common-timers": "1.156.
|
|
38
|
+
"@webex/common-timers": "1.156.2",
|
|
39
39
|
"btoa": "^1.2.1",
|
|
40
40
|
"javascript-state-machine": "^3.1.0",
|
|
41
41
|
"envify": "^4.1.0"
|
package/src/meetings/util.js
CHANGED
|
@@ -84,7 +84,7 @@ MeetingsUtil.hasH264Codec = async () => {
|
|
|
84
84
|
pc.close();
|
|
85
85
|
}
|
|
86
86
|
catch (error) {
|
|
87
|
-
LoggerProxy.logger.
|
|
87
|
+
LoggerProxy.logger.warn('Meetings:util#hasH264Codec --> Error creating peerConnection for H.264 test.');
|
|
88
88
|
}
|
|
89
89
|
|
|
90
90
|
return hasCodec;
|