@blockcast/mmt-container 2.2.0-main.cc080e5a56f2 → 2.2.0-main.cc3fe0684403

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.
Files changed (137) hide show
  1. package/README.md +5 -2
  2. package/dist/block-policy.d.ts +88 -16
  3. package/dist/block-policy.d.ts.map +1 -1
  4. package/dist/block-policy.js +164 -56
  5. package/dist/block-policy.js.map +3 -3
  6. package/dist/browser-runtime.js +1485 -172
  7. package/dist/browser-runtime.js.map +4 -4
  8. package/dist/carp-catalog.d.ts +40 -1
  9. package/dist/carp-catalog.d.ts.map +1 -1
  10. package/dist/carp-catalog.js +163 -10
  11. package/dist/carp-catalog.js.map +4 -4
  12. package/dist/catalog-fec-params.d.ts +1 -1
  13. package/dist/catalog-fec-params.d.ts.map +1 -1
  14. package/dist/catalog-fec-params.js +48 -1
  15. package/dist/catalog-fec-params.js.map +3 -3
  16. package/dist/catalog-network-source.js +34 -0
  17. package/dist/catalog-network-source.js.map +3 -3
  18. package/dist/cmaf-block-assembler.js +92 -1
  19. package/dist/cmaf-block-assembler.js.map +2 -2
  20. package/dist/codec-utils.d.ts.map +1 -1
  21. package/dist/codec-utils.js +92 -1
  22. package/dist/codec-utils.js.map +2 -2
  23. package/dist/datagram-leg-deadline.d.ts +118 -0
  24. package/dist/datagram-leg-deadline.d.ts.map +1 -0
  25. package/dist/datagram-leg-deadline.js +217 -0
  26. package/dist/datagram-leg-deadline.js.map +7 -0
  27. package/dist/delivery-catalog.js +68 -0
  28. package/dist/delivery-catalog.js.map +4 -4
  29. package/dist/delta-fallback-config.js +39 -1
  30. package/dist/delta-fallback-config.js.map +4 -4
  31. package/dist/fec-manager.d.ts +155 -10
  32. package/dist/fec-manager.d.ts.map +1 -1
  33. package/dist/fec-manager.js +596 -81
  34. package/dist/fec-manager.js.map +4 -4
  35. package/dist/fec-state.d.ts +17 -5
  36. package/dist/fec-state.d.ts.map +1 -1
  37. package/dist/fec-state.js +41 -1
  38. package/dist/fec-state.js.map +3 -3
  39. package/dist/fec-worker-setup.js +34 -0
  40. package/dist/fec-worker-setup.js.map +3 -3
  41. package/dist/held-layer-admission.js +34 -0
  42. package/dist/held-layer-admission.js.map +3 -3
  43. package/dist/index.d.ts +7 -5
  44. package/dist/index.d.ts.map +1 -1
  45. package/dist/index.js +15 -1
  46. package/dist/index.js.map +2 -2
  47. package/dist/iso-block-locator.d.ts +16 -0
  48. package/dist/iso-block-locator.d.ts.map +1 -1
  49. package/dist/iso-block-locator.js +62 -0
  50. package/dist/iso-block-locator.js.map +3 -3
  51. package/dist/mfu-reassembler.js +34 -0
  52. package/dist/mfu-reassembler.js.map +3 -3
  53. package/dist/mmtp-container-parser.d.ts +30 -2
  54. package/dist/mmtp-container-parser.d.ts.map +1 -1
  55. package/dist/mmtp-container-parser.js +140 -2
  56. package/dist/mmtp-container-parser.js.map +3 -3
  57. package/dist/mmtp-container-parser.no-modules.js +293 -18
  58. package/dist/mmtp-container-parser.no-modules.js.map +4 -4
  59. package/dist/mmtp-decode-pipeline.js +140 -2
  60. package/dist/mmtp-decode-pipeline.js.map +3 -3
  61. package/dist/mmtp-fec-session.js +34 -0
  62. package/dist/mmtp-fec-session.js.map +3 -3
  63. package/dist/mmtp-mode-selection.d.ts +48 -0
  64. package/dist/mmtp-mode-selection.d.ts.map +1 -0
  65. package/dist/mmtp-mode-selection.js +79 -0
  66. package/dist/mmtp-mode-selection.js.map +7 -0
  67. package/dist/mmtp-router.d.ts +66 -8
  68. package/dist/mmtp-router.d.ts.map +1 -1
  69. package/dist/mmtp-router.js +348 -27
  70. package/dist/mmtp-router.js.map +4 -4
  71. package/dist/multicast-auth-catalog.js +42 -2
  72. package/dist/multicast-auth-catalog.js.map +3 -3
  73. package/dist/multicast-input.js +42 -2
  74. package/dist/multicast-input.js.map +3 -3
  75. package/dist/multicast-manager.d.ts +108 -1
  76. package/dist/multicast-manager.d.ts.map +1 -1
  77. package/dist/multicast-manager.js +1067 -138
  78. package/dist/multicast-manager.js.map +4 -4
  79. package/dist/multicast-transport.js +68 -0
  80. package/dist/multicast-transport.js.map +4 -4
  81. package/dist/multicast-unwrap.js +34 -0
  82. package/dist/multicast-unwrap.js.map +3 -3
  83. package/dist/no-modules.d.ts +1 -0
  84. package/dist/no-modules.d.ts.map +1 -1
  85. package/dist/no-modules.js +295 -19
  86. package/dist/no-modules.js.map +4 -4
  87. package/dist/phase14-catalog-override.d.ts +2 -1
  88. package/dist/phase14-catalog-override.d.ts.map +1 -1
  89. package/dist/phase14-catalog-override.js +69 -2
  90. package/dist/phase14-catalog-override.js.map +3 -3
  91. package/dist/repair-fetch.d.ts.map +1 -1
  92. package/dist/repair-fetch.js +50 -0
  93. package/dist/repair-fetch.js.map +3 -3
  94. package/dist/repair-layer-subscriptions.js +34 -0
  95. package/dist/repair-layer-subscriptions.js.map +3 -3
  96. package/dist/signaling.js +34 -0
  97. package/dist/signaling.js.map +3 -3
  98. package/dist/timestamp-codec.js +34 -0
  99. package/dist/timestamp-codec.js.map +3 -3
  100. package/dist/wasm-mfu-reassembler.js +34 -0
  101. package/dist/wasm-mfu-reassembler.js.map +3 -3
  102. package/dist/wasm-mmtp-container-parser.js +140 -2
  103. package/dist/wasm-mmtp-container-parser.js.map +3 -3
  104. package/package.json +5 -5
  105. package/schemas/catalog.schema.json +2 -2
  106. package/src/block-policy.ts +324 -83
  107. package/src/carp-catalog.ts +165 -5
  108. package/src/catalog-fec-params.ts +1 -0
  109. package/src/codec-utils.ts +121 -1
  110. package/src/datagram-leg-deadline.ts +342 -0
  111. package/src/fec-manager.ts +534 -41
  112. package/src/fec-state.ts +21 -5
  113. package/src/index.ts +38 -0
  114. package/src/iso-block-locator.ts +34 -0
  115. package/src/mmtp-container-parser.ts +57 -11
  116. package/src/mmtp-mode-selection.ts +80 -0
  117. package/src/mmtp-router.ts +287 -42
  118. package/src/multicast-manager.ts +218 -10
  119. package/src/no-modules.ts +3 -0
  120. package/src/phase14-catalog-override.ts +14 -3
  121. package/src/repair-fetch.ts +23 -0
  122. package/test-vectors/catalog/README.md +36 -2
  123. package/test-vectors/catalog/mmtp-siblings/ambiguous-sibling.json +158 -0
  124. package/test-vectors/catalog/mmtp-siblings/ladder-bitrate-only.json +231 -0
  125. package/test-vectors/catalog/mmtp-siblings/ladder-four-rungs.json +405 -0
  126. package/test-vectors/catalog/mmtp-siblings/ladder-other-names.json +231 -0
  127. package/test-vectors/catalog/mmtp-siblings/mmtp-mode-unknown.json +143 -0
  128. package/test-vectors/catalog/mmtp-siblings/multicast-endpoint-lists-datagram-track.json +143 -0
  129. package/test-vectors/catalog/mmtp-siblings/no-sibling.json +79 -0
  130. package/test-vectors/catalog/mmtp-siblings/rendition-mismatch.json +143 -0
  131. package/test-vectors/catalog/mmtp-siblings/stream-delivery-mode.json +143 -0
  132. package/test-vectors/catalog/mmtp-siblings/timescale-mismatch.json +143 -0
  133. package/test-vectors/catalog/mmtp-siblings/valid-pair.json +142 -0
  134. package/test-vectors/catalog/section-codes.json +3 -3
  135. package/test-vectors/catalog-timing.json +559 -1
  136. package/test-vectors/catalog-validation.json +266 -7
  137. package/test-vectors/moq/mmtp-mode-selection.json +259 -0
@@ -4,7 +4,8 @@
4
4
  "Hand-authored; expect null = undefined, expect 'throws' = the value cannot be derived and must fail closed.",
5
5
  "keyframeCadence, mediaUnitsPerSecond and groupDuration pin the neutral catalog rules native receiver adapters share (catalogKeyframeCadenceMs, catalogFecMediaUnitsPerSecond, catalogGroupDurationMs). They are NOT what libmmt's own receiver runs today: resolveCatalogTrackFec reads audio rate from sampleRate ?? samplerate (numeric strings admitted) with no endpoint or timescale fallback, so 'audio MP4-shaped timescale' resolves no rate there; computeBlockClassifierGeometry reads only keyframeInterval*. Converging those is a behaviour change, not part of this extraction.",
6
6
  "deliveryWindow and trackFec run against libmmt's production paths (computeFecDeliveryWindowMs, resolveCatalogTrackFec), so an adapter that drops a catalog field (fec.reorderToleranceMs, say) fails here instead of in the field. An iso-ssbg1-v1 span that is 0 or absent keeps in-band geometry but supplies no elapsed-time deadline; local receiver retention remains bounded without inventing a catalog span.",
7
- "interleaveDepth: every row names its D basis. 'access-unit' is what libmmt's receiver and the current publisher run today (D = round(span / (1000/framerate)), multicast-manager FecBlockMapper, fec-manager, block-policy); an adapter must match it to agree with them on block geometry. 'group' is draft-ramadan-moq-fec \u00a75.1/\u00a79 (D over the MoQ group duration); it is the target, not live, and moves only together with the producer contract (BLO-35597). Tick-only groupDurationTicks is authoritative for the group duration."
7
+ "interleaveDepth: every row names its D basis. 'access-unit' is what libmmt's receiver and the current publisher run today (D = round(span / (1000/framerate)), multicast-manager FecBlockMapper, fec-manager, block-policy); an adapter must match it to agree with them on block geometry. 'group' is draft-ramadan-moq-fec \u00a75.1/\u00a79 (D over the MoQ group duration); it is the target, not live, and moves only together with the producer contract (BLO-35597). Tick-only groupDurationTicks is authoritative for the group duration.",
8
+ "datagramLegDeadlines pins computeDatagramLegDeadlines: whether a player takes an \"mfu-datagram\" leg and the limits it runs on (mmt-02 4.3.1). Inputs come from the datagram entry, never from its \"mfu\" sibling. W = largest ceil(span + tolerance) of the decoded instances; take = base span > 0, G > 0, D > 0 and (W <= D or forced); joinDarkMs = ceil(G + W); darkMs = ceil(max(D, W)); noFrameMs = ceil(max(D, G + u + W)); confirmMs = base tolerance if positive, else u. An absent input field is absent, never null. No value is clamped."
8
9
  ],
9
10
  "keyframeCadence": [
10
11
  {
@@ -352,5 +353,562 @@
352
353
  "reorderToleranceMs": 0
353
354
  }
354
355
  }
356
+ ],
357
+ "datagramLegDeadlines": [
358
+ {
359
+ "name": "true spans at a 546 ms delay target",
360
+ "input": {
361
+ "fec": [
362
+ {
363
+ "interleaveDepthMs": 80,
364
+ "reorderToleranceMs": 40
365
+ }
366
+ ],
367
+ "groupDurationMs": 1000,
368
+ "mediaUnitMs": 33.333333333333336,
369
+ "delayTargetMs": 546.22
370
+ },
371
+ "expect": {
372
+ "take": true,
373
+ "reason": "ok",
374
+ "fecWindowMs": 120,
375
+ "joinDarkMs": 1120,
376
+ "darkMs": 547,
377
+ "noFrameMs": 1154,
378
+ "confirmMs": 40
379
+ }
380
+ },
381
+ {
382
+ "name": "true spans at a 500 ms delay target",
383
+ "input": {
384
+ "fec": [
385
+ {
386
+ "interleaveDepthMs": 80,
387
+ "reorderToleranceMs": 40
388
+ }
389
+ ],
390
+ "groupDurationMs": 1000,
391
+ "mediaUnitMs": 33.333333333333336,
392
+ "delayTargetMs": 500
393
+ },
394
+ "expect": {
395
+ "take": true,
396
+ "reason": "ok",
397
+ "fecWindowMs": 120,
398
+ "joinDarkMs": 1120,
399
+ "darkMs": 500,
400
+ "noFrameMs": 1154,
401
+ "confirmMs": 40
402
+ }
403
+ },
404
+ {
405
+ "name": "a 100 ms span under a 1050 ms delay target",
406
+ "input": {
407
+ "fec": [
408
+ {
409
+ "interleaveDepthMs": 100,
410
+ "reorderToleranceMs": 40
411
+ }
412
+ ],
413
+ "groupDurationMs": 1000,
414
+ "mediaUnitMs": 33.333333333333336,
415
+ "delayTargetMs": 1050
416
+ },
417
+ "expect": {
418
+ "take": true,
419
+ "reason": "ok",
420
+ "fecWindowMs": 140,
421
+ "joinDarkMs": 1140,
422
+ "darkMs": 1050,
423
+ "noFrameMs": 1174,
424
+ "confirmMs": 40
425
+ }
426
+ },
427
+ {
428
+ "name": "a deep buffer: the frame limit is the delay target",
429
+ "input": {
430
+ "fec": [
431
+ {
432
+ "interleaveDepthMs": 100,
433
+ "reorderToleranceMs": 40
434
+ }
435
+ ],
436
+ "groupDurationMs": 1000,
437
+ "mediaUnitMs": 33.333333333333336,
438
+ "delayTargetMs": 1500
439
+ },
440
+ "expect": {
441
+ "take": true,
442
+ "reason": "ok",
443
+ "fecWindowMs": 140,
444
+ "joinDarkMs": 1140,
445
+ "darkMs": 1500,
446
+ "noFrameMs": 1500,
447
+ "confirmMs": 40
448
+ }
449
+ },
450
+ {
451
+ "name": "audio: the group is one AAC frame",
452
+ "input": {
453
+ "fec": [
454
+ {
455
+ "interleaveDepthMs": 125,
456
+ "reorderToleranceMs": 40
457
+ }
458
+ ],
459
+ "groupDurationMs": 23.219954648526077,
460
+ "delayTargetMs": 546.22
461
+ },
462
+ "expect": {
463
+ "take": true,
464
+ "reason": "ok",
465
+ "fecWindowMs": 165,
466
+ "joinDarkMs": 189,
467
+ "darkMs": 547,
468
+ "noFrameMs": 547,
469
+ "confirmMs": 40
470
+ }
471
+ },
472
+ {
473
+ "name": "the window equals the delay target",
474
+ "input": {
475
+ "fec": [
476
+ {
477
+ "interleaveDepthMs": 60
478
+ }
479
+ ],
480
+ "groupDurationMs": 33.333333333333336,
481
+ "mediaUnitMs": 33.333333333333336,
482
+ "delayTargetMs": 60
483
+ },
484
+ "expect": {
485
+ "take": true,
486
+ "reason": "ok",
487
+ "fecWindowMs": 60,
488
+ "joinDarkMs": 94,
489
+ "darkMs": 60,
490
+ "noFrameMs": 127,
491
+ "confirmMs": 33.333333333333336
492
+ }
493
+ },
494
+ {
495
+ "name": "a 1000 ms span under a deep buffer",
496
+ "input": {
497
+ "fec": [
498
+ {
499
+ "interleaveDepthMs": 1000,
500
+ "reorderToleranceMs": 40
501
+ }
502
+ ],
503
+ "groupDurationMs": 1000,
504
+ "mediaUnitMs": 33.333333333333336,
505
+ "delayTargetMs": 1050
506
+ },
507
+ "expect": {
508
+ "take": true,
509
+ "reason": "ok",
510
+ "fecWindowMs": 1040,
511
+ "joinDarkMs": 2040,
512
+ "darkMs": 1050,
513
+ "noFrameMs": 2074,
514
+ "confirmMs": 40
515
+ }
516
+ },
517
+ {
518
+ "name": "the window exceeds the delay target: not taken",
519
+ "input": {
520
+ "fec": [
521
+ {
522
+ "interleaveDepthMs": 1000,
523
+ "reorderToleranceMs": 40
524
+ }
525
+ ],
526
+ "groupDurationMs": 1000,
527
+ "mediaUnitMs": 33.333333333333336,
528
+ "delayTargetMs": 500
529
+ },
530
+ "expect": {
531
+ "take": false,
532
+ "reason": "fec-window-exceeds-delay-target",
533
+ "fecWindowMs": 1040,
534
+ "joinDarkMs": 2040,
535
+ "darkMs": 1040,
536
+ "noFrameMs": 2074,
537
+ "confirmMs": 40
538
+ }
539
+ },
540
+ {
541
+ "name": "the same, forced: taken, reported, never clamped",
542
+ "input": {
543
+ "fec": [
544
+ {
545
+ "interleaveDepthMs": 1000,
546
+ "reorderToleranceMs": 40
547
+ }
548
+ ],
549
+ "groupDurationMs": 1000,
550
+ "mediaUnitMs": 33.333333333333336,
551
+ "delayTargetMs": 500,
552
+ "forced": true
553
+ },
554
+ "expect": {
555
+ "take": true,
556
+ "reason": "fec-window-exceeds-delay-target",
557
+ "fecWindowMs": 1040,
558
+ "joinDarkMs": 2040,
559
+ "darkMs": 1040,
560
+ "noFrameMs": 2074,
561
+ "confirmMs": 40
562
+ }
563
+ },
564
+ {
565
+ "name": "a 4000 ms span, forced",
566
+ "input": {
567
+ "fec": [
568
+ {
569
+ "interleaveDepthMs": 4000,
570
+ "reorderToleranceMs": 40
571
+ }
572
+ ],
573
+ "groupDurationMs": 1000,
574
+ "mediaUnitMs": 33.333333333333336,
575
+ "delayTargetMs": 500,
576
+ "forced": true
577
+ },
578
+ "expect": {
579
+ "take": true,
580
+ "reason": "fec-window-exceeds-delay-target",
581
+ "fecWindowMs": 4040,
582
+ "joinDarkMs": 5040,
583
+ "darkMs": 4040,
584
+ "noFrameMs": 5074,
585
+ "confirmMs": 40
586
+ }
587
+ },
588
+ {
589
+ "name": "a 50 ms delay target takes no leg",
590
+ "input": {
591
+ "fec": [
592
+ {
593
+ "interleaveDepthMs": 80,
594
+ "reorderToleranceMs": 40
595
+ }
596
+ ],
597
+ "groupDurationMs": 1000,
598
+ "mediaUnitMs": 33.333333333333336,
599
+ "delayTargetMs": 50
600
+ },
601
+ "expect": {
602
+ "take": false,
603
+ "reason": "fec-window-exceeds-delay-target",
604
+ "fecWindowMs": 120,
605
+ "joinDarkMs": 1120,
606
+ "darkMs": 120,
607
+ "noFrameMs": 1154,
608
+ "confirmMs": 40
609
+ }
610
+ },
611
+ {
612
+ "name": "absent tolerance stays absent",
613
+ "input": {
614
+ "fec": [
615
+ {
616
+ "interleaveDepthMs": 100.2
617
+ }
618
+ ],
619
+ "groupDurationMs": 1000,
620
+ "mediaUnitMs": 33.333333333333336,
621
+ "delayTargetMs": 500
622
+ },
623
+ "expect": {
624
+ "take": true,
625
+ "reason": "ok",
626
+ "fecWindowMs": 101,
627
+ "joinDarkMs": 1101,
628
+ "darkMs": 500,
629
+ "noFrameMs": 1135,
630
+ "confirmMs": 33.333333333333336
631
+ }
632
+ },
633
+ {
634
+ "name": "a declared 0 tolerance adds nothing",
635
+ "input": {
636
+ "fec": [
637
+ {
638
+ "interleaveDepthMs": 100,
639
+ "reorderToleranceMs": 0
640
+ }
641
+ ],
642
+ "groupDurationMs": 1000,
643
+ "mediaUnitMs": 33.333333333333336,
644
+ "delayTargetMs": 500
645
+ },
646
+ "expect": {
647
+ "take": true,
648
+ "reason": "ok",
649
+ "fecWindowMs": 100,
650
+ "joinDarkMs": 1100,
651
+ "darkMs": 500,
652
+ "noFrameMs": 1134,
653
+ "confirmMs": 33.333333333333336
654
+ }
655
+ },
656
+ {
657
+ "name": "no media unit stated",
658
+ "input": {
659
+ "fec": [
660
+ {
661
+ "interleaveDepthMs": 80,
662
+ "reorderToleranceMs": 40
663
+ }
664
+ ],
665
+ "groupDurationMs": 1000,
666
+ "delayTargetMs": 500
667
+ },
668
+ "expect": {
669
+ "take": true,
670
+ "reason": "ok",
671
+ "fecWindowMs": 120,
672
+ "joinDarkMs": 1120,
673
+ "darkMs": 500,
674
+ "noFrameMs": 1120,
675
+ "confirmMs": 40
676
+ }
677
+ },
678
+ {
679
+ "name": "neither tolerance nor media unit: the confirming turn has no delay",
680
+ "input": {
681
+ "fec": [
682
+ {
683
+ "interleaveDepthMs": 100
684
+ }
685
+ ],
686
+ "groupDurationMs": 1000,
687
+ "delayTargetMs": 500
688
+ },
689
+ "expect": {
690
+ "take": true,
691
+ "reason": "ok",
692
+ "fecWindowMs": 100,
693
+ "joinDarkMs": 1100,
694
+ "darkMs": 500,
695
+ "noFrameMs": 1100,
696
+ "confirmMs": 0
697
+ }
698
+ },
699
+ {
700
+ "name": "a decoded overlay bounds the leg",
701
+ "input": {
702
+ "fec": [
703
+ {
704
+ "interleaveDepthMs": 80,
705
+ "reorderToleranceMs": 40
706
+ },
707
+ {
708
+ "interleaveDepthMs": 250,
709
+ "reorderToleranceMs": 40
710
+ }
711
+ ],
712
+ "groupDurationMs": 1000,
713
+ "mediaUnitMs": 33.333333333333336,
714
+ "delayTargetMs": 546.22
715
+ },
716
+ "expect": {
717
+ "take": true,
718
+ "reason": "ok",
719
+ "fecWindowMs": 290,
720
+ "joinDarkMs": 1290,
721
+ "darkMs": 547,
722
+ "noFrameMs": 1324,
723
+ "confirmMs": 40
724
+ }
725
+ },
726
+ {
727
+ "name": "an overlay with no span adds no window",
728
+ "input": {
729
+ "fec": [
730
+ {
731
+ "interleaveDepthMs": 80,
732
+ "reorderToleranceMs": 40
733
+ },
734
+ {
735
+ "reorderToleranceMs": 40
736
+ }
737
+ ],
738
+ "groupDurationMs": 1000,
739
+ "mediaUnitMs": 33.333333333333336,
740
+ "delayTargetMs": 546.22
741
+ },
742
+ "expect": {
743
+ "take": true,
744
+ "reason": "ok",
745
+ "fecWindowMs": 120,
746
+ "joinDarkMs": 1120,
747
+ "darkMs": 547,
748
+ "noFrameMs": 1154,
749
+ "confirmMs": 40
750
+ }
751
+ },
752
+ {
753
+ "name": "zero span",
754
+ "input": {
755
+ "fec": [
756
+ {
757
+ "interleaveDepthMs": 0,
758
+ "reorderToleranceMs": 40
759
+ }
760
+ ],
761
+ "groupDurationMs": 1000,
762
+ "mediaUnitMs": 33.333333333333336,
763
+ "delayTargetMs": 500
764
+ },
765
+ "expect": {
766
+ "take": false,
767
+ "reason": "no-fec-span"
768
+ }
769
+ },
770
+ {
771
+ "name": "absent span",
772
+ "input": {
773
+ "fec": [
774
+ {
775
+ "reorderToleranceMs": 40
776
+ }
777
+ ],
778
+ "groupDurationMs": 1000,
779
+ "mediaUnitMs": 33.333333333333336,
780
+ "delayTargetMs": 500
781
+ },
782
+ "expect": {
783
+ "take": false,
784
+ "reason": "no-fec-span"
785
+ }
786
+ },
787
+ {
788
+ "name": "no instance",
789
+ "input": {
790
+ "fec": [],
791
+ "groupDurationMs": 1000,
792
+ "mediaUnitMs": 33.333333333333336,
793
+ "delayTargetMs": 500
794
+ },
795
+ "expect": {
796
+ "take": false,
797
+ "reason": "no-fec-span"
798
+ }
799
+ },
800
+ {
801
+ "name": "negative tolerance",
802
+ "input": {
803
+ "fec": [
804
+ {
805
+ "interleaveDepthMs": 80,
806
+ "reorderToleranceMs": -1
807
+ }
808
+ ],
809
+ "groupDurationMs": 1000,
810
+ "mediaUnitMs": 33.333333333333336,
811
+ "delayTargetMs": 500
812
+ },
813
+ "expect": {
814
+ "take": false,
815
+ "reason": "no-fec-span"
816
+ }
817
+ },
818
+ {
819
+ "name": "an overlay with a span and a base without",
820
+ "input": {
821
+ "fec": [
822
+ {
823
+ "reorderToleranceMs": 40
824
+ },
825
+ {
826
+ "interleaveDepthMs": 250,
827
+ "reorderToleranceMs": 40
828
+ }
829
+ ],
830
+ "groupDurationMs": 1000,
831
+ "mediaUnitMs": 33.333333333333336,
832
+ "delayTargetMs": 500
833
+ },
834
+ "expect": {
835
+ "take": false,
836
+ "reason": "no-fec-span"
837
+ }
838
+ },
839
+ {
840
+ "name": "the forced mode does not run a leg with no span",
841
+ "input": {
842
+ "fec": [
843
+ {
844
+ "interleaveDepthMs": 0,
845
+ "reorderToleranceMs": 40
846
+ }
847
+ ],
848
+ "groupDurationMs": 1000,
849
+ "mediaUnitMs": 33.333333333333336,
850
+ "delayTargetMs": 500,
851
+ "forced": true
852
+ },
853
+ "expect": {
854
+ "take": false,
855
+ "reason": "no-fec-span"
856
+ }
857
+ },
858
+ {
859
+ "name": "no group duration",
860
+ "input": {
861
+ "fec": [
862
+ {
863
+ "interleaveDepthMs": 80,
864
+ "reorderToleranceMs": 40
865
+ }
866
+ ],
867
+ "mediaUnitMs": 33.333333333333336,
868
+ "delayTargetMs": 500
869
+ },
870
+ "expect": {
871
+ "take": false,
872
+ "reason": "no-group-duration",
873
+ "fecWindowMs": 120
874
+ }
875
+ },
876
+ {
877
+ "name": "no delay target",
878
+ "input": {
879
+ "fec": [
880
+ {
881
+ "interleaveDepthMs": 80,
882
+ "reorderToleranceMs": 40
883
+ }
884
+ ],
885
+ "groupDurationMs": 1000,
886
+ "mediaUnitMs": 33.333333333333336
887
+ },
888
+ "expect": {
889
+ "take": false,
890
+ "reason": "no-delay-target",
891
+ "fecWindowMs": 120
892
+ }
893
+ },
894
+ {
895
+ "name": "a zero delay target",
896
+ "input": {
897
+ "fec": [
898
+ {
899
+ "interleaveDepthMs": 80,
900
+ "reorderToleranceMs": 40
901
+ }
902
+ ],
903
+ "groupDurationMs": 1000,
904
+ "mediaUnitMs": 33.333333333333336,
905
+ "delayTargetMs": 0
906
+ },
907
+ "expect": {
908
+ "take": false,
909
+ "reason": "no-delay-target",
910
+ "fecWindowMs": 120
911
+ }
912
+ }
355
913
  ]
356
914
  }