moqtail 0.8.1 → 0.10.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.
@@ -1,6 +1,5 @@
1
- import { m as FullTrackName, K as KeyValuePair, F as FrozenByteBuffer, B as BaseByteBuffer } from '../byte_buffer-BM4uNj4n.js';
2
- export { a as ByteBuffer, D as DatagramObject, h as DatagramStatus, e as FetchHeaderType, j as FetchObject, L as Location, l as MAX_FULL_TRACK_NAME_LENGTH, k as MAX_NAMESPACE_TUPLE_COUNT, M as MAX_REASON_PHRASE_LEN, n as MoqtObject, O as ObjectDatagramStatusType, d as ObjectDatagramType, f as ObjectForwardingPreference, g as ObjectStatus, R as ReasonPhrase, S as SubgroupHeaderType, o as SubgroupObject, c as Tuple, T as TupleField, b as isBytes, i as isVarInt } from '../byte_buffer-BM4uNj4n.js';
3
- export { ah as AuthTokenVariant, ai as AuthorizationToken, C as ClientSetup, a9 as CommonType, w as ControlMessage, d as ControlMessageType, D as DRAFT_14, am as DeliveryTimeout, x as Fetch, y as FetchCancel, z as FetchError, l as FetchErrorCode, a0 as FetchHeader, A as FetchOk, h as FetchType, F as FilterType, B as GoAway, G as GroupOrder, a3 as Header, al as MaxAuthTokenCacheSize, an as MaxCacheDuration, M as MaxRequestId, aj as MaxRequestIdParameter, a8 as Parameter, ak as Path, L as Publish, K as PublishDone, q as PublishDoneStatusCode, N as PublishError, u as PublishErrorCode, P as PublishNamespace, c as PublishNamespaceCancel, Z as PublishNamespaceDone, a as PublishNamespaceError, f as PublishNamespaceErrorCode, b as PublishNamespaceOk, O as PublishOk, a2 as RequestIdMap, R as RequestsBlocked, E as ServerSetup, a4 as SetupParameter, ab as SetupParameterType, a5 as SetupParameters, a1 as SubgroupHeader, S as Subscribe, Q as SubscribeError, k as SubscribeErrorCode, H as SubscribeNamespace, I as SubscribeNamespaceError, n as SubscribeNamespaceErrorCode, J as SubscribeNamespaceOk, U as SubscribeOk, V as SubscribeUpdate, af as TokenAliasType, W as TrackStatus, T as TrackStatusCode, X as TrackStatusError, Y as TrackStatusOk, _ as Unsubscribe, $ as UnsubscribeNamespace, a6 as VersionSpecificParameter, ad as VersionSpecificParameterType, a7 as VersionSpecificParameters, aa as commonTypeFromNumber, e as controlMessageTypeFromBigInt, m as fetchErrorCodeFromBigInt, i as fetchTypeFromBigInt, g as filterTypeFromBigInt, j as groupOrderFromNumber, r as publishDoneStatusCodeFromBigInt, v as publishErrorCodeFromBigInt, p as publishNamespaceErrorCodeFromBigInt, ac as setupParameterTypeFromNumber, s as subscribeErrorCodeFromBigInt, o as subscribeNamespaceErrorCodeFromBigInt, ag as tokenAliasTypeFromNumber, t as trackStatusCodeFromBigInt, ae as versionSpecificParameterTypeFromNumber } from '../version_parameter-f75NkWiO.js';
1
+ import { u as FullTrackName, K as KeyValuePair, t as FrozenByteBuffer, B as BaseByteBuffer, L as LOCHeaderExtensionId, av as TrackExtensionType, b as ByteBuffer } from './setup_parameter-BOeGq6Mv.cjs';
2
+ export { A as AuthTokenVariant, a as AuthorizationToken, C as ClientSetup, c as ControlMessage, d as ControlMessageType, D as Datagram, e as DefaultPublisherGroupOrderExtension, f as DefaultPublisherPriorityExtension, g as DeliveryTimeout, h as DeliveryTimeoutExtension, i as DynamicGroupsExtension, E as EndOfRangeKind, j as Expires, F as Fetch, k as FetchCancel, l as FetchHeader, m as FetchHeaderType, n as FetchObject, o as FetchObjectContext, p as FetchOk, q as FetchType, r as FilterType, s as Forward, G as GoAway, v as GroupOrder, w as GroupOrderParam, H as Header, I as ImmutableExtensionsExtension, x as LargestObject, y as Location, M as MAX_FULL_TRACK_NAME_LENGTH, z as MAX_NAMESPACE_TUPLE_COUNT, J as MAX_REASON_PHRASE_LEN, N as MaxAuthTokenCacheSize, O as MaxCacheDurationExtension, P as MaxRequestId, Q as MaxRequestIdParameter, R as MessageParameter, S as MessageParameterType, T as MessageParameters, U as MoqtObject, V as Namespace, W as NamespaceDone, X as NamespaceSubscribeOptions, Y as NewGroupRequest, Z as ObjectDatagramType, _ as ObjectForwardingPreference, $ as ObjectStatus, a0 as Parameter, a1 as Path, a2 as Publish, a3 as PublishDone, a4 as PublishDoneStatusCode, a5 as PublishNamespace, a6 as PublishNamespaceCancel, a7 as PublishNamespaceDone, a8 as PublishOk, a9 as ReasonPhrase, aa as RequestError, ab as RequestErrorCode, ac as RequestIdMap, ad as RequestOk, ae as RequestUpdate, af as RequestsBlocked, ag as SUPPORTED_VERSIONS, ah as ServerSetup, ai as SetupParameter, aj as SetupParameterType, ak as SetupParameters, al as SubgroupHeader, am as SubgroupHeaderType, an as SubgroupObject, ao as Subscribe, ap as SubscribeNamespace, aq as SubscribeOk, ar as SubscriberPriority, as as SubscriptionFilter, at as TokenAliasType, au as TrackExtension, aw as TrackStatus, ax as TrackStatusCode, ay as Tuple, az as TupleField, aA as UnknownTrackExtension, aB as Unsubscribe, aC as UnsubscribeNamespace, aD as applyMessageParameterUpdate, aE as controlMessageTypeFromBigInt, aF as fetchTypeFromBigInt, aG as filterTypeFromBigInt, aH as groupOrderFromNumber, aI as isBytes, aJ as isVarInt, aK as locHeaderExtensionIdFromNumber, aL as messageParameterTypeFromNumber, aM as publishDoneStatusCodeFromBigInt, aN as requestErrorCodeFromBigInt, aO as setupParameterTypeFromNumber, aP as tokenAliasTypeFromNumber, aQ as trackStatusCodeFromBigInt } from './setup_parameter-BOeGq6Mv.cjs';
4
3
 
5
4
  /**
6
5
  * Copyright 2025 The MOQtail Authors
@@ -28,6 +27,56 @@ declare class Switch {
28
27
  static parsePayload(buf: BaseByteBuffer): Switch;
29
28
  }
30
29
 
30
+ /**
31
+ * Copyright 2026 The MOQtail Authors
32
+ *
33
+ * Licensed under the Apache License, Version 2.0 (the "License");
34
+ * you may not use this file except in compliance with the License.
35
+ * You may obtain a copy of the License at
36
+ *
37
+ * http://www.apache.org/licenses/LICENSE-2.0
38
+ *
39
+ * Unless required by applicable law or agreed to in writing, software
40
+ * distributed under the License is distributed on an "AS IS" BASIS,
41
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
42
+ * See the License for the specific language governing permissions and
43
+ * limitations under the License.
44
+ */
45
+ interface CMSFTrack {
46
+ name: string;
47
+ packaging: 'cmaf' | 'chunk-per-object' | 'timeline';
48
+ codec?: string;
49
+ role: 'video' | 'audio' | 'timeline';
50
+ depends?: string[];
51
+ mimeType?: string;
52
+ width?: number;
53
+ height?: number;
54
+ timescale?: number;
55
+ bitrate?: number;
56
+ initData?: string;
57
+ }
58
+ interface CMSF {
59
+ version: number;
60
+ tracks: CMSFTrack[];
61
+ }
62
+ declare class CMSFCatalog {
63
+ #private;
64
+ private constructor();
65
+ static from(payload: ArrayBufferLike): CMSFCatalog;
66
+ getByTrackName(trackName: string): CMSFTrack | undefined;
67
+ getTracks(role?: CMSF['tracks'][number]['role']): CMSFTrack[];
68
+ getVideo(index?: number): CMSFTrack | undefined;
69
+ getAudio(index?: number): CMSFTrack | undefined;
70
+ getTimeline(index?: number): CMSFTrack | undefined;
71
+ getCodecString(trackName: string): string | undefined;
72
+ getRole(trackName: string): "timeline" | "video" | "audio" | undefined;
73
+ getPackaging(trackName: string): "cmaf" | "chunk-per-object" | "timeline" | undefined;
74
+ isCMAF(trackName: string): boolean;
75
+ getTimescale(trackName: string): number | undefined;
76
+ getInitData(trackName: string): Uint8Array<ArrayBuffer> | undefined;
77
+ private extractTrackName;
78
+ }
79
+
31
80
  /**
32
81
  * Copyright 2025 The MOQtail Authors
33
82
  *
@@ -204,29 +253,6 @@ declare namespace TerminationCode {
204
253
  function tryFrom(code: number): TerminationCode;
205
254
  }
206
255
 
207
- /**
208
- * Copyright 2025 The MOQtail Authors
209
- *
210
- * Licensed under the Apache License, Version 2.0 (the "License");
211
- * you may not use this file except in compliance with the License.
212
- * You may obtain a copy of the License at
213
- *
214
- * http://www.apache.org/licenses/LICENSE-2.0
215
- *
216
- * Unless required by applicable law or agreed to in writing, software
217
- * distributed under the License is distributed on an "AS IS" BASIS,
218
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
219
- * See the License for the specific language governing permissions and
220
- * limitations under the License.
221
- */
222
- declare enum LOCHeaderExtensionId {
223
- CaptureTimestamp = 2,
224
- VideoFrameMarking = 4,
225
- AudioLevel = 6,
226
- VideoConfig = 13
227
- }
228
- declare function locHeaderExtensionIdFromNumber(value: number): LOCHeaderExtensionId;
229
-
230
256
  /**
231
257
  * Copyright 2025 The MOQtail Authors
232
258
  *
@@ -359,4 +385,58 @@ declare class ExtensionHeaders {
359
385
  static fromKeyValuePairs(kvps: KeyValuePair[]): ExtensionHeader[];
360
386
  }
361
387
 
362
- export { AudioLevel, BaseByteBuffer, CaptureTimestamp, CastingError, ExtensionHeader, ExtensionHeaders, FrozenByteBuffer, FullTrackName, InternalError, InvalidTypeError, InvalidUTF8Error, KeyValueFormattingError, KeyValuePair, LOCHeaderExtensionId, LengthExceedsMaxError, MOQtailError, NotEnoughBytesError, ProtocolViolationError, RequestIdError, Switch, TerminationCode, TerminationError, TimeoutError, TrackNameError, VarIntOverflowError, VideoConfig, VideoFrameMarking, locHeaderExtensionIdFromNumber };
388
+ /**
389
+ * Copyright 2026 The MOQtail Authors
390
+ *
391
+ * Licensed under the Apache License, Version 2.0 (the "License");
392
+ * you may not use this file except in compliance with the License.
393
+ * You may obtain a copy of the License at
394
+ *
395
+ * http://www.apache.org/licenses/LICENSE-2.0
396
+ *
397
+ * Unless required by applicable law or agreed to in writing, software
398
+ * distributed under the License is distributed on an "AS IS" BASIS,
399
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
400
+ * See the License for the specific language governing permissions and
401
+ * limitations under the License.
402
+ */
403
+
404
+ declare class ImmutableExtensionsObjectExtension {
405
+ readonly extensions: KeyValuePair[];
406
+ static readonly TYPE = TrackExtensionType.ImmutableExtensions;
407
+ constructor(extensions: KeyValuePair[]);
408
+ toKeyValuePair(): KeyValuePair;
409
+ static fromKeyValuePair(pair: KeyValuePair): ImmutableExtensionsObjectExtension | undefined;
410
+ }
411
+ declare class PriorGroupIdGapExtension {
412
+ readonly gap: bigint;
413
+ static readonly TYPE = TrackExtensionType.PriorGroupIdGap;
414
+ constructor(gap: bigint);
415
+ toKeyValuePair(): KeyValuePair;
416
+ static fromKeyValuePair(pair: KeyValuePair): PriorGroupIdGapExtension | undefined;
417
+ }
418
+ declare class PriorObjectIdGapExtension {
419
+ readonly gap: bigint;
420
+ static readonly TYPE = TrackExtensionType.PriorObjectIdGap;
421
+ constructor(gap: bigint);
422
+ toKeyValuePair(): KeyValuePair;
423
+ static fromKeyValuePair(pair: KeyValuePair): PriorObjectIdGapExtension | undefined;
424
+ }
425
+ declare class UnknownObjectExtension {
426
+ readonly kvp: KeyValuePair;
427
+ constructor(kvp: KeyValuePair);
428
+ toKeyValuePair(): KeyValuePair;
429
+ }
430
+ type ObjectExtension = ImmutableExtensionsObjectExtension | PriorGroupIdGapExtension | PriorObjectIdGapExtension | UnknownObjectExtension;
431
+ declare namespace ObjectExtension {
432
+ function fromKeyValuePair(pair: KeyValuePair): ObjectExtension;
433
+ function toKeyValuePair(ext: ObjectExtension): KeyValuePair;
434
+ function deserializeAll(buf: BaseByteBuffer): ObjectExtension[];
435
+ function serializeInto(exts: ObjectExtension[], payload: ByteBuffer): void;
436
+ function isImmutableExtensions(ext: ObjectExtension): ext is ImmutableExtensionsObjectExtension;
437
+ function isPriorGroupIdGap(ext: ObjectExtension): ext is PriorGroupIdGapExtension;
438
+ function isPriorObjectIdGap(ext: ObjectExtension): ext is PriorObjectIdGapExtension;
439
+ function isUnknown(ext: ObjectExtension): ext is UnknownObjectExtension;
440
+ }
441
+
442
+ export { AudioLevel, BaseByteBuffer, ByteBuffer, type CMSF, CMSFCatalog, type CMSFTrack, CaptureTimestamp, CastingError, ExtensionHeader, ExtensionHeaders, FrozenByteBuffer, FullTrackName, ImmutableExtensionsObjectExtension, InternalError, InvalidTypeError, InvalidUTF8Error, KeyValueFormattingError, KeyValuePair, LOCHeaderExtensionId, LengthExceedsMaxError, MOQtailError, NotEnoughBytesError, ObjectExtension, PriorGroupIdGapExtension, PriorObjectIdGapExtension, ProtocolViolationError, RequestIdError, Switch, TerminationCode, TerminationError, TimeoutError, TrackExtensionType, TrackNameError, UnknownObjectExtension, VarIntOverflowError, VideoConfig, VideoFrameMarking };
@@ -1,6 +1,5 @@
1
- import { m as FullTrackName, K as KeyValuePair, F as FrozenByteBuffer, B as BaseByteBuffer } from '../byte_buffer-BM4uNj4n.cjs';
2
- export { a as ByteBuffer, D as DatagramObject, h as DatagramStatus, e as FetchHeaderType, j as FetchObject, L as Location, l as MAX_FULL_TRACK_NAME_LENGTH, k as MAX_NAMESPACE_TUPLE_COUNT, M as MAX_REASON_PHRASE_LEN, n as MoqtObject, O as ObjectDatagramStatusType, d as ObjectDatagramType, f as ObjectForwardingPreference, g as ObjectStatus, R as ReasonPhrase, S as SubgroupHeaderType, o as SubgroupObject, c as Tuple, T as TupleField, b as isBytes, i as isVarInt } from '../byte_buffer-BM4uNj4n.cjs';
3
- export { ah as AuthTokenVariant, ai as AuthorizationToken, C as ClientSetup, a9 as CommonType, w as ControlMessage, d as ControlMessageType, D as DRAFT_14, am as DeliveryTimeout, x as Fetch, y as FetchCancel, z as FetchError, l as FetchErrorCode, a0 as FetchHeader, A as FetchOk, h as FetchType, F as FilterType, B as GoAway, G as GroupOrder, a3 as Header, al as MaxAuthTokenCacheSize, an as MaxCacheDuration, M as MaxRequestId, aj as MaxRequestIdParameter, a8 as Parameter, ak as Path, L as Publish, K as PublishDone, q as PublishDoneStatusCode, N as PublishError, u as PublishErrorCode, P as PublishNamespace, c as PublishNamespaceCancel, Z as PublishNamespaceDone, a as PublishNamespaceError, f as PublishNamespaceErrorCode, b as PublishNamespaceOk, O as PublishOk, a2 as RequestIdMap, R as RequestsBlocked, E as ServerSetup, a4 as SetupParameter, ab as SetupParameterType, a5 as SetupParameters, a1 as SubgroupHeader, S as Subscribe, Q as SubscribeError, k as SubscribeErrorCode, H as SubscribeNamespace, I as SubscribeNamespaceError, n as SubscribeNamespaceErrorCode, J as SubscribeNamespaceOk, U as SubscribeOk, V as SubscribeUpdate, af as TokenAliasType, W as TrackStatus, T as TrackStatusCode, X as TrackStatusError, Y as TrackStatusOk, _ as Unsubscribe, $ as UnsubscribeNamespace, a6 as VersionSpecificParameter, ad as VersionSpecificParameterType, a7 as VersionSpecificParameters, aa as commonTypeFromNumber, e as controlMessageTypeFromBigInt, m as fetchErrorCodeFromBigInt, i as fetchTypeFromBigInt, g as filterTypeFromBigInt, j as groupOrderFromNumber, r as publishDoneStatusCodeFromBigInt, v as publishErrorCodeFromBigInt, p as publishNamespaceErrorCodeFromBigInt, ac as setupParameterTypeFromNumber, s as subscribeErrorCodeFromBigInt, o as subscribeNamespaceErrorCodeFromBigInt, ag as tokenAliasTypeFromNumber, t as trackStatusCodeFromBigInt, ae as versionSpecificParameterTypeFromNumber } from '../version_parameter-BpmuiMQj.cjs';
1
+ import { u as FullTrackName, K as KeyValuePair, t as FrozenByteBuffer, B as BaseByteBuffer, L as LOCHeaderExtensionId, av as TrackExtensionType, b as ByteBuffer } from './setup_parameter-BOeGq6Mv.js';
2
+ export { A as AuthTokenVariant, a as AuthorizationToken, C as ClientSetup, c as ControlMessage, d as ControlMessageType, D as Datagram, e as DefaultPublisherGroupOrderExtension, f as DefaultPublisherPriorityExtension, g as DeliveryTimeout, h as DeliveryTimeoutExtension, i as DynamicGroupsExtension, E as EndOfRangeKind, j as Expires, F as Fetch, k as FetchCancel, l as FetchHeader, m as FetchHeaderType, n as FetchObject, o as FetchObjectContext, p as FetchOk, q as FetchType, r as FilterType, s as Forward, G as GoAway, v as GroupOrder, w as GroupOrderParam, H as Header, I as ImmutableExtensionsExtension, x as LargestObject, y as Location, M as MAX_FULL_TRACK_NAME_LENGTH, z as MAX_NAMESPACE_TUPLE_COUNT, J as MAX_REASON_PHRASE_LEN, N as MaxAuthTokenCacheSize, O as MaxCacheDurationExtension, P as MaxRequestId, Q as MaxRequestIdParameter, R as MessageParameter, S as MessageParameterType, T as MessageParameters, U as MoqtObject, V as Namespace, W as NamespaceDone, X as NamespaceSubscribeOptions, Y as NewGroupRequest, Z as ObjectDatagramType, _ as ObjectForwardingPreference, $ as ObjectStatus, a0 as Parameter, a1 as Path, a2 as Publish, a3 as PublishDone, a4 as PublishDoneStatusCode, a5 as PublishNamespace, a6 as PublishNamespaceCancel, a7 as PublishNamespaceDone, a8 as PublishOk, a9 as ReasonPhrase, aa as RequestError, ab as RequestErrorCode, ac as RequestIdMap, ad as RequestOk, ae as RequestUpdate, af as RequestsBlocked, ag as SUPPORTED_VERSIONS, ah as ServerSetup, ai as SetupParameter, aj as SetupParameterType, ak as SetupParameters, al as SubgroupHeader, am as SubgroupHeaderType, an as SubgroupObject, ao as Subscribe, ap as SubscribeNamespace, aq as SubscribeOk, ar as SubscriberPriority, as as SubscriptionFilter, at as TokenAliasType, au as TrackExtension, aw as TrackStatus, ax as TrackStatusCode, ay as Tuple, az as TupleField, aA as UnknownTrackExtension, aB as Unsubscribe, aC as UnsubscribeNamespace, aD as applyMessageParameterUpdate, aE as controlMessageTypeFromBigInt, aF as fetchTypeFromBigInt, aG as filterTypeFromBigInt, aH as groupOrderFromNumber, aI as isBytes, aJ as isVarInt, aK as locHeaderExtensionIdFromNumber, aL as messageParameterTypeFromNumber, aM as publishDoneStatusCodeFromBigInt, aN as requestErrorCodeFromBigInt, aO as setupParameterTypeFromNumber, aP as tokenAliasTypeFromNumber, aQ as trackStatusCodeFromBigInt } from './setup_parameter-BOeGq6Mv.js';
4
3
 
5
4
  /**
6
5
  * Copyright 2025 The MOQtail Authors
@@ -28,6 +27,56 @@ declare class Switch {
28
27
  static parsePayload(buf: BaseByteBuffer): Switch;
29
28
  }
30
29
 
30
+ /**
31
+ * Copyright 2026 The MOQtail Authors
32
+ *
33
+ * Licensed under the Apache License, Version 2.0 (the "License");
34
+ * you may not use this file except in compliance with the License.
35
+ * You may obtain a copy of the License at
36
+ *
37
+ * http://www.apache.org/licenses/LICENSE-2.0
38
+ *
39
+ * Unless required by applicable law or agreed to in writing, software
40
+ * distributed under the License is distributed on an "AS IS" BASIS,
41
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
42
+ * See the License for the specific language governing permissions and
43
+ * limitations under the License.
44
+ */
45
+ interface CMSFTrack {
46
+ name: string;
47
+ packaging: 'cmaf' | 'chunk-per-object' | 'timeline';
48
+ codec?: string;
49
+ role: 'video' | 'audio' | 'timeline';
50
+ depends?: string[];
51
+ mimeType?: string;
52
+ width?: number;
53
+ height?: number;
54
+ timescale?: number;
55
+ bitrate?: number;
56
+ initData?: string;
57
+ }
58
+ interface CMSF {
59
+ version: number;
60
+ tracks: CMSFTrack[];
61
+ }
62
+ declare class CMSFCatalog {
63
+ #private;
64
+ private constructor();
65
+ static from(payload: ArrayBufferLike): CMSFCatalog;
66
+ getByTrackName(trackName: string): CMSFTrack | undefined;
67
+ getTracks(role?: CMSF['tracks'][number]['role']): CMSFTrack[];
68
+ getVideo(index?: number): CMSFTrack | undefined;
69
+ getAudio(index?: number): CMSFTrack | undefined;
70
+ getTimeline(index?: number): CMSFTrack | undefined;
71
+ getCodecString(trackName: string): string | undefined;
72
+ getRole(trackName: string): "timeline" | "video" | "audio" | undefined;
73
+ getPackaging(trackName: string): "cmaf" | "chunk-per-object" | "timeline" | undefined;
74
+ isCMAF(trackName: string): boolean;
75
+ getTimescale(trackName: string): number | undefined;
76
+ getInitData(trackName: string): Uint8Array<ArrayBuffer> | undefined;
77
+ private extractTrackName;
78
+ }
79
+
31
80
  /**
32
81
  * Copyright 2025 The MOQtail Authors
33
82
  *
@@ -204,29 +253,6 @@ declare namespace TerminationCode {
204
253
  function tryFrom(code: number): TerminationCode;
205
254
  }
206
255
 
207
- /**
208
- * Copyright 2025 The MOQtail Authors
209
- *
210
- * Licensed under the Apache License, Version 2.0 (the "License");
211
- * you may not use this file except in compliance with the License.
212
- * You may obtain a copy of the License at
213
- *
214
- * http://www.apache.org/licenses/LICENSE-2.0
215
- *
216
- * Unless required by applicable law or agreed to in writing, software
217
- * distributed under the License is distributed on an "AS IS" BASIS,
218
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
219
- * See the License for the specific language governing permissions and
220
- * limitations under the License.
221
- */
222
- declare enum LOCHeaderExtensionId {
223
- CaptureTimestamp = 2,
224
- VideoFrameMarking = 4,
225
- AudioLevel = 6,
226
- VideoConfig = 13
227
- }
228
- declare function locHeaderExtensionIdFromNumber(value: number): LOCHeaderExtensionId;
229
-
230
256
  /**
231
257
  * Copyright 2025 The MOQtail Authors
232
258
  *
@@ -359,4 +385,58 @@ declare class ExtensionHeaders {
359
385
  static fromKeyValuePairs(kvps: KeyValuePair[]): ExtensionHeader[];
360
386
  }
361
387
 
362
- export { AudioLevel, BaseByteBuffer, CaptureTimestamp, CastingError, ExtensionHeader, ExtensionHeaders, FrozenByteBuffer, FullTrackName, InternalError, InvalidTypeError, InvalidUTF8Error, KeyValueFormattingError, KeyValuePair, LOCHeaderExtensionId, LengthExceedsMaxError, MOQtailError, NotEnoughBytesError, ProtocolViolationError, RequestIdError, Switch, TerminationCode, TerminationError, TimeoutError, TrackNameError, VarIntOverflowError, VideoConfig, VideoFrameMarking, locHeaderExtensionIdFromNumber };
388
+ /**
389
+ * Copyright 2026 The MOQtail Authors
390
+ *
391
+ * Licensed under the Apache License, Version 2.0 (the "License");
392
+ * you may not use this file except in compliance with the License.
393
+ * You may obtain a copy of the License at
394
+ *
395
+ * http://www.apache.org/licenses/LICENSE-2.0
396
+ *
397
+ * Unless required by applicable law or agreed to in writing, software
398
+ * distributed under the License is distributed on an "AS IS" BASIS,
399
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
400
+ * See the License for the specific language governing permissions and
401
+ * limitations under the License.
402
+ */
403
+
404
+ declare class ImmutableExtensionsObjectExtension {
405
+ readonly extensions: KeyValuePair[];
406
+ static readonly TYPE = TrackExtensionType.ImmutableExtensions;
407
+ constructor(extensions: KeyValuePair[]);
408
+ toKeyValuePair(): KeyValuePair;
409
+ static fromKeyValuePair(pair: KeyValuePair): ImmutableExtensionsObjectExtension | undefined;
410
+ }
411
+ declare class PriorGroupIdGapExtension {
412
+ readonly gap: bigint;
413
+ static readonly TYPE = TrackExtensionType.PriorGroupIdGap;
414
+ constructor(gap: bigint);
415
+ toKeyValuePair(): KeyValuePair;
416
+ static fromKeyValuePair(pair: KeyValuePair): PriorGroupIdGapExtension | undefined;
417
+ }
418
+ declare class PriorObjectIdGapExtension {
419
+ readonly gap: bigint;
420
+ static readonly TYPE = TrackExtensionType.PriorObjectIdGap;
421
+ constructor(gap: bigint);
422
+ toKeyValuePair(): KeyValuePair;
423
+ static fromKeyValuePair(pair: KeyValuePair): PriorObjectIdGapExtension | undefined;
424
+ }
425
+ declare class UnknownObjectExtension {
426
+ readonly kvp: KeyValuePair;
427
+ constructor(kvp: KeyValuePair);
428
+ toKeyValuePair(): KeyValuePair;
429
+ }
430
+ type ObjectExtension = ImmutableExtensionsObjectExtension | PriorGroupIdGapExtension | PriorObjectIdGapExtension | UnknownObjectExtension;
431
+ declare namespace ObjectExtension {
432
+ function fromKeyValuePair(pair: KeyValuePair): ObjectExtension;
433
+ function toKeyValuePair(ext: ObjectExtension): KeyValuePair;
434
+ function deserializeAll(buf: BaseByteBuffer): ObjectExtension[];
435
+ function serializeInto(exts: ObjectExtension[], payload: ByteBuffer): void;
436
+ function isImmutableExtensions(ext: ObjectExtension): ext is ImmutableExtensionsObjectExtension;
437
+ function isPriorGroupIdGap(ext: ObjectExtension): ext is PriorGroupIdGapExtension;
438
+ function isPriorObjectIdGap(ext: ObjectExtension): ext is PriorObjectIdGapExtension;
439
+ function isUnknown(ext: ObjectExtension): ext is UnknownObjectExtension;
440
+ }
441
+
442
+ export { AudioLevel, BaseByteBuffer, ByteBuffer, type CMSF, CMSFCatalog, type CMSFTrack, CaptureTimestamp, CastingError, ExtensionHeader, ExtensionHeaders, FrozenByteBuffer, FullTrackName, ImmutableExtensionsObjectExtension, InternalError, InvalidTypeError, InvalidUTF8Error, KeyValueFormattingError, KeyValuePair, LOCHeaderExtensionId, LengthExceedsMaxError, MOQtailError, NotEnoughBytesError, ObjectExtension, PriorGroupIdGapExtension, PriorObjectIdGapExtension, ProtocolViolationError, RequestIdError, Switch, TerminationCode, TerminationError, TimeoutError, TrackExtensionType, TrackNameError, UnknownObjectExtension, VarIntOverflowError, VideoConfig, VideoFrameMarking };