@livedigital/client 2.38.0-debug-noise.1 → 2.38.0
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/{src/EnhancedEventEmitter.d.ts → EnhancedEventEmitter.d.ts} +0 -0
- package/dist/{src/constants → constants}/common.d.ts +0 -0
- package/dist/{src/constants/simulcastEncodings.d.ts → constants/encodings.d.ts} +4 -0
- package/dist/{src/constants → constants}/events.d.ts +0 -0
- package/dist/{src/constants → constants}/videoConstrains.d.ts +0 -0
- package/dist/{src/engine → engine}/DefaultEngineDependenciesFactory.d.ts +0 -0
- package/dist/{src/engine → engine}/Logger.d.ts +0 -0
- package/dist/{src/engine → engine}/Peer.d.ts +0 -0
- package/dist/{src/engine → engine}/PeerConsumer.d.ts +0 -0
- package/dist/{src/engine → engine}/PeerProducer.d.ts +0 -0
- package/dist/{src/engine → engine}/handlers/ChannelEventHandler.d.ts +0 -0
- package/dist/{src/engine → engine}/handlers/MediaSoupEventHandler.d.ts +0 -0
- package/dist/{src/engine → engine}/index.d.ts +0 -0
- package/dist/{src/engine → engine}/media/index.d.ts +0 -0
- package/dist/{src/engine → engine}/media/tracks/AudioTrack.d.ts +2 -0
- package/dist/{src/engine → engine}/media/tracks/BaseTrack.d.ts +0 -0
- package/dist/{src/engine → engine}/media/tracks/MediaStreamTrackManager.d.ts +0 -0
- package/dist/{src/engine → engine}/media/tracks/PeerTrack.d.ts +0 -0
- package/dist/{src/engine → engine}/media/tracks/TrackWithCodecOptions.d.ts +0 -0
- package/dist/{src/engine → engine}/media/tracks/TrackWithEncodings.d.ts +0 -0
- package/dist/{src/engine → engine}/media/tracks/VideoTrack.d.ts +0 -0
- package/dist/{src/engine → engine}/network/LoadBalancerClient.d.ts +0 -0
- package/dist/{src/engine → engine}/network/Socket.d.ts +0 -0
- package/dist/{src/engine → engine}/network/index.d.ts +0 -0
- package/dist/{src/engine → engine}/system/index.d.ts +1 -1
- package/dist/{src/errors → errors}/LivedigitalSDKError.d.ts +0 -0
- package/dist/{src/errors → errors}/UnsupportedError.d.ts +0 -0
- package/dist/{src/helpers → helpers}/appDataValidator.d.ts +0 -0
- package/dist/{src/helpers → helpers}/datetime.d.ts +0 -0
- package/dist/{src/helpers → helpers}/filterStatsCodecs.d.ts +0 -0
- package/dist/{src/helpers → helpers}/retry.d.ts +0 -0
- package/dist/{src/index.d.ts → index.d.ts} +0 -0
- package/dist/index.es.js +1 -1
- package/dist/index.js +1 -1
- package/dist/{src/types → types}/common.d.ts +4 -1
- package/dist/{src/types → types}/engine.d.ts +0 -0
- package/dist/{src/types → types}/network.d.ts +0 -0
- package/package.json +3 -3
- package/src/constants/{simulcastEncodings.ts → encodings.ts} +2 -0
- package/src/engine/media/index.ts +1 -1
- package/src/engine/media/tracks/AudioTrack.ts +9 -1
- package/src/engine/media/tracks/BaseTrack.ts +3 -3
- package/src/engine/media/tracks/PeerTrack.ts +3 -3
- package/src/engine/media/tracks/VideoTrack.ts +1 -1
- package/src/engine/system/index.ts +11 -5
- package/src/types/common.ts +3 -0
- package/dist/node_modules/mediasoup-client/src/Consumer.d.ts +0 -114
- package/dist/node_modules/mediasoup-client/src/DataConsumer.d.ts +0 -93
- package/dist/node_modules/mediasoup-client/src/DataProducer.d.ts +0 -97
- package/dist/node_modules/mediasoup-client/src/EnhancedEventEmitter.d.ts +0 -7
- package/dist/node_modules/mediasoup-client/src/Logger.d.ts +0 -10
- package/dist/node_modules/mediasoup-client/src/Producer.d.ts +0 -151
- package/dist/node_modules/mediasoup-client/src/RtpParameters.d.ts +0 -305
- package/dist/node_modules/mediasoup-client/src/SctpParameters.d.ts +0 -67
- package/dist/node_modules/mediasoup-client/src/Transport.d.ts +0 -212
- package/dist/node_modules/mediasoup-client/src/errors.d.ts +0 -12
- package/dist/node_modules/mediasoup-client/src/handlers/HandlerInterface.d.ts +0 -84
- package/dist/node_modules/mediasoup-client/src/ortc.d.ts +0 -122
- package/dist/node_modules/mediasoup-client/src/utils.d.ts +0 -8
|
@@ -1,212 +0,0 @@
|
|
|
1
|
-
import { EnhancedEventEmitter } from './EnhancedEventEmitter';
|
|
2
|
-
import { HandlerFactory, HandlerInterface } from './handlers/HandlerInterface';
|
|
3
|
-
import { Producer, ProducerOptions } from './Producer';
|
|
4
|
-
import { Consumer, ConsumerOptions } from './Consumer';
|
|
5
|
-
import { DataProducer, DataProducerOptions } from './DataProducer';
|
|
6
|
-
import { DataConsumer, DataConsumerOptions } from './DataConsumer';
|
|
7
|
-
import { SctpParameters } from './SctpParameters';
|
|
8
|
-
interface InternalTransportOptions extends TransportOptions {
|
|
9
|
-
direction: 'send' | 'recv';
|
|
10
|
-
handlerFactory: HandlerFactory;
|
|
11
|
-
extendedRtpCapabilities: any;
|
|
12
|
-
canProduceByKind: CanProduceByKind;
|
|
13
|
-
}
|
|
14
|
-
export declare type TransportOptions = {
|
|
15
|
-
id: string;
|
|
16
|
-
iceParameters: IceParameters;
|
|
17
|
-
iceCandidates: IceCandidate[];
|
|
18
|
-
dtlsParameters: DtlsParameters;
|
|
19
|
-
sctpParameters?: SctpParameters;
|
|
20
|
-
iceServers?: RTCIceServer[];
|
|
21
|
-
iceTransportPolicy?: RTCIceTransportPolicy;
|
|
22
|
-
additionalSettings?: any;
|
|
23
|
-
proprietaryConstraints?: any;
|
|
24
|
-
appData?: any;
|
|
25
|
-
};
|
|
26
|
-
export declare type CanProduceByKind = {
|
|
27
|
-
audio: boolean;
|
|
28
|
-
video: boolean;
|
|
29
|
-
[key: string]: boolean;
|
|
30
|
-
};
|
|
31
|
-
export declare type IceParameters = {
|
|
32
|
-
/**
|
|
33
|
-
* ICE username fragment.
|
|
34
|
-
* */
|
|
35
|
-
usernameFragment: string;
|
|
36
|
-
/**
|
|
37
|
-
* ICE password.
|
|
38
|
-
*/
|
|
39
|
-
password: string;
|
|
40
|
-
/**
|
|
41
|
-
* ICE Lite.
|
|
42
|
-
*/
|
|
43
|
-
iceLite?: boolean;
|
|
44
|
-
};
|
|
45
|
-
export declare type IceCandidate = {
|
|
46
|
-
/**
|
|
47
|
-
* Unique identifier that allows ICE to correlate candidates that appear on
|
|
48
|
-
* multiple transports.
|
|
49
|
-
*/
|
|
50
|
-
foundation: string;
|
|
51
|
-
/**
|
|
52
|
-
* The assigned priority of the candidate.
|
|
53
|
-
*/
|
|
54
|
-
priority: number;
|
|
55
|
-
/**
|
|
56
|
-
* The IP address of the candidate.
|
|
57
|
-
*/
|
|
58
|
-
ip: string;
|
|
59
|
-
/**
|
|
60
|
-
* The protocol of the candidate.
|
|
61
|
-
*/
|
|
62
|
-
protocol: 'udp' | 'tcp';
|
|
63
|
-
/**
|
|
64
|
-
* The port for the candidate.
|
|
65
|
-
*/
|
|
66
|
-
port: number;
|
|
67
|
-
/**
|
|
68
|
-
* The type of candidate.
|
|
69
|
-
*/
|
|
70
|
-
type: 'host' | 'srflx' | 'prflx' | 'relay';
|
|
71
|
-
/**
|
|
72
|
-
* The type of TCP candidate.
|
|
73
|
-
*/
|
|
74
|
-
tcpType: 'active' | 'passive' | 'so';
|
|
75
|
-
};
|
|
76
|
-
export declare type DtlsParameters = {
|
|
77
|
-
/**
|
|
78
|
-
* Server DTLS role. Default 'auto'.
|
|
79
|
-
*/
|
|
80
|
-
role?: DtlsRole;
|
|
81
|
-
/**
|
|
82
|
-
* Server DTLS fingerprints.
|
|
83
|
-
*/
|
|
84
|
-
fingerprints: DtlsFingerprint[];
|
|
85
|
-
};
|
|
86
|
-
/**
|
|
87
|
-
* The hash function algorithm (as defined in the "Hash function Textual Names"
|
|
88
|
-
* registry initially specified in RFC 4572 Section 8) and its corresponding
|
|
89
|
-
* certificate fingerprint value (in lowercase hex string as expressed utilizing
|
|
90
|
-
* the syntax of "fingerprint" in RFC 4572 Section 5).
|
|
91
|
-
*/
|
|
92
|
-
export declare type DtlsFingerprint = {
|
|
93
|
-
algorithm: string;
|
|
94
|
-
value: string;
|
|
95
|
-
};
|
|
96
|
-
export declare type DtlsRole = 'auto' | 'client' | 'server';
|
|
97
|
-
export declare type ConnectionState = 'new' | 'connecting' | 'connected' | 'failed' | 'disconnected' | 'closed';
|
|
98
|
-
export declare type PlainRtpParameters = {
|
|
99
|
-
ip: string;
|
|
100
|
-
ipVersion: 4 | 6;
|
|
101
|
-
port: number;
|
|
102
|
-
};
|
|
103
|
-
export declare class Transport extends EnhancedEventEmitter {
|
|
104
|
-
private readonly _id;
|
|
105
|
-
private _closed;
|
|
106
|
-
private readonly _direction;
|
|
107
|
-
private readonly _extendedRtpCapabilities;
|
|
108
|
-
private readonly _canProduceByKind;
|
|
109
|
-
private readonly _maxSctpMessageSize?;
|
|
110
|
-
private readonly _handler;
|
|
111
|
-
private _connectionState;
|
|
112
|
-
private readonly _appData;
|
|
113
|
-
private readonly _producers;
|
|
114
|
-
private readonly _consumers;
|
|
115
|
-
private readonly _dataProducers;
|
|
116
|
-
private readonly _dataConsumers;
|
|
117
|
-
private _probatorConsumerCreated;
|
|
118
|
-
private readonly _awaitQueue;
|
|
119
|
-
private _pendingConsumerTasks;
|
|
120
|
-
private _consumerCreationInProgress;
|
|
121
|
-
protected readonly _observer: EnhancedEventEmitter;
|
|
122
|
-
/**
|
|
123
|
-
* @emits connect - (transportLocalParameters: any, callback: Function, errback: Function)
|
|
124
|
-
* @emits connectionstatechange - (connectionState: ConnectionState)
|
|
125
|
-
* @emits produce - (producerLocalParameters: any, callback: Function, errback: Function)
|
|
126
|
-
* @emits producedata - (dataProducerLocalParameters: any, callback: Function, errback: Function)
|
|
127
|
-
*/
|
|
128
|
-
constructor({ direction, id, iceParameters, iceCandidates, dtlsParameters, sctpParameters, iceServers, iceTransportPolicy, additionalSettings, proprietaryConstraints, appData, handlerFactory, extendedRtpCapabilities, canProduceByKind }: InternalTransportOptions);
|
|
129
|
-
/**
|
|
130
|
-
* Transport id.
|
|
131
|
-
*/
|
|
132
|
-
get id(): string;
|
|
133
|
-
/**
|
|
134
|
-
* Whether the Transport is closed.
|
|
135
|
-
*/
|
|
136
|
-
get closed(): boolean;
|
|
137
|
-
/**
|
|
138
|
-
* Transport direction.
|
|
139
|
-
*/
|
|
140
|
-
get direction(): 'send' | 'recv';
|
|
141
|
-
/**
|
|
142
|
-
* RTC handler instance.
|
|
143
|
-
*/
|
|
144
|
-
get handler(): HandlerInterface;
|
|
145
|
-
/**
|
|
146
|
-
* Connection state.
|
|
147
|
-
*/
|
|
148
|
-
get connectionState(): ConnectionState;
|
|
149
|
-
/**
|
|
150
|
-
* App custom data.
|
|
151
|
-
*/
|
|
152
|
-
get appData(): any;
|
|
153
|
-
/**
|
|
154
|
-
* Invalid setter.
|
|
155
|
-
*/
|
|
156
|
-
set appData(appData: any);
|
|
157
|
-
/**
|
|
158
|
-
* Observer.
|
|
159
|
-
*
|
|
160
|
-
* @emits close
|
|
161
|
-
* @emits newproducer - (producer: Producer)
|
|
162
|
-
* @emits newconsumer - (producer: Producer)
|
|
163
|
-
* @emits newdataproducer - (dataProducer: DataProducer)
|
|
164
|
-
* @emits newdataconsumer - (dataProducer: DataProducer)
|
|
165
|
-
*/
|
|
166
|
-
get observer(): EnhancedEventEmitter;
|
|
167
|
-
/**
|
|
168
|
-
* Close the Transport.
|
|
169
|
-
*/
|
|
170
|
-
close(): void;
|
|
171
|
-
/**
|
|
172
|
-
* Get associated Transport (RTCPeerConnection) stats.
|
|
173
|
-
*
|
|
174
|
-
* @returns {RTCStatsReport}
|
|
175
|
-
*/
|
|
176
|
-
getStats(): Promise<RTCStatsReport>;
|
|
177
|
-
/**
|
|
178
|
-
* Restart ICE connection.
|
|
179
|
-
*/
|
|
180
|
-
restartIce({ iceParameters }: {
|
|
181
|
-
iceParameters: IceParameters;
|
|
182
|
-
}): Promise<void>;
|
|
183
|
-
/**
|
|
184
|
-
* Update ICE servers.
|
|
185
|
-
*/
|
|
186
|
-
updateIceServers({ iceServers }?: {
|
|
187
|
-
iceServers?: RTCIceServer[];
|
|
188
|
-
}): Promise<void>;
|
|
189
|
-
/**
|
|
190
|
-
* Create a Producer.
|
|
191
|
-
*/
|
|
192
|
-
produce({ track, encodings, codecOptions, codec, stopTracks, disableTrackOnPause, zeroRtpOnPause, appData }?: ProducerOptions): Promise<Producer>;
|
|
193
|
-
/**
|
|
194
|
-
* Create a Consumer to consume a remote Producer.
|
|
195
|
-
*/
|
|
196
|
-
consume({ id, producerId, kind, rtpParameters, appData }: ConsumerOptions): Promise<Consumer>;
|
|
197
|
-
/**
|
|
198
|
-
* Create a DataProducer
|
|
199
|
-
*/
|
|
200
|
-
produceData({ ordered, maxPacketLifeTime, maxRetransmits, label, protocol, appData }?: DataProducerOptions): Promise<DataProducer>;
|
|
201
|
-
/**
|
|
202
|
-
* Create a DataConsumer
|
|
203
|
-
*/
|
|
204
|
-
consumeData({ id, dataProducerId, sctpStreamParameters, label, protocol, appData }: DataConsumerOptions): Promise<DataConsumer>;
|
|
205
|
-
_createPendingConsumers(): Promise<void>;
|
|
206
|
-
_handleHandler(): void;
|
|
207
|
-
_handleProducer(producer: Producer): void;
|
|
208
|
-
_handleConsumer(consumer: Consumer): void;
|
|
209
|
-
_handleDataProducer(dataProducer: DataProducer): void;
|
|
210
|
-
_handleDataConsumer(dataConsumer: DataConsumer): void;
|
|
211
|
-
}
|
|
212
|
-
export {};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Error indicating not support for something.
|
|
3
|
-
*/
|
|
4
|
-
export declare class UnsupportedError extends Error {
|
|
5
|
-
constructor(message: string);
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Error produced when calling a method in an invalid state.
|
|
9
|
-
*/
|
|
10
|
-
export declare class InvalidStateError extends Error {
|
|
11
|
-
constructor(message: string);
|
|
12
|
-
}
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
import { EnhancedEventEmitter } from '../EnhancedEventEmitter';
|
|
2
|
-
import { ProducerCodecOptions } from '../Producer';
|
|
3
|
-
import { IceParameters, IceCandidate, DtlsParameters } from '../Transport';
|
|
4
|
-
import { RtpCapabilities, RtpCodecCapability, RtpParameters, RtpEncodingParameters } from '../RtpParameters';
|
|
5
|
-
import { SctpCapabilities, SctpParameters, SctpStreamParameters } from '../SctpParameters';
|
|
6
|
-
export declare type HandlerFactory = () => HandlerInterface;
|
|
7
|
-
export declare type HandlerRunOptions = {
|
|
8
|
-
direction: 'send' | 'recv';
|
|
9
|
-
iceParameters: IceParameters;
|
|
10
|
-
iceCandidates: IceCandidate[];
|
|
11
|
-
dtlsParameters: DtlsParameters;
|
|
12
|
-
sctpParameters?: SctpParameters;
|
|
13
|
-
iceServers?: RTCIceServer[];
|
|
14
|
-
iceTransportPolicy?: RTCIceTransportPolicy;
|
|
15
|
-
additionalSettings?: any;
|
|
16
|
-
proprietaryConstraints?: any;
|
|
17
|
-
extendedRtpCapabilities: any;
|
|
18
|
-
};
|
|
19
|
-
export declare type HandlerSendOptions = {
|
|
20
|
-
track: MediaStreamTrack;
|
|
21
|
-
encodings?: RtpEncodingParameters[];
|
|
22
|
-
codecOptions?: ProducerCodecOptions;
|
|
23
|
-
codec?: RtpCodecCapability;
|
|
24
|
-
};
|
|
25
|
-
export declare type HandlerSendResult = {
|
|
26
|
-
localId: string;
|
|
27
|
-
rtpParameters: RtpParameters;
|
|
28
|
-
rtpSender?: RTCRtpSender;
|
|
29
|
-
};
|
|
30
|
-
export declare type HandlerReceiveOptions = {
|
|
31
|
-
trackId: string;
|
|
32
|
-
kind: 'audio' | 'video';
|
|
33
|
-
rtpParameters: RtpParameters;
|
|
34
|
-
};
|
|
35
|
-
export declare type HandlerReceiveResult = {
|
|
36
|
-
localId: string;
|
|
37
|
-
track: MediaStreamTrack;
|
|
38
|
-
rtpReceiver?: RTCRtpReceiver;
|
|
39
|
-
};
|
|
40
|
-
export declare type HandlerSendDataChannelOptions = SctpStreamParameters;
|
|
41
|
-
export declare type HandlerSendDataChannelResult = {
|
|
42
|
-
dataChannel: RTCDataChannel;
|
|
43
|
-
sctpStreamParameters: SctpStreamParameters;
|
|
44
|
-
};
|
|
45
|
-
export declare type HandlerReceiveDataChannelOptions = {
|
|
46
|
-
sctpStreamParameters: SctpStreamParameters;
|
|
47
|
-
label?: string;
|
|
48
|
-
protocol?: string;
|
|
49
|
-
};
|
|
50
|
-
export declare type HandlerReceiveDataChannelResult = {
|
|
51
|
-
dataChannel: RTCDataChannel;
|
|
52
|
-
};
|
|
53
|
-
export declare abstract class HandlerInterface extends EnhancedEventEmitter {
|
|
54
|
-
/**
|
|
55
|
-
* @emits @connect - (
|
|
56
|
-
* { dtlsParameters: DtlsParameters },
|
|
57
|
-
* callback: Function,
|
|
58
|
-
* errback: Function
|
|
59
|
-
* )
|
|
60
|
-
* @emits @connectionstatechange - (connectionState: ConnectionState)
|
|
61
|
-
*/
|
|
62
|
-
constructor();
|
|
63
|
-
abstract get name(): string;
|
|
64
|
-
abstract close(): void;
|
|
65
|
-
abstract getNativeRtpCapabilities(): Promise<RtpCapabilities>;
|
|
66
|
-
abstract getNativeSctpCapabilities(): Promise<SctpCapabilities>;
|
|
67
|
-
abstract run(options: HandlerRunOptions): void;
|
|
68
|
-
abstract updateIceServers(iceServers: RTCIceServer[]): Promise<void>;
|
|
69
|
-
abstract restartIce(iceParameters: IceParameters): Promise<void>;
|
|
70
|
-
abstract getTransportStats(): Promise<RTCStatsReport>;
|
|
71
|
-
abstract send(options: HandlerSendOptions): Promise<HandlerSendResult>;
|
|
72
|
-
abstract stopSending(localId: string): Promise<void>;
|
|
73
|
-
abstract replaceTrack(localId: string, track: MediaStreamTrack | null): Promise<void>;
|
|
74
|
-
abstract setMaxSpatialLayer(localId: string, spatialLayer: number): Promise<void>;
|
|
75
|
-
abstract setRtpEncodingParameters(localId: string, params: any): Promise<void>;
|
|
76
|
-
abstract getSenderStats(localId: string): Promise<RTCStatsReport>;
|
|
77
|
-
abstract sendDataChannel(options: HandlerSendDataChannelOptions): Promise<HandlerSendDataChannelResult>;
|
|
78
|
-
abstract receive(optionsList: HandlerReceiveOptions[]): Promise<HandlerReceiveResult[]>;
|
|
79
|
-
abstract stopReceiving(localId: string): Promise<void>;
|
|
80
|
-
abstract pauseReceiving(localId: string): Promise<void>;
|
|
81
|
-
abstract resumeReceiving(localId: string): Promise<void>;
|
|
82
|
-
abstract getReceiverStats(localId: string): Promise<RTCStatsReport>;
|
|
83
|
-
abstract receiveDataChannel(options: HandlerReceiveDataChannelOptions): Promise<HandlerReceiveDataChannelResult>;
|
|
84
|
-
}
|
|
@@ -1,122 +0,0 @@
|
|
|
1
|
-
import { RtpCapabilities, MediaKind, RtpCodecCapability, RtpHeaderExtension, RtpParameters, RtpCodecParameters, RtcpFeedback, RtpEncodingParameters, RtpHeaderExtensionParameters, RtcpParameters } from './RtpParameters';
|
|
2
|
-
import { SctpCapabilities, NumSctpStreams, SctpParameters, SctpStreamParameters } from './SctpParameters';
|
|
3
|
-
/**
|
|
4
|
-
* Validates RtpCapabilities. It may modify given data by adding missing
|
|
5
|
-
* fields with default values.
|
|
6
|
-
* It throws if invalid.
|
|
7
|
-
*/
|
|
8
|
-
export declare function validateRtpCapabilities(caps: RtpCapabilities): void;
|
|
9
|
-
/**
|
|
10
|
-
* Validates RtpCodecCapability. It may modify given data by adding missing
|
|
11
|
-
* fields with default values.
|
|
12
|
-
* It throws if invalid.
|
|
13
|
-
*/
|
|
14
|
-
export declare function validateRtpCodecCapability(codec: RtpCodecCapability): void;
|
|
15
|
-
/**
|
|
16
|
-
* Validates RtcpFeedback. It may modify given data by adding missing
|
|
17
|
-
* fields with default values.
|
|
18
|
-
* It throws if invalid.
|
|
19
|
-
*/
|
|
20
|
-
export declare function validateRtcpFeedback(fb: RtcpFeedback): void;
|
|
21
|
-
/**
|
|
22
|
-
* Validates RtpHeaderExtension. It may modify given data by adding missing
|
|
23
|
-
* fields with default values.
|
|
24
|
-
* It throws if invalid.
|
|
25
|
-
*/
|
|
26
|
-
export declare function validateRtpHeaderExtension(ext: RtpHeaderExtension): void;
|
|
27
|
-
/**
|
|
28
|
-
* Validates RtpParameters. It may modify given data by adding missing
|
|
29
|
-
* fields with default values.
|
|
30
|
-
* It throws if invalid.
|
|
31
|
-
*/
|
|
32
|
-
export declare function validateRtpParameters(params: RtpParameters): void;
|
|
33
|
-
/**
|
|
34
|
-
* Validates RtpCodecParameters. It may modify given data by adding missing
|
|
35
|
-
* fields with default values.
|
|
36
|
-
* It throws if invalid.
|
|
37
|
-
*/
|
|
38
|
-
export declare function validateRtpCodecParameters(codec: RtpCodecParameters): void;
|
|
39
|
-
/**
|
|
40
|
-
* Validates RtpHeaderExtensionParameteters. It may modify given data by adding missing
|
|
41
|
-
* fields with default values.
|
|
42
|
-
* It throws if invalid.
|
|
43
|
-
*/
|
|
44
|
-
export declare function validateRtpHeaderExtensionParameters(ext: RtpHeaderExtensionParameters): void;
|
|
45
|
-
/**
|
|
46
|
-
* Validates RtpEncodingParameters. It may modify given data by adding missing
|
|
47
|
-
* fields with default values.
|
|
48
|
-
* It throws if invalid.
|
|
49
|
-
*/
|
|
50
|
-
export declare function validateRtpEncodingParameters(encoding: RtpEncodingParameters): void;
|
|
51
|
-
/**
|
|
52
|
-
* Validates RtcpParameters. It may modify given data by adding missing
|
|
53
|
-
* fields with default values.
|
|
54
|
-
* It throws if invalid.
|
|
55
|
-
*/
|
|
56
|
-
export declare function validateRtcpParameters(rtcp: RtcpParameters): void;
|
|
57
|
-
/**
|
|
58
|
-
* Validates SctpCapabilities. It may modify given data by adding missing
|
|
59
|
-
* fields with default values.
|
|
60
|
-
* It throws if invalid.
|
|
61
|
-
*/
|
|
62
|
-
export declare function validateSctpCapabilities(caps: SctpCapabilities): void;
|
|
63
|
-
/**
|
|
64
|
-
* Validates NumSctpStreams. It may modify given data by adding missing
|
|
65
|
-
* fields with default values.
|
|
66
|
-
* It throws if invalid.
|
|
67
|
-
*/
|
|
68
|
-
export declare function validateNumSctpStreams(numStreams: NumSctpStreams): void;
|
|
69
|
-
/**
|
|
70
|
-
* Validates SctpParameters. It may modify given data by adding missing
|
|
71
|
-
* fields with default values.
|
|
72
|
-
* It throws if invalid.
|
|
73
|
-
*/
|
|
74
|
-
export declare function validateSctpParameters(params: SctpParameters): void;
|
|
75
|
-
/**
|
|
76
|
-
* Validates SctpStreamParameters. It may modify given data by adding missing
|
|
77
|
-
* fields with default values.
|
|
78
|
-
* It throws if invalid.
|
|
79
|
-
*/
|
|
80
|
-
export declare function validateSctpStreamParameters(params: SctpStreamParameters): void;
|
|
81
|
-
/**
|
|
82
|
-
* Generate extended RTP capabilities for sending and receiving.
|
|
83
|
-
*/
|
|
84
|
-
export declare function getExtendedRtpCapabilities(localCaps: RtpCapabilities, remoteCaps: RtpCapabilities): any;
|
|
85
|
-
/**
|
|
86
|
-
* Generate RTP capabilities for receiving media based on the given extended
|
|
87
|
-
* RTP capabilities.
|
|
88
|
-
*/
|
|
89
|
-
export declare function getRecvRtpCapabilities(extendedRtpCapabilities: any): RtpCapabilities;
|
|
90
|
-
/**
|
|
91
|
-
* Generate RTP parameters of the given kind for sending media.
|
|
92
|
-
* NOTE: mid, encodings and rtcp fields are left empty.
|
|
93
|
-
*/
|
|
94
|
-
export declare function getSendingRtpParameters(kind: MediaKind, extendedRtpCapabilities: any): RtpParameters;
|
|
95
|
-
/**
|
|
96
|
-
* Generate RTP parameters of the given kind suitable for the remote SDP answer.
|
|
97
|
-
*/
|
|
98
|
-
export declare function getSendingRemoteRtpParameters(kind: MediaKind, extendedRtpCapabilities: any): RtpParameters;
|
|
99
|
-
/**
|
|
100
|
-
* Reduce given codecs by returning an array of codecs "compatible" with the
|
|
101
|
-
* given capability codec. If no capability codec is given, take the first
|
|
102
|
-
* one(s).
|
|
103
|
-
*
|
|
104
|
-
* Given codecs must be generated by ortc.getSendingRtpParameters() or
|
|
105
|
-
* ortc.getSendingRemoteRtpParameters().
|
|
106
|
-
*
|
|
107
|
-
* The returned array of codecs also include a RTX codec if available.
|
|
108
|
-
*/
|
|
109
|
-
export declare function reduceCodecs(codecs: RtpCodecParameters[], capCodec?: RtpCodecCapability): RtpCodecParameters[];
|
|
110
|
-
/**
|
|
111
|
-
* Create RTP parameters for a Consumer for the RTP probator.
|
|
112
|
-
*/
|
|
113
|
-
export declare function generateProbatorRtpParameters(videoRtpParameters: RtpParameters): RtpParameters;
|
|
114
|
-
/**
|
|
115
|
-
* Whether media can be sent based on the given RTP capabilities.
|
|
116
|
-
*/
|
|
117
|
-
export declare function canSend(kind: MediaKind, extendedRtpCapabilities: any): boolean;
|
|
118
|
-
/**
|
|
119
|
-
* Whether the given RTP parameters can be received with the given RTP
|
|
120
|
-
* capabilities.
|
|
121
|
-
*/
|
|
122
|
-
export declare function canReceive(rtpParameters: RtpParameters, extendedRtpCapabilities: any): boolean;
|