-
Notifications
You must be signed in to change notification settings - Fork 10
/
StatisticsPerStream.ts
312 lines (272 loc) · 8.59 KB
/
StatisticsPerStream.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
import {map, mapArray} from '../common/Mapper';
import CodecConfigType from './CodecConfigType';
import DolbyVisionPerStreamMode from './DolbyVisionPerStreamMode';
import EncodingMode from './EncodingMode';
import InputFactor from './InputFactor';
import NexGuardABWatermarkingFeature from './NexGuardABWatermarkingFeature';
import PixelFormatBitDepth from './PixelFormatBitDepth';
import PsnrPerStreamMode from './PsnrPerStreamMode';
import StatisticsPerTitleStream from './StatisticsPerTitleStream';
import StatisticsResolution from './StatisticsResolution';
/**
* @export
* @class StatisticsPerStream
*/
export class StatisticsPerStream {
/**
* ID of the stream (required)
* @type {string}
* @memberof StatisticsPerStream
*/
public streamId?: string;
/**
* ID of the condec configuration (required)
* @type {string}
* @memberof StatisticsPerStream
*/
public codecConfigId?: string;
/**
* Multiplier for the encoded minutes. Depends on muxing type. (required)
* @type {number}
* @memberof StatisticsPerStream
*/
public multiplicator?: number;
/**
* Encoded bytes. (required)
* @type {number}
* @memberof StatisticsPerStream
*/
public encodedBytes?: number;
/**
* Length of the stream. (required)
* @type {number}
* @memberof StatisticsPerStream
*/
public encodedSeconds?: number;
/**
* Minutes you will be charged for (billableMinutes = encodedSeconds * multiplicator) (required)
* @type {number}
* @memberof StatisticsPerStream
*/
public billableMinutes?: number;
/**
* Video width, only if video stream
* @type {number}
* @memberof StatisticsPerStream
*/
public width?: number;
/**
* Video height, only if video stream
* @type {number}
* @memberof StatisticsPerStream
*/
public height?: number;
/**
* If it' a video stream this value is the FPS, for audio it's the sample rate. (required)
* @type {number}
* @memberof StatisticsPerStream
*/
public rate?: number;
/**
* Bitrate of the stream (required)
* @type {number}
* @memberof StatisticsPerStream
*/
public bitrate?: number;
/**
* @type {CodecConfigType}
* @memberof StatisticsPerStream
*/
public codec?: CodecConfigType;
/**
* @type {StatisticsResolution}
* @memberof StatisticsPerStream
*/
public resolution?: StatisticsResolution;
/**
* @type {EncodingMode}
* @memberof StatisticsPerStream
*/
public encodingMode?: EncodingMode;
/**
* The output minutes multiplicator for the given encodingMode
* @type {number}
* @memberof StatisticsPerStream
*/
public encodingModeMultiplicator?: number;
/**
* @type {StatisticsPerTitleStream}
* @memberof StatisticsPerStream
*/
public perTitleResultStream?: StatisticsPerTitleStream;
/**
* The output minutes multiplicator for per-title
* @type {number}
* @memberof StatisticsPerStream
*/
public perTitleMultiplicator?: number;
/**
* @type {PsnrPerStreamMode}
* @memberof StatisticsPerStream
*/
public psnrMode?: PsnrPerStreamMode;
/**
* The output minutes multiplicator for psnr streams
* @type {number}
* @memberof StatisticsPerStream
*/
public psnrMultiplicator?: number;
/**
* @type {DolbyVisionPerStreamMode}
* @memberof StatisticsPerStream
*/
public dolbyVisionMode?: DolbyVisionPerStreamMode;
/**
* The output minutes multiplicator for Dolby Vision streams
* @type {number}
* @memberof StatisticsPerStream
*/
public dolbyVisionMultiplicator?: number;
/**
* Name of the preset configuration used for the codec configuration or \"CUSTOM\" if any preset values were overridden
* @type {string}
* @memberof StatisticsPerStream
*/
public preset?: string;
/**
* The output minutes multiplicator for the used codec configuration preset.
* @type {number}
* @memberof StatisticsPerStream
*/
public presetMultiplicator?: number;
/**
* Indicates if the stream was part of a live encoding.
* @type {boolean}
* @memberof StatisticsPerStream
*/
public live?: boolean;
/**
* The output minutes multiplicator for live streams.
* @type {number}
* @memberof StatisticsPerStream
*/
public liveMultiplicator?: number;
/**
* Indicates if an enhanced interlace filter was used.
* @type {boolean}
* @memberof StatisticsPerStream
*/
public enhancedDeinterlace?: boolean;
/**
* The output minutes multiplicator for streams using an enhanced Deinterlace Filter.
* @type {number}
* @memberof StatisticsPerStream
*/
public enhancedDeinterlaceMultiplicator?: number;
/**
* Indicates if the conversion from Dolby Vision to HDR was triggered.
* @type {boolean}
* @memberof StatisticsPerStream
*/
public dolbyVisionToHdr?: boolean;
/**
* The output minutes multiplicator for streams using the conversion from Dolby Vision to HDR.
* @type {number}
* @memberof StatisticsPerStream
*/
public dolbyVisionToHdrMultiplicator?: number;
/**
* Indicates if the conversion from Dolby Vision to SDR was triggered.
* @type {boolean}
* @memberof StatisticsPerStream
*/
public dolbyVisionToSdr?: boolean;
/**
* The output minutes multiplicator for streams using the conversion from Dolby Vision to SDR.
* @type {number}
* @memberof StatisticsPerStream
*/
public dolbyVisionToSdrMultiplicator?: number;
/**
* Indicates if the conversion from HDR10/HLG to SDR was triggered.
* @type {boolean}
* @memberof StatisticsPerStream
*/
public hdrHlgToSdr?: boolean;
/**
* The output minutes multiplicator for streams using the conversion from HDR10/HLG to SDR.
* @type {number}
* @memberof StatisticsPerStream
*/
public hdrHlgToSdrMultiplicator?: number;
/**
* @type {NexGuardABWatermarkingFeature}
* @memberof StatisticsPerStream
*/
public nexGuardABWatermarkingType?: NexGuardABWatermarkingFeature;
/**
* The output minutes multiplicator for streams using a NexGuard A/B Watermarking.
* @type {number}
* @memberof StatisticsPerStream
*/
public nexGuardABWatermarkingMultiplicator?: number;
/**
* @type {PixelFormatBitDepth}
* @memberof StatisticsPerStream
*/
public pixelFormatBitDepth?: PixelFormatBitDepth;
/**
* The output minutes multiplicator for the pixel format bit depth
* @type {number}
* @memberof StatisticsPerStream
*/
public pixelFormatMultiplicator?: number;
/**
* @type {InputFactor}
* @memberof StatisticsPerStream
*/
public inputFactor?: InputFactor;
constructor(obj?: Partial<StatisticsPerStream>) {
if(!obj) {
return;
}
this.streamId = map(obj.streamId);
this.codecConfigId = map(obj.codecConfigId);
this.multiplicator = map(obj.multiplicator);
this.encodedBytes = map(obj.encodedBytes);
this.encodedSeconds = map(obj.encodedSeconds);
this.billableMinutes = map(obj.billableMinutes);
this.width = map(obj.width);
this.height = map(obj.height);
this.rate = map(obj.rate);
this.bitrate = map(obj.bitrate);
this.codec = map(obj.codec);
this.resolution = map(obj.resolution);
this.encodingMode = map(obj.encodingMode);
this.encodingModeMultiplicator = map(obj.encodingModeMultiplicator);
this.perTitleResultStream = map(obj.perTitleResultStream);
this.perTitleMultiplicator = map(obj.perTitleMultiplicator);
this.psnrMode = map(obj.psnrMode);
this.psnrMultiplicator = map(obj.psnrMultiplicator);
this.dolbyVisionMode = map(obj.dolbyVisionMode);
this.dolbyVisionMultiplicator = map(obj.dolbyVisionMultiplicator);
this.preset = map(obj.preset);
this.presetMultiplicator = map(obj.presetMultiplicator);
this.live = map(obj.live);
this.liveMultiplicator = map(obj.liveMultiplicator);
this.enhancedDeinterlace = map(obj.enhancedDeinterlace);
this.enhancedDeinterlaceMultiplicator = map(obj.enhancedDeinterlaceMultiplicator);
this.dolbyVisionToHdr = map(obj.dolbyVisionToHdr);
this.dolbyVisionToHdrMultiplicator = map(obj.dolbyVisionToHdrMultiplicator);
this.dolbyVisionToSdr = map(obj.dolbyVisionToSdr);
this.dolbyVisionToSdrMultiplicator = map(obj.dolbyVisionToSdrMultiplicator);
this.hdrHlgToSdr = map(obj.hdrHlgToSdr);
this.hdrHlgToSdrMultiplicator = map(obj.hdrHlgToSdrMultiplicator);
this.nexGuardABWatermarkingType = map(obj.nexGuardABWatermarkingType);
this.nexGuardABWatermarkingMultiplicator = map(obj.nexGuardABWatermarkingMultiplicator);
this.pixelFormatBitDepth = map(obj.pixelFormatBitDepth);
this.pixelFormatMultiplicator = map(obj.pixelFormatMultiplicator);
this.inputFactor = map(obj.inputFactor, InputFactor);
}
}
export default StatisticsPerStream;