@byteplus/react-native-live-pull 1.1.2-rc.1 → 1.1.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/lib/commonjs/index.js
CHANGED
|
@@ -4565,6 +4565,7 @@ var TVLManager = function () {
|
|
|
4565
4565
|
var _enableAudioFrameObserver_decorators;
|
|
4566
4566
|
var _setEnableSuperResolution_decorators;
|
|
4567
4567
|
var _setVolume_decorators;
|
|
4568
|
+
var _setEnableIgnoreAudioInterruption_decorators;
|
|
4568
4569
|
_classThis = /** @class */ (function () {
|
|
4569
4570
|
function TVLManager_1() {
|
|
4570
4571
|
/** {zh}
|
|
@@ -4872,6 +4873,9 @@ var TVLManager = function () {
|
|
|
4872
4873
|
TVLManager_1.prototype.setVolume = function (volume) {
|
|
4873
4874
|
throw new Error('not implement');
|
|
4874
4875
|
};
|
|
4876
|
+
TVLManager_1.prototype.setEnableIgnoreAudioInterruption = function (enable) {
|
|
4877
|
+
throw new Error('not implement');
|
|
4878
|
+
};
|
|
4875
4879
|
return TVLManager_1;
|
|
4876
4880
|
}());
|
|
4877
4881
|
__setFunctionName(_classThis, "TVLManager");
|
|
@@ -4907,6 +4911,7 @@ var TVLManager = function () {
|
|
|
4907
4911
|
_enableAudioFrameObserver_decorators = [NativeMethodSync('enableAudioFrameObserver:enableRendering:')];
|
|
4908
4912
|
_setEnableSuperResolution_decorators = [NativeMethodSync('setEnableSuperResolution:')];
|
|
4909
4913
|
_setVolume_decorators = [NativeMethodSync('setVolume:')];
|
|
4914
|
+
_setEnableIgnoreAudioInterruption_decorators = [NativeMethodSync('setEnableIgnoreAudioInterruption:')];
|
|
4910
4915
|
__esDecorate(_classThis, null, _static_setLogLevel_decorators, { kind: "method", name: "setLogLevel", static: true, private: false, access: { has: function (obj) { return "setLogLevel" in obj; }, get: function (obj) { return obj.setLogLevel; } }, metadata: _metadata }, null, _staticExtraInitializers);
|
|
4911
4916
|
__esDecorate(_classThis, null, _static_getVersion_decorators, { kind: "method", name: "getVersion", static: true, private: false, access: { has: function (obj) { return "getVersion" in obj; }, get: function (obj) { return obj.getVersion; } }, metadata: _metadata }, null, _staticExtraInitializers);
|
|
4912
4917
|
__esDecorate(_classThis, null, _static_setHttpDNSHostIP_decorators, { kind: "method", name: "setHttpDNSHostIP", static: true, private: false, access: { has: function (obj) { return "setHttpDNSHostIP" in obj; }, get: function (obj) { return obj.setHttpDNSHostIP; } }, metadata: _metadata }, null, _staticExtraInitializers);
|
|
@@ -4933,6 +4938,7 @@ var TVLManager = function () {
|
|
|
4933
4938
|
__esDecorate(_classThis, null, _enableAudioFrameObserver_decorators, { kind: "method", name: "enableAudioFrameObserver", static: false, private: false, access: { has: function (obj) { return "enableAudioFrameObserver" in obj; }, get: function (obj) { return obj.enableAudioFrameObserver; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4934
4939
|
__esDecorate(_classThis, null, _setEnableSuperResolution_decorators, { kind: "method", name: "setEnableSuperResolution", static: false, private: false, access: { has: function (obj) { return "setEnableSuperResolution" in obj; }, get: function (obj) { return obj.setEnableSuperResolution; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4935
4940
|
__esDecorate(_classThis, null, _setVolume_decorators, { kind: "method", name: "setVolume", static: false, private: false, access: { has: function (obj) { return "setVolume" in obj; }, get: function (obj) { return obj.setVolume; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4941
|
+
__esDecorate(_classThis, null, _setEnableIgnoreAudioInterruption_decorators, { kind: "method", name: "setEnableIgnoreAudioInterruption", static: false, private: false, access: { has: function (obj) { return "setEnableIgnoreAudioInterruption" in obj; }, get: function (obj) { return obj.setEnableIgnoreAudioInterruption; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4936
4942
|
__esDecorate(null, null, _observer_decorators, { kind: "field", name: "observer", static: false, private: false, access: { has: function (obj) { return "observer" in obj; }, get: function (obj) { return obj.observer; }, set: function (obj, value) { obj.observer = value; } }, metadata: _metadata }, _observer_initializers, _observer_extraInitializers);
|
|
4937
4943
|
__esDecorate(null, null, _playerView_decorators, { kind: "field", name: "playerView", static: false, private: false, access: { has: function (obj) { return "playerView" in obj; }, get: function (obj) { return obj.playerView; }, set: function (obj, value) { obj.playerView = value; } }, metadata: _metadata }, _playerView_initializers, _playerView_extraInitializers);
|
|
4938
4944
|
__esDecorate(null, null, _volume_decorators, { kind: "field", name: "volume", static: false, private: false, access: { has: function (obj) { return "volume" in obj; }, get: function (obj) { return obj.volume; }, set: function (obj, value) { obj.volume = value; } }, metadata: _metadata }, _volume_initializers, _volume_extraInitializers);
|
|
@@ -6723,38 +6729,6 @@ var VeLivePlayerStatistics = function () {
|
|
|
6723
6729
|
enumerable: false,
|
|
6724
6730
|
configurable: true
|
|
6725
6731
|
});
|
|
6726
|
-
Object.defineProperty(VeLivePlayerStatistics_1.prototype, "format", {
|
|
6727
|
-
/** {zh}
|
|
6728
|
-
* @brief 当前播放的视频格式。
|
|
6729
|
-
*
|
|
6730
|
-
*/
|
|
6731
|
-
/** {en}
|
|
6732
|
-
* @brief The video format.
|
|
6733
|
-
*
|
|
6734
|
-
*/
|
|
6735
|
-
get: function () {
|
|
6736
|
-
// TODO: implement
|
|
6737
|
-
throw new Error("not implement 'format'");
|
|
6738
|
-
},
|
|
6739
|
-
enumerable: false,
|
|
6740
|
-
configurable: true
|
|
6741
|
-
});
|
|
6742
|
-
Object.defineProperty(VeLivePlayerStatistics_1.prototype, "protocol", {
|
|
6743
|
-
/** {zh}
|
|
6744
|
-
* @brief 当前播放的传输协议。
|
|
6745
|
-
*
|
|
6746
|
-
*/
|
|
6747
|
-
/** {en}
|
|
6748
|
-
* @brief The transmission protocol of the live stream.
|
|
6749
|
-
*
|
|
6750
|
-
*/
|
|
6751
|
-
get: function () {
|
|
6752
|
-
// TODO: implement
|
|
6753
|
-
throw new Error("not implement 'protocol'");
|
|
6754
|
-
},
|
|
6755
|
-
enumerable: false,
|
|
6756
|
-
configurable: true
|
|
6757
|
-
});
|
|
6758
6732
|
Object.defineProperty(VeLivePlayerStatistics_1.prototype, "url", {
|
|
6759
6733
|
/** {zh}
|
|
6760
6734
|
* @brief 当前直播的播放地址。
|
|
@@ -11384,6 +11358,13 @@ extendsClassMethod(VeLivePlayer, 'destroy', function (origin) {
|
|
|
11384
11358
|
}); });
|
|
11385
11359
|
};
|
|
11386
11360
|
});
|
|
11361
|
+
extendsClassMethod(VeLivePlayer, 'setEnableIgnoreAudioInterruption', function () {
|
|
11362
|
+
return function setEnableIgnoreAudioInterruption(enable) {
|
|
11363
|
+
return runImpl(this, function () { }, function (engine) {
|
|
11364
|
+
engine.setEnableIgnoreAudioInterruption(enable);
|
|
11365
|
+
});
|
|
11366
|
+
};
|
|
11367
|
+
});
|
|
11387
11368
|
|
|
11388
11369
|
extendsClassMethod(android_VeLivePlayerObserver, 'onVideoSizeChanged', function (original) {
|
|
11389
11370
|
return function onVideoSizeChanged(player, width, height) {
|
|
@@ -11641,23 +11622,24 @@ function initAndroidPlayer(options) {
|
|
|
11641
11622
|
}
|
|
11642
11623
|
function initIOSPlayer(options) {
|
|
11643
11624
|
return __awaiter(this, void 0, void 0, function () {
|
|
11644
|
-
var viewId, option, player, config, uiView, multiObserver, manager;
|
|
11625
|
+
var viewId, option, iosPlayer, player, config, uiView, multiObserver, manager;
|
|
11645
11626
|
return __generator(this, function (_a) {
|
|
11646
11627
|
switch (_a.label) {
|
|
11647
11628
|
case 0:
|
|
11648
11629
|
viewId = options.viewId, option = __rest(options, ["viewId"]);
|
|
11649
|
-
|
|
11630
|
+
iosPlayer = new TVLManager();
|
|
11631
|
+
player = packObject(iosPlayer, VeLivePlayer);
|
|
11650
11632
|
config = new VeLivePlayerConfiguration();
|
|
11651
11633
|
Object.assign(config, defaultConfig, option);
|
|
11652
11634
|
player.setConfig(config);
|
|
11653
11635
|
uiView = NativeView.getView(viewId, NativeUIView);
|
|
11654
|
-
return [4 /*yield*/, uiView.insertSubview(
|
|
11636
|
+
return [4 /*yield*/, uiView.insertSubview(iosPlayer.playerView, 0)];
|
|
11655
11637
|
case 1:
|
|
11656
11638
|
_a.sent();
|
|
11657
11639
|
multiObserver = VeLivePlayerMultiObserver.getInstance();
|
|
11658
|
-
multiObserver.setupPlayer(
|
|
11640
|
+
multiObserver.setupPlayer(iosPlayer);
|
|
11659
11641
|
manager = VeLivePictureInPictureManager.getInstance();
|
|
11660
|
-
manager.setupPlayer(
|
|
11642
|
+
manager.setupPlayer(iosPlayer);
|
|
11661
11643
|
return [2 /*return*/, player];
|
|
11662
11644
|
}
|
|
11663
11645
|
});
|
package/lib/module/index.js
CHANGED
|
@@ -4563,6 +4563,7 @@ var TVLManager = function () {
|
|
|
4563
4563
|
var _enableAudioFrameObserver_decorators;
|
|
4564
4564
|
var _setEnableSuperResolution_decorators;
|
|
4565
4565
|
var _setVolume_decorators;
|
|
4566
|
+
var _setEnableIgnoreAudioInterruption_decorators;
|
|
4566
4567
|
_classThis = /** @class */ (function () {
|
|
4567
4568
|
function TVLManager_1() {
|
|
4568
4569
|
/** {zh}
|
|
@@ -4870,6 +4871,9 @@ var TVLManager = function () {
|
|
|
4870
4871
|
TVLManager_1.prototype.setVolume = function (volume) {
|
|
4871
4872
|
throw new Error('not implement');
|
|
4872
4873
|
};
|
|
4874
|
+
TVLManager_1.prototype.setEnableIgnoreAudioInterruption = function (enable) {
|
|
4875
|
+
throw new Error('not implement');
|
|
4876
|
+
};
|
|
4873
4877
|
return TVLManager_1;
|
|
4874
4878
|
}());
|
|
4875
4879
|
__setFunctionName(_classThis, "TVLManager");
|
|
@@ -4905,6 +4909,7 @@ var TVLManager = function () {
|
|
|
4905
4909
|
_enableAudioFrameObserver_decorators = [NativeMethodSync('enableAudioFrameObserver:enableRendering:')];
|
|
4906
4910
|
_setEnableSuperResolution_decorators = [NativeMethodSync('setEnableSuperResolution:')];
|
|
4907
4911
|
_setVolume_decorators = [NativeMethodSync('setVolume:')];
|
|
4912
|
+
_setEnableIgnoreAudioInterruption_decorators = [NativeMethodSync('setEnableIgnoreAudioInterruption:')];
|
|
4908
4913
|
__esDecorate(_classThis, null, _static_setLogLevel_decorators, { kind: "method", name: "setLogLevel", static: true, private: false, access: { has: function (obj) { return "setLogLevel" in obj; }, get: function (obj) { return obj.setLogLevel; } }, metadata: _metadata }, null, _staticExtraInitializers);
|
|
4909
4914
|
__esDecorate(_classThis, null, _static_getVersion_decorators, { kind: "method", name: "getVersion", static: true, private: false, access: { has: function (obj) { return "getVersion" in obj; }, get: function (obj) { return obj.getVersion; } }, metadata: _metadata }, null, _staticExtraInitializers);
|
|
4910
4915
|
__esDecorate(_classThis, null, _static_setHttpDNSHostIP_decorators, { kind: "method", name: "setHttpDNSHostIP", static: true, private: false, access: { has: function (obj) { return "setHttpDNSHostIP" in obj; }, get: function (obj) { return obj.setHttpDNSHostIP; } }, metadata: _metadata }, null, _staticExtraInitializers);
|
|
@@ -4931,6 +4936,7 @@ var TVLManager = function () {
|
|
|
4931
4936
|
__esDecorate(_classThis, null, _enableAudioFrameObserver_decorators, { kind: "method", name: "enableAudioFrameObserver", static: false, private: false, access: { has: function (obj) { return "enableAudioFrameObserver" in obj; }, get: function (obj) { return obj.enableAudioFrameObserver; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4932
4937
|
__esDecorate(_classThis, null, _setEnableSuperResolution_decorators, { kind: "method", name: "setEnableSuperResolution", static: false, private: false, access: { has: function (obj) { return "setEnableSuperResolution" in obj; }, get: function (obj) { return obj.setEnableSuperResolution; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4933
4938
|
__esDecorate(_classThis, null, _setVolume_decorators, { kind: "method", name: "setVolume", static: false, private: false, access: { has: function (obj) { return "setVolume" in obj; }, get: function (obj) { return obj.setVolume; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4939
|
+
__esDecorate(_classThis, null, _setEnableIgnoreAudioInterruption_decorators, { kind: "method", name: "setEnableIgnoreAudioInterruption", static: false, private: false, access: { has: function (obj) { return "setEnableIgnoreAudioInterruption" in obj; }, get: function (obj) { return obj.setEnableIgnoreAudioInterruption; } }, metadata: _metadata }, null, _instanceExtraInitializers);
|
|
4934
4940
|
__esDecorate(null, null, _observer_decorators, { kind: "field", name: "observer", static: false, private: false, access: { has: function (obj) { return "observer" in obj; }, get: function (obj) { return obj.observer; }, set: function (obj, value) { obj.observer = value; } }, metadata: _metadata }, _observer_initializers, _observer_extraInitializers);
|
|
4935
4941
|
__esDecorate(null, null, _playerView_decorators, { kind: "field", name: "playerView", static: false, private: false, access: { has: function (obj) { return "playerView" in obj; }, get: function (obj) { return obj.playerView; }, set: function (obj, value) { obj.playerView = value; } }, metadata: _metadata }, _playerView_initializers, _playerView_extraInitializers);
|
|
4936
4942
|
__esDecorate(null, null, _volume_decorators, { kind: "field", name: "volume", static: false, private: false, access: { has: function (obj) { return "volume" in obj; }, get: function (obj) { return obj.volume; }, set: function (obj, value) { obj.volume = value; } }, metadata: _metadata }, _volume_initializers, _volume_extraInitializers);
|
|
@@ -6721,38 +6727,6 @@ var VeLivePlayerStatistics = function () {
|
|
|
6721
6727
|
enumerable: false,
|
|
6722
6728
|
configurable: true
|
|
6723
6729
|
});
|
|
6724
|
-
Object.defineProperty(VeLivePlayerStatistics_1.prototype, "format", {
|
|
6725
|
-
/** {zh}
|
|
6726
|
-
* @brief 当前播放的视频格式。
|
|
6727
|
-
*
|
|
6728
|
-
*/
|
|
6729
|
-
/** {en}
|
|
6730
|
-
* @brief The video format.
|
|
6731
|
-
*
|
|
6732
|
-
*/
|
|
6733
|
-
get: function () {
|
|
6734
|
-
// TODO: implement
|
|
6735
|
-
throw new Error("not implement 'format'");
|
|
6736
|
-
},
|
|
6737
|
-
enumerable: false,
|
|
6738
|
-
configurable: true
|
|
6739
|
-
});
|
|
6740
|
-
Object.defineProperty(VeLivePlayerStatistics_1.prototype, "protocol", {
|
|
6741
|
-
/** {zh}
|
|
6742
|
-
* @brief 当前播放的传输协议。
|
|
6743
|
-
*
|
|
6744
|
-
*/
|
|
6745
|
-
/** {en}
|
|
6746
|
-
* @brief The transmission protocol of the live stream.
|
|
6747
|
-
*
|
|
6748
|
-
*/
|
|
6749
|
-
get: function () {
|
|
6750
|
-
// TODO: implement
|
|
6751
|
-
throw new Error("not implement 'protocol'");
|
|
6752
|
-
},
|
|
6753
|
-
enumerable: false,
|
|
6754
|
-
configurable: true
|
|
6755
|
-
});
|
|
6756
6730
|
Object.defineProperty(VeLivePlayerStatistics_1.prototype, "url", {
|
|
6757
6731
|
/** {zh}
|
|
6758
6732
|
* @brief 当前直播的播放地址。
|
|
@@ -11382,6 +11356,13 @@ extendsClassMethod(VeLivePlayer, 'destroy', function (origin) {
|
|
|
11382
11356
|
}); });
|
|
11383
11357
|
};
|
|
11384
11358
|
});
|
|
11359
|
+
extendsClassMethod(VeLivePlayer, 'setEnableIgnoreAudioInterruption', function () {
|
|
11360
|
+
return function setEnableIgnoreAudioInterruption(enable) {
|
|
11361
|
+
return runImpl(this, function () { }, function (engine) {
|
|
11362
|
+
engine.setEnableIgnoreAudioInterruption(enable);
|
|
11363
|
+
});
|
|
11364
|
+
};
|
|
11365
|
+
});
|
|
11385
11366
|
|
|
11386
11367
|
extendsClassMethod(android_VeLivePlayerObserver, 'onVideoSizeChanged', function (original) {
|
|
11387
11368
|
return function onVideoSizeChanged(player, width, height) {
|
|
@@ -11639,23 +11620,24 @@ function initAndroidPlayer(options) {
|
|
|
11639
11620
|
}
|
|
11640
11621
|
function initIOSPlayer(options) {
|
|
11641
11622
|
return __awaiter(this, void 0, void 0, function () {
|
|
11642
|
-
var viewId, option, player, config, uiView, multiObserver, manager;
|
|
11623
|
+
var viewId, option, iosPlayer, player, config, uiView, multiObserver, manager;
|
|
11643
11624
|
return __generator(this, function (_a) {
|
|
11644
11625
|
switch (_a.label) {
|
|
11645
11626
|
case 0:
|
|
11646
11627
|
viewId = options.viewId, option = __rest(options, ["viewId"]);
|
|
11647
|
-
|
|
11628
|
+
iosPlayer = new TVLManager();
|
|
11629
|
+
player = packObject(iosPlayer, VeLivePlayer);
|
|
11648
11630
|
config = new VeLivePlayerConfiguration();
|
|
11649
11631
|
Object.assign(config, defaultConfig, option);
|
|
11650
11632
|
player.setConfig(config);
|
|
11651
11633
|
uiView = NativeView.getView(viewId, NativeUIView);
|
|
11652
|
-
return [4 /*yield*/, uiView.insertSubview(
|
|
11634
|
+
return [4 /*yield*/, uiView.insertSubview(iosPlayer.playerView, 0)];
|
|
11653
11635
|
case 1:
|
|
11654
11636
|
_a.sent();
|
|
11655
11637
|
multiObserver = VeLivePlayerMultiObserver.getInstance();
|
|
11656
|
-
multiObserver.setupPlayer(
|
|
11638
|
+
multiObserver.setupPlayer(iosPlayer);
|
|
11657
11639
|
manager = VeLivePictureInPictureManager.getInstance();
|
|
11658
|
-
manager.setupPlayer(
|
|
11640
|
+
manager.setupPlayer(iosPlayer);
|
|
11659
11641
|
return [2 /*return*/, player];
|
|
11660
11642
|
}
|
|
11661
11643
|
});
|
|
@@ -111,18 +111,6 @@ export declare class VeLivePlayerStatistics {
|
|
|
111
111
|
*/
|
|
112
112
|
get isHardwareDecode(): boolean;
|
|
113
113
|
|
|
114
|
-
/** {en}
|
|
115
|
-
* @brief The video format.
|
|
116
|
-
*
|
|
117
|
-
*/
|
|
118
|
-
get format(): void;
|
|
119
|
-
|
|
120
|
-
/** {en}
|
|
121
|
-
* @brief The transmission protocol of the live stream.
|
|
122
|
-
*
|
|
123
|
-
*/
|
|
124
|
-
get protocol(): void;
|
|
125
|
-
|
|
126
114
|
/** {en}
|
|
127
115
|
* @brief The current pull stream address.
|
|
128
116
|
*
|
|
@@ -83,6 +83,19 @@ declare module '../codegen/pack/api' {
|
|
|
83
83
|
* @order 6
|
|
84
84
|
*/
|
|
85
85
|
disablePictureInPicture(): Promise<void>;
|
|
86
|
+
/**
|
|
87
|
+
* {zh}
|
|
88
|
+
* @brief 设置是否忽略音频中断
|
|
89
|
+
* @param enable 是否忽略音频中断
|
|
90
|
+
* @order 7
|
|
91
|
+
*/
|
|
92
|
+
/**
|
|
93
|
+
* {en}
|
|
94
|
+
* @brief Set whether to ignore audio interruption
|
|
95
|
+
* @param enable Whether to ignore audio interruption
|
|
96
|
+
* @order 7
|
|
97
|
+
*/
|
|
98
|
+
setEnableIgnoreAudioInterruption(enable: boolean): void;
|
|
86
99
|
}
|
|
87
100
|
}
|
|
88
101
|
export { VeLivePlayer };
|
|
@@ -1 +1,17 @@
|
|
|
1
|
+
declare module '../codegen/pack/keytype' {
|
|
2
|
+
interface VeLivePlayerStatistics {
|
|
3
|
+
|
|
4
|
+
/** {en}
|
|
5
|
+
* @brief The video format.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
format: VeLivePlayerFormat;
|
|
9
|
+
|
|
10
|
+
/** {en}
|
|
11
|
+
* @brief The transmission protocol of the live stream.
|
|
12
|
+
*
|
|
13
|
+
*/
|
|
14
|
+
protocol: VeLivePlayerProtocol;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
1
17
|
export { VeLivePlayerAudioBufferType, VeLivePlayerAudioFrame, VeLivePlayerConfiguration, VeLivePlayerFillMode, VeLivePlayerFormat, VeLivePlayerLogLevel, VeLivePlayerMirror, VeLivePlayerPixelFormat, VeLivePlayerProtocol, VeLivePlayerResolution, VeLivePlayerResolutionSwitchReason, VeLivePlayerRotation, VeLivePlayerStatistics, VeLivePlayerStatus, VeLivePlayerStream, VeLivePlayerStreamData, VeLivePlayerStreamType, VeLivePlayerVideoBufferType, VeLivePlayerVideoFrame, } from '../codegen/pack/keytype';
|