@norskvideo/norsk-studio-built-ins 1.27.0-2025-04-05-fad1c39a → 1.27.0-2025-04-07-8f68de69

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 (82) hide show
  1. package/client/info.js +6824 -1190
  2. package/lib/info.js +29 -21
  3. package/lib/info.js.map +1 -1
  4. package/lib/output.autoCmaf/info.js +4 -132
  5. package/lib/output.autoCmaf/info.js.map +1 -1
  6. package/lib/output.autoCmaf/runtime.js +4 -54
  7. package/lib/output.autoCmaf/runtime.js.map +1 -1
  8. package/lib/output.autoCmaf/types.d.ts +31 -31
  9. package/lib/output.autoCmaf/types.yaml +4 -85
  10. package/lib/output.cmafMultiVariant/info.d.ts +15 -0
  11. package/lib/output.cmafMultiVariant/info.js +91 -0
  12. package/lib/output.cmafMultiVariant/info.js.map +1 -0
  13. package/lib/output.cmafMultiVariant/runtime.d.ts +37 -0
  14. package/lib/output.cmafMultiVariant/runtime.js +158 -0
  15. package/lib/output.cmafMultiVariant/runtime.js.map +1 -0
  16. package/lib/output.cmafMultiVariant/types.d.ts +130 -0
  17. package/lib/output.cmafMultiVariant/types.js +3 -0
  18. package/lib/output.cmafMultiVariant/types.js.map +1 -0
  19. package/lib/output.cmafMultiVariant/types.yaml +74 -0
  20. package/lib/output.cmafPlaylist/info.d.ts +22 -0
  21. package/lib/output.cmafPlaylist/info.js +114 -0
  22. package/lib/output.cmafPlaylist/info.js.map +1 -0
  23. package/lib/output.cmafPlaylist/runtime.d.ts +41 -0
  24. package/lib/output.cmafPlaylist/runtime.js +239 -0
  25. package/lib/output.cmafPlaylist/runtime.js.map +1 -0
  26. package/lib/output.cmafPlaylist/types.d.ts +155 -0
  27. package/lib/output.cmafPlaylist/types.js +3 -0
  28. package/lib/output.cmafPlaylist/types.js.map +1 -0
  29. package/lib/output.cmafPlaylist/types.yaml +90 -0
  30. package/lib/output.tsMediaPlaylist/info.d.ts +22 -0
  31. package/lib/output.tsMediaPlaylist/info.js +113 -0
  32. package/lib/output.tsMediaPlaylist/info.js.map +1 -0
  33. package/lib/output.tsMediaPlaylist/runtime.d.ts +41 -0
  34. package/lib/output.tsMediaPlaylist/runtime.js +225 -0
  35. package/lib/output.tsMediaPlaylist/runtime.js.map +1 -0
  36. package/lib/output.tsMediaPlaylist/types.d.ts +155 -0
  37. package/lib/output.tsMediaPlaylist/types.js +3 -0
  38. package/lib/output.tsMediaPlaylist/types.js.map +1 -0
  39. package/lib/output.tsMediaPlaylist/types.yaml +90 -0
  40. package/lib/output.tsMultiVariant/info.d.ts +15 -0
  41. package/lib/output.tsMultiVariant/info.js +91 -0
  42. package/lib/output.tsMultiVariant/info.js.map +1 -0
  43. package/lib/output.tsMultiVariant/runtime.d.ts +37 -0
  44. package/lib/output.tsMultiVariant/runtime.js +157 -0
  45. package/lib/output.tsMultiVariant/runtime.js.map +1 -0
  46. package/lib/output.tsMultiVariant/types.d.ts +130 -0
  47. package/lib/output.tsMultiVariant/types.js +3 -0
  48. package/lib/output.tsMultiVariant/types.js.map +1 -0
  49. package/lib/output.tsMultiVariant/types.yaml +74 -0
  50. package/lib/processor.fixedLadder/info.d.ts +3 -3
  51. package/lib/processor.fixedLadder/info.js +1159 -73
  52. package/lib/processor.fixedLadder/info.js.map +1 -1
  53. package/lib/processor.fixedLadder/nvidia-rate-control-view.d.ts +4 -0
  54. package/lib/processor.fixedLadder/nvidia-rate-control-view.js +20 -0
  55. package/lib/processor.fixedLadder/nvidia-rate-control-view.js.map +1 -0
  56. package/lib/processor.fixedLadder/nvidia-view.d.ts +5 -0
  57. package/lib/processor.fixedLadder/nvidia-view.js +20 -0
  58. package/lib/processor.fixedLadder/nvidia-view.js.map +1 -0
  59. package/lib/processor.fixedLadder/quadra-view.d.ts +6 -0
  60. package/lib/processor.fixedLadder/quadra-view.js +22 -0
  61. package/lib/processor.fixedLadder/quadra-view.js.map +1 -0
  62. package/lib/processor.fixedLadder/runtime.js.map +1 -1
  63. package/lib/processor.fixedLadder/software-view.d.ts +5 -0
  64. package/lib/processor.fixedLadder/software-view.js +20 -0
  65. package/lib/processor.fixedLadder/software-view.js.map +1 -0
  66. package/lib/processor.fixedLadder/types.d.ts +108 -20
  67. package/lib/processor.fixedLadder/types.yaml +241 -34
  68. package/lib/processor.fixedLadder/x26x-bitrate-view.d.ts +4 -0
  69. package/lib/processor.fixedLadder/x26x-bitrate-view.js +20 -0
  70. package/lib/processor.fixedLadder/x26x-bitrate-view.js.map +1 -0
  71. package/lib/shared/cmaf.d.ts +17 -0
  72. package/lib/shared/cmaf.js +198 -0
  73. package/lib/shared/cmaf.js.map +1 -0
  74. package/lib/{output.autoCmaf/form-views.d.ts → shared/playlist-form-views.d.ts} +1 -1
  75. package/lib/{output.autoCmaf/form-views.js → shared/playlist-form-views.js} +1 -1
  76. package/lib/shared/playlist-form-views.js.map +1 -0
  77. package/lib/shared/types.d.ts +158 -0
  78. package/lib/shared/types.js +3 -0
  79. package/lib/shared/types.js.map +1 -0
  80. package/lib/shared/types.yaml +182 -0
  81. package/package.json +3 -3
  82. package/lib/output.autoCmaf/form-views.js.map +0 -1
@@ -5,6 +5,44 @@ info:
5
5
 
6
6
  components:
7
7
  schemas:
8
+ x26xBitrateMode:
9
+ type: object
10
+ properties:
11
+ value:
12
+ type: number
13
+ mode:
14
+ type: string
15
+ enum: ["abr", "cqp", "crf"]
16
+ required: ['value', 'mode']
17
+
18
+ nvidiaRateControl:
19
+ type: object
20
+ properties:
21
+ mode:
22
+ type: string
23
+ enum: ['con_stqp', 'vbr', 'cbr']
24
+ averageBitrate:
25
+ type: number
26
+ maxBitrate:
27
+ type: number
28
+ vbvBufferSize:
29
+ type: number
30
+ vbvInitialDelay:
31
+ type: number
32
+ enableLookahead:
33
+ type: boolean
34
+ strictGopTarget:
35
+ type: boolean
36
+ lookaheadDepth:
37
+ type: number
38
+ enableTemporalAQ:
39
+ type: boolean
40
+ enableSpatialAQ:
41
+ type: boolean
42
+ aqStrength:
43
+ type: number
44
+ required: ['mode', 'averageBitrate']
45
+
8
46
  x264Codec:
9
47
  type: object
10
48
  properties:
@@ -14,14 +52,7 @@ components:
14
52
  threads:
15
53
  type: number
16
54
  bitrateMode:
17
- type: object
18
- properties:
19
- value:
20
- type: number
21
- mode:
22
- type: string
23
- enum: ["abr", "cqp", "crf"]
24
- required: ['value', 'mode']
55
+ $ref: '#/components/schemas/x26xBitrateMode'
25
56
  profile:
26
57
  type: string
27
58
  enum: ["baseline", "main", "high", "high10", "high422", "high444"]
@@ -140,37 +171,209 @@ components:
140
171
  outputAud:
141
172
  type: boolean
142
173
  rateControl:
143
- type: object
144
- properties:
145
- mode:
146
- type: string
147
- enum: ['con_stqp', 'vbr', 'cbr']
148
- averageBitrate:
149
- type: number
150
- maxBitrate:
151
- type: number
152
- vbvBufferSize:
153
- type: number
154
- vbvInitialDelay:
155
- type: number
156
- enableLookahead:
157
- type: boolean
158
- strictGopTarget:
159
- type: boolean
160
- lookaheadDepth:
161
- type: number
162
- enableTemporalAQ:
163
- type: boolean
164
- enableSpatialAQ:
165
- type: boolean
166
- aqStrength:
167
- type: number
168
- required: ['mode', 'averageBitrate']
174
+ $ref: '#/components/schemas/nvidiaRateControl'
169
175
  useBFramesAsRef:
170
176
  type: string
171
177
  enum: ['disabled', 'each', 'middle']
172
178
  required: ['type']
173
179
 
180
+ x265Codec:
181
+ type: object
182
+ properties:
183
+ type:
184
+ type: string
185
+ enum: ["x265"]
186
+ threads:
187
+ type: number
188
+ bitrateMode:
189
+ $ref: '#/components/schemas/x26xBitrateMode'
190
+ profile:
191
+ type: string
192
+ enum: ["main", "main10", "main444_8", "main422_10", "main444_10"]
193
+ level:
194
+ type: number
195
+ enum: [1, 2, 2.1, 3, 3.1, 4, 4.1, 5, 5.1, 5.2, 6, 6.1, 6.2]
196
+ tier:
197
+ type: string
198
+ enum: ["main", "high"]
199
+ keyFrameIntervalMin:
200
+ type: number
201
+ keyFrameIntervalMax:
202
+ type: number
203
+ bframes:
204
+ type: number
205
+ tune:
206
+ type: string
207
+ enum: ["psnr", "ssim", "grain", "zerolatency", "fastdecode", "animation"]
208
+ preset:
209
+ type: string
210
+ enum: ["ultrafast", "superfast", "veryfast", "faster", "fast", "medium", "slow", "slower", "veryslow", "placebo"]
211
+ frameReference:
212
+ type: number
213
+ vbvMaxRate:
214
+ type: number
215
+ vbvBufferSize:
216
+ type: number
217
+ sceneCut:
218
+ type: number
219
+ aud:
220
+ type: boolean
221
+ noDeblock:
222
+ type: boolean
223
+ required: ['type']
224
+
225
+ quadraHEVCCodec:
226
+ type: object
227
+ properties:
228
+ type:
229
+ type: string
230
+ enum: ['quadra-hevc']
231
+ extraOpts:
232
+ type: string
233
+ enableAud:
234
+ type: boolean
235
+ gpuIndex:
236
+ type: number
237
+ bitrate:
238
+ type: number
239
+ enableVfr:
240
+ type: boolean
241
+ crf:
242
+ type: number
243
+ gopPresetIndex:
244
+ type: number
245
+ intraPeriod:
246
+ type: number
247
+ rcEnable:
248
+ type: boolean
249
+ intraQp:
250
+ type: number
251
+ rcInitDelay:
252
+ type: number
253
+ profile:
254
+ type: string
255
+ enum: ['main', 'main10']
256
+ level:
257
+ type: number
258
+ enum: [ 1, 2, 2.1, 3, 3.1, 4, 4.1, 5, 5.1, 5.2, 6, 6.1, 6.2]
259
+ tier:
260
+ type: string
261
+ enum: ["main", "high"]
262
+ lossless:
263
+ type: boolean
264
+ hrdEnable:
265
+ type: boolean
266
+ dolbyVisionProfile:
267
+ type: number
268
+ fillerEnable:
269
+ type: boolean
270
+ minQp:
271
+ type: number
272
+ maxQp:
273
+ type: number
274
+ maxDeltaQp:
275
+ type: number
276
+ cuLevelRCEnable:
277
+ type: boolean
278
+ lookAheadDepth:
279
+ type: number
280
+ vbvBufferSize:
281
+ type: number
282
+ vbvMaxRate:
283
+ type: number
284
+ required: ['type']
285
+
286
+ nvidiaHEVCCodec:
287
+ type: object
288
+ properties:
289
+ type:
290
+ type: string
291
+ enum: ['nv-hevc']
292
+ preset:
293
+ type: string
294
+ enum: ['p1', 'p2', 'p3', 'p4', 'p5', 'p6', 'p7']
295
+ tuning:
296
+ type: string
297
+ enum: ['high_quality', 'low_latency', 'ultra_low_latency', 'lossless']
298
+ idrPeriod:
299
+ type: number
300
+ gopInterval:
301
+ type: number
302
+ frameIntervalP:
303
+ type: number
304
+ level:
305
+ type: number
306
+ enum: [1, 2, 2.1, 3, 3.1, 4, 4.1, 5, 5.1, 5.2, 6, 6.1, 6.2]
307
+ profile:
308
+ type: string
309
+ enum: ['main', 'main10']
310
+ outputAud:
311
+ type: boolean
312
+ tier:
313
+ type: string
314
+ enum: ["main", "high" ]
315
+ rateControl:
316
+ $ref: '#/components/schemas/nvidiaRateControl'
317
+ useBFramesAsRef:
318
+ type: string
319
+ enum: ['disabled', 'each', 'middle']
320
+ required: ['type']
321
+
322
+ quadraAV1Codec:
323
+ type: object
324
+ properties:
325
+ type:
326
+ type: string
327
+ enum: ['quadra-av1']
328
+ extraOpts:
329
+ type: string
330
+ enableAud:
331
+ type: boolean
332
+ gpuIndex:
333
+ type: number
334
+ bitrate:
335
+ type: number
336
+ enableVfr:
337
+ type: boolean
338
+ crf:
339
+ type: number
340
+ gopPresetIndex:
341
+ type: number
342
+ intraPeriod:
343
+ type: number
344
+ rcEnable:
345
+ type: boolean
346
+ intraQp:
347
+ type: number
348
+ rcInitDelay:
349
+ type: number
350
+ profile:
351
+ type: string
352
+ enum: ['main_420_8']
353
+ tier:
354
+ type: string
355
+ enum: ["main", "high"]
356
+ level:
357
+ type: number
358
+ enum: [1, 2, 2.1, 3, 3.1, 4, 4.1, 5, 5.1, 5.2, 6, 6.1, 6.2]
359
+ fillerEnable:
360
+ type: boolean
361
+ minQp:
362
+ type: number
363
+ maxQp:
364
+ type: number
365
+ maxDeltaQp:
366
+ type: number
367
+ cuLevelRCEnable:
368
+ type: boolean
369
+ lookAheadDepth:
370
+ type: number
371
+ vbvBufferSize:
372
+ type: number
373
+ vbvMaxRate:
374
+ type: number
375
+ required: ['type']
376
+
174
377
  frameRate:
175
378
  type: object
176
379
  properties:
@@ -190,6 +393,7 @@ components:
190
393
  codec:
191
394
  oneOf:
192
395
  - $ref: '#/components/schemas/x264Codec'
396
+ - $ref: '#/components/schemas/x265Codec'
193
397
  frameRate:
194
398
  $ref: '#/components/schemas/frameRate'
195
399
  required: ['width', 'height', 'codec', 'frameRate']
@@ -204,6 +408,7 @@ components:
204
408
  codec:
205
409
  oneOf:
206
410
  - $ref: '#/components/schemas/nvidiaH264Codec'
411
+ - $ref: '#/components/schemas/nvidiaHEVCCodec'
207
412
  frameRate:
208
413
  $ref: '#/components/schemas/frameRate'
209
414
  required: ['width', 'height', 'codec', 'frameRate']
@@ -228,6 +433,8 @@ components:
228
433
  codec:
229
434
  oneOf:
230
435
  - $ref: '#/components/schemas/quadraH264Codec'
436
+ - $ref: '#/components/schemas/quadraHEVCCodec'
437
+ - $ref: '#/components/schemas/quadraAV1Codec'
231
438
  frameRate:
232
439
  $ref: '#/components/schemas/frameRate'
233
440
  required: ['width', 'height', 'codec', 'frameRate']
@@ -0,0 +1,4 @@
1
+ import type { components } from "./types";
2
+ type X26xBitrate = components["schemas"]["x26xBitrateMode"];
3
+ export default function (bitrate: X26xBitrate | undefined): import("react/jsx-runtime").JSX.Element;
4
+ export {};
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = default_1;
4
+ const jsx_runtime_1 = require("react/jsx-runtime");
5
+ function default_1(bitrate) {
6
+ const value = (() => {
7
+ if (bitrate) {
8
+ switch (bitrate.mode) {
9
+ case "abr": return (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: ["ABR ", bitrate.value, "kbps "] });
10
+ case "cqp": return (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: ["CQP ", bitrate.value] });
11
+ case "crf": return (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: ["CRF ", bitrate.value] });
12
+ }
13
+ }
14
+ else {
15
+ return (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: "N/A" });
16
+ }
17
+ })();
18
+ return ((0, jsx_runtime_1.jsx)("div", { className: "text-gray-900 dark:text-white", children: value }));
19
+ }
20
+ //# sourceMappingURL=x26x-bitrate-view.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"x26x-bitrate-view.js","sourceRoot":"","sources":["../../src/processor.fixedLadder/x26x-bitrate-view.tsx"],"names":[],"mappings":";;AAIA,4BAcC;;AAdD,mBAAyB,OAAgC;IACvD,MAAM,KAAK,GAAG,CAAC,GAAG,EAAE;QAClB,IAAI,OAAO,EAAE,CAAC;YACZ,QAAQ,OAAO,CAAC,IAAI,EAAE,CAAC;gBACrB,KAAK,KAAK,CAAC,CAAC,OAAO,qEAAO,OAAO,CAAC,KAAK,aAAS,CAAC;gBACjD,KAAK,KAAK,CAAC,CAAC,OAAO,qEAAO,OAAO,CAAC,KAAK,IAAI,CAAC;gBAC5C,KAAK,KAAK,CAAC,CAAC,OAAO,qEAAO,OAAO,CAAC,KAAK,IAAI,CAAC;YAC9C,CAAC;QACH,CAAC;aACI,CAAC;YACJ,OAAO,mEAAQ,CAAC;QAClB,CAAC;IACH,CAAC,CAAC,EAAE,CAAC;IACL,OAAO,CAAC,gCAAK,SAAS,EAAC,+BAA+B,YAAE,KAAK,GAAQ,CAAC,CAAA;AACxE,CAAC"}
@@ -0,0 +1,17 @@
1
+ import { type BaseConfig, type FormEntry } from '@norskvideo/norsk-studio/lib/extension/client-types';
2
+ import { components } from './types';
3
+ import { CmafDestinationSettings } from '@norskvideo/norsk-sdk';
4
+ export type Segment = components['schemas']['AutoCmafSegment'];
5
+ export type Destination = components['schemas']['AutoCmafDestination'];
6
+ export declare const SegmentFormEntry: FormEntry<BaseConfig, Segment>;
7
+ export declare const DestinationsFormEntry: FormEntry<BaseConfig, Destination[]>;
8
+ export type ReifiedDestination = {
9
+ advertDestinations: string[];
10
+ destinations: CmafDestinationSettings[];
11
+ };
12
+ export declare function reifyDestinations(cfg: {
13
+ publishingGroup: string;
14
+ destinations: Destination[];
15
+ segments: Segment;
16
+ sessionId?: string;
17
+ }): ReifiedDestination;
@@ -0,0 +1,198 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.DestinationsFormEntry = exports.SegmentFormEntry = void 0;
7
+ exports.reifyDestinations = reifyDestinations;
8
+ const client_types_1 = require("@norskvideo/norsk-studio/lib/extension/client-types");
9
+ const playlist_form_views_1 = require("./playlist-form-views");
10
+ const zod_1 = __importDefault(require("zod"));
11
+ const validation_1 = require("@norskvideo/norsk-studio/lib/extension/validation");
12
+ exports.SegmentFormEntry = {
13
+ help: "Detailed segment configuration",
14
+ hint: {
15
+ type: 'form-item',
16
+ view: playlist_form_views_1.SegmentConfiguration,
17
+ envOverride: true,
18
+ form: {
19
+ retentionPeriod: {
20
+ help: "How many seconds of data to retain for playback in media playlists",
21
+ hint: {
22
+ type: "numeric",
23
+ defaultValue: 60,
24
+ validation: zod_1.default.number().min(10).max(3600)
25
+ }
26
+ },
27
+ defaultSegmentCount: {
28
+ help: "How many segments to display in a default playlist (0 means show all)",
29
+ hint: {
30
+ type: "numeric",
31
+ defaultValue: 0,
32
+ validation: zod_1.default.number()
33
+ }
34
+ },
35
+ targetSegmentDuration: {
36
+ help: "How many seconds should be in each segment",
37
+ hint: {
38
+ type: "numeric",
39
+ defaultValue: 4.0,
40
+ validation: zod_1.default.number().min(1).max(10)
41
+ }
42
+ },
43
+ targetPartDuration: {
44
+ help: "For low latency playlists, what size parts should be generated in seconds",
45
+ hint: {
46
+ type: "numeric",
47
+ defaultValue: 1.0,
48
+ validation: zod_1.default.number().min(0.2).max(10),
49
+ global: {
50
+ constraint: 'custom',
51
+ message: "Part duration must be less than segment duration",
52
+ validate: (cfg) => {
53
+ if (cfg.targetPartDuration < cfg.targetSegmentDuration)
54
+ return true;
55
+ return false;
56
+ }
57
+ }
58
+ },
59
+ },
60
+ holdBackSegments: {
61
+ help: "How many segments back should a player start",
62
+ hint: {
63
+ type: "numeric",
64
+ optional: true,
65
+ validation: zod_1.default.number().min(3).max(10).int().optional(),
66
+ },
67
+ },
68
+ holdBackParts: {
69
+ help: "How many parts back should a player start",
70
+ hint: {
71
+ type: "numeric",
72
+ optional: true,
73
+ validation: zod_1.default.number().min(3).max(10).int().optional(),
74
+ },
75
+ },
76
+ }
77
+ }
78
+ };
79
+ exports.DestinationsFormEntry = {
80
+ help: "Destination to publish to",
81
+ hint: {
82
+ type: "form-list-pick",
83
+ envOverride: true,
84
+ defaultValue: [],
85
+ view: playlist_form_views_1.Destination,
86
+ form: (0, client_types_1.discriminatedForm)({
87
+ akamai: {
88
+ display: "Akamai",
89
+ form: {
90
+ ingest: {
91
+ help: "The complete URL to be pushed to",
92
+ hint: {
93
+ type: "text",
94
+ }
95
+ },
96
+ playback: {
97
+ help: "The URL from which playback can be accessed",
98
+ hint: {
99
+ type: "text",
100
+ defaultValue: ""
101
+ }
102
+ },
103
+ includeAdInsertions: {
104
+ help: "If ad markers are inserted, include them in this publication",
105
+ hint: {
106
+ type: "boolean",
107
+ defaultValue: false
108
+ }
109
+ }
110
+ }
111
+ },
112
+ s3: {
113
+ display: "S3",
114
+ form: {
115
+ host: {
116
+ help: "The hostname of the s3 bucket to push to",
117
+ hint: {
118
+ type: "text",
119
+ validation: validation_1.Hostname
120
+ }
121
+ },
122
+ prefix: {
123
+ help: "The sub directory of the bucket to place playlists and segments into",
124
+ hint: {
125
+ type: "text",
126
+ defaultValue: ""
127
+ }
128
+ },
129
+ includeAdInsertions: {
130
+ help: "If ad markers are inserted, include them in this publication",
131
+ hint: {
132
+ type: "boolean",
133
+ defaultValue: false
134
+ }
135
+ }
136
+ }
137
+ }
138
+ })
139
+ }
140
+ };
141
+ function reifyDestinations(cfg) {
142
+ const ret = { destinations: [], advertDestinations: [] };
143
+ ret.destinations.push({
144
+ type: "local",
145
+ retentionPeriodSeconds: cfg.segments.retentionPeriod,
146
+ defaultSegmentCount: cfg.segments.defaultSegmentCount,
147
+ holdBackSeconds: (cfg.segments.holdBackSegments ?? 3) * cfg.segments.targetSegmentDuration,
148
+ partHoldBackSeconds: (cfg.segments.holdBackParts ?? 3) * cfg.segments.targetPartDuration,
149
+ sessionId: cfg.sessionId,
150
+ id: `local-${cfg.publishingGroup}`
151
+ });
152
+ cfg.destinations.filter((d) => d.type == 's3').forEach((d, i) => {
153
+ let sanitisedPrefix = d.prefix;
154
+ if (sanitisedPrefix == "") {
155
+ sanitisedPrefix = "/";
156
+ }
157
+ else {
158
+ if (!sanitisedPrefix.startsWith("/"))
159
+ sanitisedPrefix = "/" + sanitisedPrefix;
160
+ if (!sanitisedPrefix.endsWith("/"))
161
+ sanitisedPrefix = sanitisedPrefix + "/";
162
+ }
163
+ const id = `s3-${i}-${cfg.publishingGroup}`;
164
+ ret.destinations.push({
165
+ id,
166
+ type: 's3',
167
+ awsRegion: process.env.AWS_REGION ?? 'eu-west-2',
168
+ host: d.host,
169
+ sessionId: cfg.sessionId,
170
+ pathPrefix: sanitisedPrefix,
171
+ port: 80,
172
+ retentionPeriodSeconds: cfg.segments.retentionPeriod,
173
+ holdBackSeconds: (cfg.segments.holdBackSegments ?? 3) * cfg.segments.targetSegmentDuration,
174
+ partHoldBackSeconds: (cfg.segments.holdBackParts ?? 3) * cfg.segments.targetPartDuration
175
+ });
176
+ if (d.includeAdInsertions) {
177
+ ret.advertDestinations.push(id);
178
+ }
179
+ });
180
+ cfg.destinations.filter((d) => d.type == 'akamai').forEach((d, i) => {
181
+ const id = `akamai-${i}-${cfg.publishingGroup}`;
182
+ const url = new URL(d.ingest);
183
+ ret.destinations.push({
184
+ id,
185
+ type: 'generic',
186
+ host: url.host,
187
+ port: url.port ? parseInt(url.port, 10) : 80,
188
+ pathPrefix: url.pathname.endsWith("/") ? url.pathname : `${url.pathname}/`,
189
+ retentionPeriodSeconds: cfg.segments.retentionPeriod,
190
+ });
191
+ if (d.includeAdInsertions) {
192
+ ret.advertDestinations.push(id);
193
+ }
194
+ });
195
+ ret.advertDestinations.push('local');
196
+ return ret;
197
+ }
198
+ //# sourceMappingURL=cmaf.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cmaf.js","sourceRoot":"","sources":["../../src/shared/cmaf.ts"],"names":[],"mappings":";;;;;;AAiJA,8CA+DC;AAhND,sFAAyH;AACzH,+DAAyE;AACzE,8CAAmB;AAEnB,kFAA6E;AAMhE,QAAA,gBAAgB,GAAmC;IAC9D,IAAI,EAAE,gCAAgC;IACtC,IAAI,EAAE;QACJ,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,0CAAoB;QAC1B,WAAW,EAAE,IAAI;QACjB,IAAI,EAAE;YACJ,eAAe,EAAE;gBACf,IAAI,EAAE,oEAAoE;gBAC1E,IAAI,EAAE;oBACJ,IAAI,EAAE,SAAS;oBACf,YAAY,EAAE,EAAE;oBAChB,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC;iBACzC;aACF;YACD,mBAAmB,EAAE;gBACnB,IAAI,EAAE,uEAAuE;gBAC7E,IAAI,EAAE;oBACJ,IAAI,EAAE,SAAS;oBACf,YAAY,EAAE,CAAC;oBACf,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;iBACvB;aACF;YACD,qBAAqB,EAAE;gBACrB,IAAI,EAAE,4CAA4C;gBAClD,IAAI,EAAE;oBACJ,IAAI,EAAE,SAAS;oBACf,YAAY,EAAE,GAAG;oBACjB,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC;iBACtC;aACF;YACD,kBAAkB,EAAE;gBAClB,IAAI,EAAE,2EAA2E;gBACjF,IAAI,EAAE;oBACJ,IAAI,EAAE,SAAS;o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kB,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IACrC,OAAO,GAAG,CAAC;AACb,CAAC"}
@@ -1,3 +1,3 @@
1
- import type { AutoCmafDestination, AutoCmafSegment } from "./runtime";
1
+ import type { Destination as AutoCmafDestination, Segment as AutoCmafSegment } from "./cmaf";
2
2
  export declare function Destination(destination: AutoCmafDestination): import("react/jsx-runtime").JSX.Element;
3
3
  export declare function SegmentConfiguration(cfg: AutoCmafSegment): import("react/jsx-runtime").JSX.Element;
@@ -19,4 +19,4 @@ function Destination(destination) {
19
19
  function SegmentConfiguration(cfg) {
20
20
  return (0, jsx_runtime_1.jsxs)("div", { className: "grid grid-flow-row-dense grid-cols-3 text-sm", children: [(0, jsx_runtime_1.jsx)("div", { className: "col-span-1", children: "Segments" }), (0, jsx_runtime_1.jsx)("div", { className: "col-span-2", children: cfg.defaultSegmentCount == 0 ? "all" : cfg.defaultSegmentCount }), (0, jsx_runtime_1.jsx)("div", { className: "col-span-1", children: "Segment Target" }), (0, jsx_runtime_1.jsxs)("div", { className: "col-span-2", children: [cfg.targetSegmentDuration, "s"] }), (0, jsx_runtime_1.jsx)("div", { className: "col-span-1", children: "Part Target" }), (0, jsx_runtime_1.jsxs)("div", { className: "col-span-2", children: [cfg.targetPartDuration, "s"] }), (0, jsx_runtime_1.jsx)("div", { className: "col-span-1", children: "Retention" }), (0, jsx_runtime_1.jsxs)("div", { className: "col-span-2", children: [cfg.retentionPeriod, "s"] })] });
21
21
  }
22
- //# sourceMappingURL=form-views.js.map
22
+ //# sourceMappingURL=playlist-form-views.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"playlist-form-views.js","sourceRoot":"","sources":["../../src/shared/playlist-form-views.tsx"],"names":[],"mappings":";;AAEA,kCAgCC;AAED,oDAcC;;AAhDD,SAAgB,WAAW,CAAC,WAAgC;IAC1D,QAAQ,WAAW,CAAC,IAAI,EAAE,CAAC;QACzB,KAAK,IAAI;YACP,OAAO,iCAAK,SAAS,EAAC,8CAA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