omnirtc-web 1.7.1 → 1.7.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/aigc.js +6 -6
- package/dist/es-aigc.js +6 -6
- package/dist/es-omnirtc-web.js +2 -2
- package/dist/omnirtc-web.js +2 -2
- package/package.json +1 -1
package/dist/aigc.js
CHANGED
|
@@ -6973,7 +6973,7 @@
|
|
|
6973
6973
|
* @returns
|
|
6974
6974
|
*/
|
|
6975
6975
|
Aigc.prototype.query = function () {
|
|
6976
|
-
return this.request.get('/
|
|
6976
|
+
return this.request.get('/config?appId=' + this.config.engineConfig.adaptAppId);
|
|
6977
6977
|
};
|
|
6978
6978
|
Aigc.prototype.start = function (taskType, config, robotId, options) {
|
|
6979
6979
|
var _a;
|
|
@@ -6984,7 +6984,7 @@
|
|
|
6984
6984
|
this.taskType = taskType;
|
|
6985
6985
|
var ts = Date.now().toString();
|
|
6986
6986
|
var data = __assign((_a = { appId: this.config.engineConfig.adaptAppId, room: this.config.roomStr, user: String(this.config.user), robotId: robotId, taskId: this.taskId, taskType: taskType }, _a[taskType === 'visionchat' ? 'vision' : taskType] = config, _a.ts = ts, _a), options);
|
|
6987
|
-
return this.request.post('/
|
|
6987
|
+
return this.request.post('/start', data, {
|
|
6988
6988
|
headers: {
|
|
6989
6989
|
'X-Auth-TimeStamp': ts,
|
|
6990
6990
|
}
|
|
@@ -7000,7 +7000,7 @@
|
|
|
7000
7000
|
var data = __assign({ appId: this.config.engineConfig.adaptAppId, taskId: this.taskId, taskType: this.taskType, ts: ts }, options);
|
|
7001
7001
|
this.taskId = undefined;
|
|
7002
7002
|
this.taskType = undefined;
|
|
7003
|
-
return this.request.post('/
|
|
7003
|
+
return this.request.post('/stop', data, {
|
|
7004
7004
|
headers: {
|
|
7005
7005
|
'X-Auth-TimeStamp': ts,
|
|
7006
7006
|
}
|
|
@@ -7008,7 +7008,7 @@
|
|
|
7008
7008
|
};
|
|
7009
7009
|
Aigc.prototype.update = function (type, config, options) {
|
|
7010
7010
|
var data = __assign({ appId: this.config.engineConfig.adaptAppId, taskId: this.taskId, type: type, data: config }, options);
|
|
7011
|
-
return this.request.post('/
|
|
7011
|
+
return this.request.post('/update', data);
|
|
7012
7012
|
};
|
|
7013
7013
|
/**
|
|
7014
7014
|
* 绑定事件触发器
|
|
@@ -7043,8 +7043,8 @@
|
|
|
7043
7043
|
}
|
|
7044
7044
|
return taskId;
|
|
7045
7045
|
};
|
|
7046
|
-
Aigc.BASE_URL_TEST = 'https://api2.xueersi.com/rtcapi2stage';
|
|
7047
|
-
Aigc.BASE_URL = 'https://api2.xueersi.com/rtcapi2';
|
|
7046
|
+
Aigc.BASE_URL_TEST = 'https://api2.xueersi.com/rtcapi2stage/api/aigc';
|
|
7047
|
+
Aigc.BASE_URL = 'https://api2.xueersi.com/rtcapi2/api/aigc';
|
|
7048
7048
|
Aigc.DICTIONARY = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
|
|
7049
7049
|
Aigc.UUID = 'd327b12049ac3bfb09925af9ea3b21f9';
|
|
7050
7050
|
return Aigc;
|
package/dist/es-aigc.js
CHANGED
|
@@ -6969,7 +6969,7 @@ var Aigc = /** @class */ (function (_super) {
|
|
|
6969
6969
|
* @returns
|
|
6970
6970
|
*/
|
|
6971
6971
|
Aigc.prototype.query = function () {
|
|
6972
|
-
return this.request.get('/
|
|
6972
|
+
return this.request.get('/config?appId=' + this.config.engineConfig.adaptAppId);
|
|
6973
6973
|
};
|
|
6974
6974
|
Aigc.prototype.start = function (taskType, config, robotId, options) {
|
|
6975
6975
|
var _a;
|
|
@@ -6980,7 +6980,7 @@ var Aigc = /** @class */ (function (_super) {
|
|
|
6980
6980
|
this.taskType = taskType;
|
|
6981
6981
|
var ts = Date.now().toString();
|
|
6982
6982
|
var data = __assign((_a = { appId: this.config.engineConfig.adaptAppId, room: this.config.roomStr, user: String(this.config.user), robotId: robotId, taskId: this.taskId, taskType: taskType }, _a[taskType === 'visionchat' ? 'vision' : taskType] = config, _a.ts = ts, _a), options);
|
|
6983
|
-
return this.request.post('/
|
|
6983
|
+
return this.request.post('/start', data, {
|
|
6984
6984
|
headers: {
|
|
6985
6985
|
'X-Auth-TimeStamp': ts,
|
|
6986
6986
|
}
|
|
@@ -6996,7 +6996,7 @@ var Aigc = /** @class */ (function (_super) {
|
|
|
6996
6996
|
var data = __assign({ appId: this.config.engineConfig.adaptAppId, taskId: this.taskId, taskType: this.taskType, ts: ts }, options);
|
|
6997
6997
|
this.taskId = undefined;
|
|
6998
6998
|
this.taskType = undefined;
|
|
6999
|
-
return this.request.post('/
|
|
6999
|
+
return this.request.post('/stop', data, {
|
|
7000
7000
|
headers: {
|
|
7001
7001
|
'X-Auth-TimeStamp': ts,
|
|
7002
7002
|
}
|
|
@@ -7004,7 +7004,7 @@ var Aigc = /** @class */ (function (_super) {
|
|
|
7004
7004
|
};
|
|
7005
7005
|
Aigc.prototype.update = function (type, config, options) {
|
|
7006
7006
|
var data = __assign({ appId: this.config.engineConfig.adaptAppId, taskId: this.taskId, type: type, data: config }, options);
|
|
7007
|
-
return this.request.post('/
|
|
7007
|
+
return this.request.post('/update', data);
|
|
7008
7008
|
};
|
|
7009
7009
|
/**
|
|
7010
7010
|
* 绑定事件触发器
|
|
@@ -7039,8 +7039,8 @@ var Aigc = /** @class */ (function (_super) {
|
|
|
7039
7039
|
}
|
|
7040
7040
|
return taskId;
|
|
7041
7041
|
};
|
|
7042
|
-
Aigc.BASE_URL_TEST = 'https://api2.xueersi.com/rtcapi2stage';
|
|
7043
|
-
Aigc.BASE_URL = 'https://api2.xueersi.com/rtcapi2';
|
|
7042
|
+
Aigc.BASE_URL_TEST = 'https://api2.xueersi.com/rtcapi2stage/api/aigc';
|
|
7043
|
+
Aigc.BASE_URL = 'https://api2.xueersi.com/rtcapi2/api/aigc';
|
|
7044
7044
|
Aigc.DICTIONARY = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
|
|
7045
7045
|
Aigc.UUID = 'd327b12049ac3bfb09925af9ea3b21f9';
|
|
7046
7046
|
return Aigc;
|
package/dist/es-omnirtc-web.js
CHANGED
|
@@ -5432,7 +5432,7 @@ _stream.addTrack(track.track);context=getAudioContext();source=context.createMed
|
|
|
5432
5432
|
*/function getAudioBuffer(source,cacheOnlineFile){return __awaiter$1(this,void 0,void 0,/*#__PURE__*/regenerator.mark(function _callee228(){var arrayBuffer,cacheAudioBuffer,getFileArrayBuffer,audioBuffer;return regenerator.wrap(function _callee228$(_context243){while(1)switch(_context243.prev=_context243.next){case 0:if(!('string'==typeof source)){_context243.next=15;break;}cacheAudioBuffer=cacheMap.get(source);if(!cacheAudioBuffer){_context243.next=4;break;}return _context243.abrupt("return",cacheAudioBuffer);case 4:_context243.prev=4;_context243.next=7;return getStringArrayBuffer(source);case 7:arrayBuffer=_context243.sent;_context243.next=13;break;case 10:_context243.prev=10;_context243.t0=_context243["catch"](4);throw new CoreRTCError(CoreRTCErrorCode.CHECK_VIDEO_TRACK_ERROR,typeof _context243.t0==='string'?_context243.t0:'fetch audio file failed');case 13:_context243.next=19;break;case 15:getFileArrayBuffer=new Promise(function(resolve,reject){var fileReader=new FileReader();fileReader.addEventListener('load',function(res){if(res.target){resolve(res.target.result);}else {reject(new CoreRTCError(CoreRTCErrorCode.READ_LOCAL_AUDIO_FILE_ERROR,'read local audio file error'));}});fileReader.addEventListener('error',function(){reject(new CoreRTCError(CoreRTCErrorCode.READ_LOCAL_AUDIO_FILE_ERROR,'read local audio file error'));});fileReader.readAsArrayBuffer(source);});_context243.next=18;return getFileArrayBuffer;case 18:arrayBuffer=_context243.sent;case 19:_context243.next=21;return decodeAudioData(arrayBuffer);case 21:audioBuffer=_context243.sent;if('string'==typeof source&&cacheOnlineFile)cacheMap.set(source,audioBuffer);return _context243.abrupt("return",audioBuffer);case 24:case"end":return _context243.stop();}},_callee228,null,[[4,10]]);}));}
|
|
5433
5433
|
|
|
5434
5434
|
var StaticConfig = {
|
|
5435
|
-
agentVersion: "OmniRTC_Web_V1.7.
|
|
5435
|
+
agentVersion: "OmniRTC_Web_V1.7.2",
|
|
5436
5436
|
logVersion: 1,
|
|
5437
5437
|
serviceType: 320,
|
|
5438
5438
|
logBackendUrl: "https://rtc-logs.magic-school.com/stream.gif"
|
|
@@ -8363,7 +8363,7 @@ function log(clsName) {
|
|
|
8363
8363
|
sdk_api_name: '中间层-函数调用',
|
|
8364
8364
|
message: "\u4E2D\u95F4\u5C42-".concat(clsName, ".").concat(name),
|
|
8365
8365
|
from_encapsulation_layer: true,
|
|
8366
|
-
encapsulation_layer_built_timestamp: '2026/
|
|
8366
|
+
encapsulation_layer_built_timestamp: '2026/6/10 17:54:45',
|
|
8367
8367
|
});
|
|
8368
8368
|
}
|
|
8369
8369
|
}
|
package/dist/omnirtc-web.js
CHANGED
|
@@ -5440,7 +5440,7 @@
|
|
|
5440
5440
|
*/function getAudioBuffer(source,cacheOnlineFile){return __awaiter$1(this,void 0,void 0,/*#__PURE__*/regenerator.mark(function _callee228(){var arrayBuffer,cacheAudioBuffer,getFileArrayBuffer,audioBuffer;return regenerator.wrap(function _callee228$(_context243){while(1)switch(_context243.prev=_context243.next){case 0:if(!('string'==typeof source)){_context243.next=15;break;}cacheAudioBuffer=cacheMap.get(source);if(!cacheAudioBuffer){_context243.next=4;break;}return _context243.abrupt("return",cacheAudioBuffer);case 4:_context243.prev=4;_context243.next=7;return getStringArrayBuffer(source);case 7:arrayBuffer=_context243.sent;_context243.next=13;break;case 10:_context243.prev=10;_context243.t0=_context243["catch"](4);throw new CoreRTCError(CoreRTCErrorCode.CHECK_VIDEO_TRACK_ERROR,typeof _context243.t0==='string'?_context243.t0:'fetch audio file failed');case 13:_context243.next=19;break;case 15:getFileArrayBuffer=new Promise(function(resolve,reject){var fileReader=new FileReader();fileReader.addEventListener('load',function(res){if(res.target){resolve(res.target.result);}else {reject(new CoreRTCError(CoreRTCErrorCode.READ_LOCAL_AUDIO_FILE_ERROR,'read local audio file error'));}});fileReader.addEventListener('error',function(){reject(new CoreRTCError(CoreRTCErrorCode.READ_LOCAL_AUDIO_FILE_ERROR,'read local audio file error'));});fileReader.readAsArrayBuffer(source);});_context243.next=18;return getFileArrayBuffer;case 18:arrayBuffer=_context243.sent;case 19:_context243.next=21;return decodeAudioData(arrayBuffer);case 21:audioBuffer=_context243.sent;if('string'==typeof source&&cacheOnlineFile)cacheMap.set(source,audioBuffer);return _context243.abrupt("return",audioBuffer);case 24:case"end":return _context243.stop();}},_callee228,null,[[4,10]]);}));}
|
|
5441
5441
|
|
|
5442
5442
|
var StaticConfig = {
|
|
5443
|
-
agentVersion: "OmniRTC_Web_V1.7.
|
|
5443
|
+
agentVersion: "OmniRTC_Web_V1.7.2",
|
|
5444
5444
|
logVersion: 1,
|
|
5445
5445
|
serviceType: 320,
|
|
5446
5446
|
logBackendUrl: "https://rtc-logs.magic-school.com/stream.gif"
|
|
@@ -8371,7 +8371,7 @@
|
|
|
8371
8371
|
sdk_api_name: '中间层-函数调用',
|
|
8372
8372
|
message: "\u4E2D\u95F4\u5C42-".concat(clsName, ".").concat(name),
|
|
8373
8373
|
from_encapsulation_layer: true,
|
|
8374
|
-
encapsulation_layer_built_timestamp: '2026/
|
|
8374
|
+
encapsulation_layer_built_timestamp: '2026/6/10 17:54:45',
|
|
8375
8375
|
});
|
|
8376
8376
|
}
|
|
8377
8377
|
}
|