@volcengine/vepusher 2.0.4-rc.17 → 2.0.4-rc.18
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/index.es.js +26 -17
- package/dist/index.umd.js +3 -3
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -7477,7 +7477,7 @@ class $_ {
|
|
|
7477
7477
|
page_path_fe: window.location.pathname || "unknown",
|
|
7478
7478
|
page_host_fe: window.location.hostname || "unknown",
|
|
7479
7479
|
sdk_version: "2.0.3",
|
|
7480
|
-
build_version: "1.0.0.
|
|
7480
|
+
build_version: "1.0.0.139",
|
|
7481
7481
|
...r
|
|
7482
7482
|
}
|
|
7483
7483
|
};
|
|
@@ -9793,9 +9793,10 @@ const Cg = async () => {
|
|
|
9793
9793
|
async getSdpWithSdp({
|
|
9794
9794
|
url: e,
|
|
9795
9795
|
offer: t,
|
|
9796
|
-
|
|
9796
|
+
frameRate: r,
|
|
9797
|
+
isReconnect: n
|
|
9797
9798
|
}) {
|
|
9798
|
-
var
|
|
9799
|
+
var a;
|
|
9799
9800
|
return await Sc(
|
|
9800
9801
|
e,
|
|
9801
9802
|
{
|
|
@@ -9806,13 +9807,14 @@ const Cg = async () => {
|
|
|
9806
9807
|
version: "1.0-html",
|
|
9807
9808
|
localSdp: t,
|
|
9808
9809
|
metadata: {
|
|
9809
|
-
platform: "Web"
|
|
9810
|
+
platform: "Web",
|
|
9811
|
+
framerate: r
|
|
9810
9812
|
}
|
|
9811
9813
|
})
|
|
9812
9814
|
},
|
|
9813
9815
|
{
|
|
9814
9816
|
...this._opts,
|
|
9815
|
-
timeout:
|
|
9817
|
+
timeout: n ? 10 * Ja : (a = this._opts) == null ? void 0 : a.timeout
|
|
9816
9818
|
}
|
|
9817
9819
|
);
|
|
9818
9820
|
}
|
|
@@ -9856,6 +9858,7 @@ const Cg = async () => {
|
|
|
9856
9858
|
if (Ie.instance.getCustomRTMAnswerSdp ? d = await this.getCustomRTMAnswerSdp(o) : d = await this.getSdpWithSdp({
|
|
9857
9859
|
url: this._signalUrl,
|
|
9858
9860
|
offer: o,
|
|
9861
|
+
frameRate: r == null ? void 0 : r.frameRate,
|
|
9859
9862
|
isReconnect: r == null ? void 0 : r.isReconnect
|
|
9860
9863
|
}), (d == null ? void 0 : d.code) !== 200)
|
|
9861
9864
|
throw {
|
|
@@ -13057,7 +13060,7 @@ class Uv extends bc {
|
|
|
13057
13060
|
return this._prevStats;
|
|
13058
13061
|
}
|
|
13059
13062
|
async startPush(e, t = {}) {
|
|
13060
|
-
var a, o, d;
|
|
13063
|
+
var a, o, d, c, u, l;
|
|
13061
13064
|
if (t.isReconnect || (this._pushSessionId = Date.now(), O(I.START_PUSH, {
|
|
13062
13065
|
push_url: e,
|
|
13063
13066
|
session_id: this._pushSessionId
|
|
@@ -13118,25 +13121,31 @@ class Uv extends bc {
|
|
|
13118
13121
|
throw new Error(`not support push mode: ${this._pushMode}`);
|
|
13119
13122
|
this._connect = s;
|
|
13120
13123
|
try {
|
|
13121
|
-
!t.isReconnect && ((a = this._reconnectStrategy) != null && a.isActive()) && this._reconnectStrategy.stop({ quiet: !0 }), (o = this._reconnectStrategy) != null && o.isActive() || this.setConnectState(pe.CONNECTING)
|
|
13124
|
+
!t.isReconnect && ((a = this._reconnectStrategy) != null && a.isActive()) && this._reconnectStrategy.stop({ quiet: !0 }), (o = this._reconnectStrategy) != null && o.isActive() || this.setConnectState(pe.CONNECTING);
|
|
13125
|
+
let h;
|
|
13126
|
+
((d = this._composedStream.videoStream) == null ? void 0 : d.frameRate) !== 1 ? h = (c = this._composedStream.videoStream) == null ? void 0 : c.frameRate : h = (u = r == null ? void 0 : r.getSettings()) == null ? void 0 : u.frameRate, await s.publish(
|
|
13122
13127
|
[n, r],
|
|
13123
13128
|
[this._audioBitrate, this._videoBitrate],
|
|
13124
|
-
{
|
|
13129
|
+
{
|
|
13130
|
+
cfg: t.cfg,
|
|
13131
|
+
isReconnect: t.isReconnect,
|
|
13132
|
+
frameRate: h
|
|
13133
|
+
}
|
|
13125
13134
|
), t.isReconnect || (Jo.log("startPush begin"), this._connectionStartDate = Date.now());
|
|
13126
|
-
} catch (
|
|
13127
|
-
const
|
|
13135
|
+
} catch (h) {
|
|
13136
|
+
const p = new zt(
|
|
13128
13137
|
me.PUBLISH_FAILED,
|
|
13129
|
-
|
|
13130
|
-
|
|
13138
|
+
h.message,
|
|
13139
|
+
h
|
|
13131
13140
|
);
|
|
13132
|
-
if (Jo.groupEnd(), (
|
|
13133
|
-
throw this.unpublish({ isReconnecting: !0 }),
|
|
13141
|
+
if (Jo.groupEnd(), (l = this._reconnectStrategy) != null && l.isActive())
|
|
13142
|
+
throw this.unpublish({ isReconnecting: !0 }), p;
|
|
13134
13143
|
this._streamConsumeController.emit(
|
|
13135
13144
|
Q.PushError,
|
|
13136
|
-
|
|
13145
|
+
p
|
|
13137
13146
|
), O(I.STOP_PUSH_STREAM, {
|
|
13138
13147
|
reason: Jt.PushError,
|
|
13139
|
-
error_message:
|
|
13148
|
+
error_message: p.message,
|
|
13140
13149
|
enable_reconnect: !1,
|
|
13141
13150
|
push_mode: this._pushMode,
|
|
13142
13151
|
session_id: this._pushSessionId,
|
|
@@ -13145,7 +13154,7 @@ class Uv extends bc {
|
|
|
13145
13154
|
is_success: !1,
|
|
13146
13155
|
push_url: this._pushUrl,
|
|
13147
13156
|
reason: kt.PushError,
|
|
13148
|
-
error_message:
|
|
13157
|
+
error_message: p.message,
|
|
13149
13158
|
session_id: this._pushSessionId,
|
|
13150
13159
|
push_mode: this._pushMode
|
|
13151
13160
|
}), this.unpublish();
|