@stinkycomputing/sesame-api-client 1.9.0-alpha.1 → 1.10.0-alpha.2

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/index.mjs CHANGED
@@ -6017,6 +6017,7 @@ var sesame = $root.sesame = (() => {
6017
6017
  values[valuesById[8] = "SOURCE_TYPE_SRT_STREAM"] = 8;
6018
6018
  values[valuesById[9] = "SOURCE_TYPE_WEBSOCKET"] = 9;
6019
6019
  values[valuesById[10] = "SOURCE_TYPE_MOQ"] = 10;
6020
+ values[valuesById[11] = "SOURCE_TYPE_SCOPE"] = 11;
6020
6021
  return values;
6021
6022
  }();
6022
6023
  sources.DeinterlaceType = function() {
@@ -6067,9 +6068,9 @@ var sesame = $root.sesame = (() => {
6067
6068
  sources.PreprocessStep = function() {
6068
6069
  const valuesById = {}, values = Object.create(valuesById);
6069
6070
  values[valuesById[0] = "PREPROCESS_STEP_UNSPECIFIED"] = 0;
6070
- values[valuesById[1] = "PREPROCESS_STEP_VIDEO_SCOPES"] = 1;
6071
6071
  values[valuesById[2] = "PREPROCESS_STEP_CHROMA_KEY"] = 2;
6072
6072
  values[valuesById[3] = "PREPROCESS_STEP_BLUR"] = 3;
6073
+ values[valuesById[4] = "PREPROCESS_STEP_COLOR_CORRECT"] = 4;
6073
6074
  return values;
6074
6075
  }();
6075
6076
  sources.VideoProcessorParam = function() {
@@ -6266,9 +6267,9 @@ var sesame = $root.sesame = (() => {
6266
6267
  default:
6267
6268
  return "type: enum value expected";
6268
6269
  case 0:
6269
- case 1:
6270
6270
  case 2:
6271
6271
  case 3:
6272
+ case 4:
6272
6273
  break;
6273
6274
  }
6274
6275
  if (message.params != null && message.hasOwnProperty("params")) {
@@ -6299,10 +6300,6 @@ var sesame = $root.sesame = (() => {
6299
6300
  case 0:
6300
6301
  message.type = 0;
6301
6302
  break;
6302
- case "PREPROCESS_STEP_VIDEO_SCOPES":
6303
- case 1:
6304
- message.type = 1;
6305
- break;
6306
6303
  case "PREPROCESS_STEP_CHROMA_KEY":
6307
6304
  case 2:
6308
6305
  message.type = 2;
@@ -6311,6 +6308,10 @@ var sesame = $root.sesame = (() => {
6311
6308
  case 3:
6312
6309
  message.type = 3;
6313
6310
  break;
6311
+ case "PREPROCESS_STEP_COLOR_CORRECT":
6312
+ case 4:
6313
+ message.type = 4;
6314
+ break;
6314
6315
  }
6315
6316
  if (object.params) {
6316
6317
  if (!Array.isArray(object.params))
@@ -7255,6 +7256,175 @@ var sesame = $root.sesame = (() => {
7255
7256
  };
7256
7257
  return RTTSourceConfig;
7257
7258
  }();
7259
+ sources.ScopeMode = function() {
7260
+ const valuesById = {}, values = Object.create(valuesById);
7261
+ values[valuesById[0] = "SCOPE_MODE_UNSPECIFIED"] = 0;
7262
+ values[valuesById[1] = "SCOPE_MODE_WAVEFORM"] = 1;
7263
+ values[valuesById[2] = "SCOPE_MODE_RGB_PARADE"] = 2;
7264
+ values[valuesById[3] = "SCOPE_MODE_VECTORSCOPE"] = 3;
7265
+ values[valuesById[4] = "SCOPE_MODE_AUDIO_PHASE"] = 4;
7266
+ return values;
7267
+ }();
7268
+ sources.ScopeSourceConfig = function() {
7269
+ function ScopeSourceConfig(properties) {
7270
+ if (properties) {
7271
+ for (let keys = Object.keys(properties), i = 0; i < keys.length; ++i)
7272
+ if (properties[keys[i]] != null)
7273
+ this[keys[i]] = properties[keys[i]];
7274
+ }
7275
+ }
7276
+ ScopeSourceConfig.prototype.compositorId = "";
7277
+ ScopeSourceConfig.prototype.audioMix = "";
7278
+ ScopeSourceConfig.prototype.mode = 0;
7279
+ ScopeSourceConfig.create = function create(properties) {
7280
+ return new ScopeSourceConfig(properties);
7281
+ };
7282
+ ScopeSourceConfig.encode = function encode(message, writer) {
7283
+ if (!writer)
7284
+ writer = $Writer.create();
7285
+ if (message.compositorId != null && Object.hasOwnProperty.call(message, "compositorId"))
7286
+ writer.uint32(
7287
+ /* id 1, wireType 2 =*/
7288
+ 10
7289
+ ).string(message.compositorId);
7290
+ if (message.audioMix != null && Object.hasOwnProperty.call(message, "audioMix"))
7291
+ writer.uint32(
7292
+ /* id 2, wireType 2 =*/
7293
+ 18
7294
+ ).string(message.audioMix);
7295
+ if (message.mode != null && Object.hasOwnProperty.call(message, "mode"))
7296
+ writer.uint32(
7297
+ /* id 3, wireType 0 =*/
7298
+ 24
7299
+ ).int32(message.mode);
7300
+ return writer;
7301
+ };
7302
+ ScopeSourceConfig.encodeDelimited = function encodeDelimited(message, writer) {
7303
+ return this.encode(message, writer).ldelim();
7304
+ };
7305
+ ScopeSourceConfig.decode = function decode(reader, length, error) {
7306
+ if (!(reader instanceof $Reader))
7307
+ reader = $Reader.create(reader);
7308
+ let end = length === void 0 ? reader.len : reader.pos + length, message = new $root.sesame.v1.sources.ScopeSourceConfig();
7309
+ while (reader.pos < end) {
7310
+ let tag = reader.uint32();
7311
+ if (tag === error)
7312
+ break;
7313
+ switch (tag >>> 3) {
7314
+ case 1: {
7315
+ message.compositorId = reader.string();
7316
+ break;
7317
+ }
7318
+ case 2: {
7319
+ message.audioMix = reader.string();
7320
+ break;
7321
+ }
7322
+ case 3: {
7323
+ message.mode = reader.int32();
7324
+ break;
7325
+ }
7326
+ default:
7327
+ reader.skipType(tag & 7);
7328
+ break;
7329
+ }
7330
+ }
7331
+ return message;
7332
+ };
7333
+ ScopeSourceConfig.decodeDelimited = function decodeDelimited(reader) {
7334
+ if (!(reader instanceof $Reader))
7335
+ reader = new $Reader(reader);
7336
+ return this.decode(reader, reader.uint32());
7337
+ };
7338
+ ScopeSourceConfig.verify = function verify(message) {
7339
+ if (typeof message !== "object" || message === null)
7340
+ return "object expected";
7341
+ if (message.compositorId != null && message.hasOwnProperty("compositorId")) {
7342
+ if (!$util.isString(message.compositorId))
7343
+ return "compositorId: string expected";
7344
+ }
7345
+ if (message.audioMix != null && message.hasOwnProperty("audioMix")) {
7346
+ if (!$util.isString(message.audioMix))
7347
+ return "audioMix: string expected";
7348
+ }
7349
+ if (message.mode != null && message.hasOwnProperty("mode"))
7350
+ switch (message.mode) {
7351
+ default:
7352
+ return "mode: enum value expected";
7353
+ case 0:
7354
+ case 1:
7355
+ case 2:
7356
+ case 3:
7357
+ case 4:
7358
+ break;
7359
+ }
7360
+ return null;
7361
+ };
7362
+ ScopeSourceConfig.fromObject = function fromObject(object) {
7363
+ if (object instanceof $root.sesame.v1.sources.ScopeSourceConfig)
7364
+ return object;
7365
+ let message = new $root.sesame.v1.sources.ScopeSourceConfig();
7366
+ if (object.compositorId != null)
7367
+ message.compositorId = String(object.compositorId);
7368
+ if (object.audioMix != null)
7369
+ message.audioMix = String(object.audioMix);
7370
+ switch (object.mode) {
7371
+ default:
7372
+ if (typeof object.mode === "number") {
7373
+ message.mode = object.mode;
7374
+ break;
7375
+ }
7376
+ break;
7377
+ case "SCOPE_MODE_UNSPECIFIED":
7378
+ case 0:
7379
+ message.mode = 0;
7380
+ break;
7381
+ case "SCOPE_MODE_WAVEFORM":
7382
+ case 1:
7383
+ message.mode = 1;
7384
+ break;
7385
+ case "SCOPE_MODE_RGB_PARADE":
7386
+ case 2:
7387
+ message.mode = 2;
7388
+ break;
7389
+ case "SCOPE_MODE_VECTORSCOPE":
7390
+ case 3:
7391
+ message.mode = 3;
7392
+ break;
7393
+ case "SCOPE_MODE_AUDIO_PHASE":
7394
+ case 4:
7395
+ message.mode = 4;
7396
+ break;
7397
+ }
7398
+ return message;
7399
+ };
7400
+ ScopeSourceConfig.toObject = function toObject(message, options) {
7401
+ if (!options)
7402
+ options = {};
7403
+ let object = {};
7404
+ if (options.defaults) {
7405
+ object.compositorId = "";
7406
+ object.audioMix = "";
7407
+ object.mode = options.enums === String ? "SCOPE_MODE_UNSPECIFIED" : 0;
7408
+ }
7409
+ if (message.compositorId != null && message.hasOwnProperty("compositorId"))
7410
+ object.compositorId = message.compositorId;
7411
+ if (message.audioMix != null && message.hasOwnProperty("audioMix"))
7412
+ object.audioMix = message.audioMix;
7413
+ if (message.mode != null && message.hasOwnProperty("mode"))
7414
+ object.mode = options.enums === String ? $root.sesame.v1.sources.ScopeMode[message.mode] === void 0 ? message.mode : $root.sesame.v1.sources.ScopeMode[message.mode] : message.mode;
7415
+ return object;
7416
+ };
7417
+ ScopeSourceConfig.prototype.toJSON = function toJSON() {
7418
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
7419
+ };
7420
+ ScopeSourceConfig.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
7421
+ if (typeUrlPrefix === void 0) {
7422
+ typeUrlPrefix = "type.googleapis.com";
7423
+ }
7424
+ return typeUrlPrefix + "/sesame.v1.sources.ScopeSourceConfig";
7425
+ };
7426
+ return ScopeSourceConfig;
7427
+ }();
7258
7428
  sources.DecklinkSourceConfig = function() {
7259
7429
  function DecklinkSourceConfig(properties) {
7260
7430
  if (properties) {
@@ -8230,9 +8400,10 @@ var sesame = $root.sesame = (() => {
8230
8400
  SourceConfig.prototype.srtStream = null;
8231
8401
  SourceConfig.prototype.websocket = null;
8232
8402
  SourceConfig.prototype.moq = null;
8403
+ SourceConfig.prototype.scope = null;
8233
8404
  let $oneOfFields;
8234
8405
  Object.defineProperty(SourceConfig.prototype, "details", {
8235
- get: $util.oneOfGetter($oneOfFields = ["file", "recorder", "browser", "rtt", "decklink", "signalGenerator", "systemAudio", "srtStream", "websocket", "moq"]),
8406
+ get: $util.oneOfGetter($oneOfFields = ["file", "recorder", "browser", "rtt", "decklink", "signalGenerator", "systemAudio", "srtStream", "websocket", "moq", "scope"]),
8236
8407
  set: $util.oneOfSetter($oneOfFields)
8237
8408
  });
8238
8409
  SourceConfig.create = function create(properties) {
@@ -8296,6 +8467,11 @@ var sesame = $root.sesame = (() => {
8296
8467
  /* id 19, wireType 2 =*/
8297
8468
  154
8298
8469
  ).fork()).ldelim();
8470
+ if (message.scope != null && Object.hasOwnProperty.call(message, "scope"))
8471
+ $root.sesame.v1.sources.ScopeSourceConfig.encode(message.scope, writer.uint32(
8472
+ /* id 20, wireType 2 =*/
8473
+ 162
8474
+ ).fork()).ldelim();
8299
8475
  return writer;
8300
8476
  };
8301
8477
  SourceConfig.encodeDelimited = function encodeDelimited(message, writer) {
@@ -8354,6 +8530,10 @@ var sesame = $root.sesame = (() => {
8354
8530
  message.moq = $root.sesame.v1.sources.MoqSourceConfig.decode(reader, reader.uint32());
8355
8531
  break;
8356
8532
  }
8533
+ case 20: {
8534
+ message.scope = $root.sesame.v1.sources.ScopeSourceConfig.decode(reader, reader.uint32());
8535
+ break;
8536
+ }
8357
8537
  default:
8358
8538
  reader.skipType(tag & 7);
8359
8539
  break;
@@ -8473,6 +8653,16 @@ var sesame = $root.sesame = (() => {
8473
8653
  return "moq." + error;
8474
8654
  }
8475
8655
  }
8656
+ if (message.scope != null && message.hasOwnProperty("scope")) {
8657
+ if (properties.details === 1)
8658
+ return "details: multiple values";
8659
+ properties.details = 1;
8660
+ {
8661
+ let error = $root.sesame.v1.sources.ScopeSourceConfig.verify(message.scope);
8662
+ if (error)
8663
+ return "scope." + error;
8664
+ }
8665
+ }
8476
8666
  return null;
8477
8667
  };
8478
8668
  SourceConfig.fromObject = function fromObject(object) {
@@ -8534,6 +8724,11 @@ var sesame = $root.sesame = (() => {
8534
8724
  throw TypeError(".sesame.v1.sources.SourceConfig.moq: object expected");
8535
8725
  message.moq = $root.sesame.v1.sources.MoqSourceConfig.fromObject(object.moq);
8536
8726
  }
8727
+ if (object.scope != null) {
8728
+ if (typeof object.scope !== "object")
8729
+ throw TypeError(".sesame.v1.sources.SourceConfig.scope: object expected");
8730
+ message.scope = $root.sesame.v1.sources.ScopeSourceConfig.fromObject(object.scope);
8731
+ }
8537
8732
  return message;
8538
8733
  };
8539
8734
  SourceConfig.toObject = function toObject(message, options) {
@@ -8594,6 +8789,11 @@ var sesame = $root.sesame = (() => {
8594
8789
  if (options.oneofs)
8595
8790
  object.details = "moq";
8596
8791
  }
8792
+ if (message.scope != null && message.hasOwnProperty("scope")) {
8793
+ object.scope = $root.sesame.v1.sources.ScopeSourceConfig.toObject(message.scope, options);
8794
+ if (options.oneofs)
8795
+ object.details = "scope";
8796
+ }
8597
8797
  return object;
8598
8798
  };
8599
8799
  SourceConfig.prototype.toJSON = function toJSON() {
@@ -8921,6 +9121,7 @@ var sesame = $root.sesame = (() => {
8921
9121
  }();
8922
9122
  sources.SourceStatus = function() {
8923
9123
  function SourceStatus(properties) {
9124
+ this.videoProcessors = [];
8924
9125
  if (properties) {
8925
9126
  for (let keys = Object.keys(properties), i = 0; i < keys.length; ++i)
8926
9127
  if (properties[keys[i]] != null)
@@ -8948,6 +9149,7 @@ var sesame = $root.sesame = (() => {
8948
9149
  SourceStatus.prototype.decodeTiming = null;
8949
9150
  SourceStatus.prototype.videoBufAvg = 0;
8950
9151
  SourceStatus.prototype.srtStats = null;
9152
+ SourceStatus.prototype.videoProcessors = $util.emptyArray;
8951
9153
  let $oneOfFields;
8952
9154
  Object.defineProperty(SourceStatus.prototype, "_msg", {
8953
9155
  get: $util.oneOfGetter($oneOfFields = ["msg"]),
@@ -9068,6 +9270,12 @@ var sesame = $root.sesame = (() => {
9068
9270
  /* id 21, wireType 2 =*/
9069
9271
  170
9070
9272
  ).fork()).ldelim();
9273
+ if (message.videoProcessors != null && message.videoProcessors.length)
9274
+ for (let i = 0; i < message.videoProcessors.length; ++i)
9275
+ $root.sesame.v1.sources.VideoProcessor.encode(message.videoProcessors[i], writer.uint32(
9276
+ /* id 22, wireType 2 =*/
9277
+ 178
9278
+ ).fork()).ldelim();
9071
9279
  return writer;
9072
9280
  };
9073
9281
  SourceStatus.encodeDelimited = function encodeDelimited(message, writer) {
@@ -9166,6 +9374,12 @@ var sesame = $root.sesame = (() => {
9166
9374
  message.srtStats = $root.sesame.v1.status.SRTReceiveStatistics.decode(reader, reader.uint32());
9167
9375
  break;
9168
9376
  }
9377
+ case 22: {
9378
+ if (!(message.videoProcessors && message.videoProcessors.length))
9379
+ message.videoProcessors = [];
9380
+ message.videoProcessors.push($root.sesame.v1.sources.VideoProcessor.decode(reader, reader.uint32()));
9381
+ break;
9382
+ }
9169
9383
  default:
9170
9384
  reader.skipType(tag & 7);
9171
9385
  break;
@@ -9201,6 +9415,7 @@ var sesame = $root.sesame = (() => {
9201
9415
  case 8:
9202
9416
  case 9:
9203
9417
  case 10:
9418
+ case 11:
9204
9419
  break;
9205
9420
  }
9206
9421
  if (message.userId != null && message.hasOwnProperty("userId")) {
@@ -9302,6 +9517,15 @@ var sesame = $root.sesame = (() => {
9302
9517
  return "srtStats." + error;
9303
9518
  }
9304
9519
  }
9520
+ if (message.videoProcessors != null && message.hasOwnProperty("videoProcessors")) {
9521
+ if (!Array.isArray(message.videoProcessors))
9522
+ return "videoProcessors: array expected";
9523
+ for (let i = 0; i < message.videoProcessors.length; ++i) {
9524
+ let error = $root.sesame.v1.sources.VideoProcessor.verify(message.videoProcessors[i]);
9525
+ if (error)
9526
+ return "videoProcessors." + error;
9527
+ }
9528
+ }
9305
9529
  return null;
9306
9530
  };
9307
9531
  SourceStatus.fromObject = function fromObject(object) {
@@ -9361,6 +9585,10 @@ var sesame = $root.sesame = (() => {
9361
9585
  case 10:
9362
9586
  message.type = 10;
9363
9587
  break;
9588
+ case "SOURCE_TYPE_SCOPE":
9589
+ case 11:
9590
+ message.type = 11;
9591
+ break;
9364
9592
  }
9365
9593
  if (object.userId != null)
9366
9594
  message.userId = String(object.userId);
@@ -9494,12 +9722,24 @@ var sesame = $root.sesame = (() => {
9494
9722
  throw TypeError(".sesame.v1.sources.SourceStatus.srtStats: object expected");
9495
9723
  message.srtStats = $root.sesame.v1.status.SRTReceiveStatistics.fromObject(object.srtStats);
9496
9724
  }
9725
+ if (object.videoProcessors) {
9726
+ if (!Array.isArray(object.videoProcessors))
9727
+ throw TypeError(".sesame.v1.sources.SourceStatus.videoProcessors: array expected");
9728
+ message.videoProcessors = [];
9729
+ for (let i = 0; i < object.videoProcessors.length; ++i) {
9730
+ if (typeof object.videoProcessors[i] !== "object")
9731
+ throw TypeError(".sesame.v1.sources.SourceStatus.videoProcessors: object expected");
9732
+ message.videoProcessors[i] = $root.sesame.v1.sources.VideoProcessor.fromObject(object.videoProcessors[i]);
9733
+ }
9734
+ }
9497
9735
  return message;
9498
9736
  };
9499
9737
  SourceStatus.toObject = function toObject(message, options) {
9500
9738
  if (!options)
9501
9739
  options = {};
9502
9740
  let object = {};
9741
+ if (options.arrays || options.defaults)
9742
+ object.videoProcessors = [];
9503
9743
  if (options.defaults) {
9504
9744
  object.id = "";
9505
9745
  object.type = options.enums === String ? "SOURCE_TYPE_UNSPECIFIED" : 0;
@@ -9590,6 +9830,11 @@ var sesame = $root.sesame = (() => {
9590
9830
  if (options.oneofs)
9591
9831
  object._srtStats = "srtStats";
9592
9832
  }
9833
+ if (message.videoProcessors && message.videoProcessors.length) {
9834
+ object.videoProcessors = [];
9835
+ for (let j = 0; j < message.videoProcessors.length; ++j)
9836
+ object.videoProcessors[j] = $root.sesame.v1.sources.VideoProcessor.toObject(message.videoProcessors[j], options);
9837
+ }
9593
9838
  return object;
9594
9839
  };
9595
9840
  SourceStatus.prototype.toJSON = function toJSON() {
@@ -10929,6 +11174,325 @@ var sesame = $root.sesame = (() => {
10929
11174
  };
10930
11175
  return TransportControlRequest;
10931
11176
  }();
11177
+ sources.VideoProcessorControlRequest = function() {
11178
+ function VideoProcessorControlRequest(properties) {
11179
+ this.params = [];
11180
+ if (properties) {
11181
+ for (let keys = Object.keys(properties), i = 0; i < keys.length; ++i)
11182
+ if (properties[keys[i]] != null)
11183
+ this[keys[i]] = properties[keys[i]];
11184
+ }
11185
+ }
11186
+ VideoProcessorControlRequest.prototype.processorId = "";
11187
+ VideoProcessorControlRequest.prototype.params = $util.emptyArray;
11188
+ VideoProcessorControlRequest.create = function create(properties) {
11189
+ return new VideoProcessorControlRequest(properties);
11190
+ };
11191
+ VideoProcessorControlRequest.encode = function encode(message, writer) {
11192
+ if (!writer)
11193
+ writer = $Writer.create();
11194
+ if (message.processorId != null && Object.hasOwnProperty.call(message, "processorId"))
11195
+ writer.uint32(
11196
+ /* id 1, wireType 2 =*/
11197
+ 10
11198
+ ).string(message.processorId);
11199
+ if (message.params != null && message.params.length)
11200
+ for (let i = 0; i < message.params.length; ++i)
11201
+ $root.sesame.v1.sources.VideoProcessorParam.encode(message.params[i], writer.uint32(
11202
+ /* id 2, wireType 2 =*/
11203
+ 18
11204
+ ).fork()).ldelim();
11205
+ return writer;
11206
+ };
11207
+ VideoProcessorControlRequest.encodeDelimited = function encodeDelimited(message, writer) {
11208
+ return this.encode(message, writer).ldelim();
11209
+ };
11210
+ VideoProcessorControlRequest.decode = function decode(reader, length, error) {
11211
+ if (!(reader instanceof $Reader))
11212
+ reader = $Reader.create(reader);
11213
+ let end = length === void 0 ? reader.len : reader.pos + length, message = new $root.sesame.v1.sources.VideoProcessorControlRequest();
11214
+ while (reader.pos < end) {
11215
+ let tag = reader.uint32();
11216
+ if (tag === error)
11217
+ break;
11218
+ switch (tag >>> 3) {
11219
+ case 1: {
11220
+ message.processorId = reader.string();
11221
+ break;
11222
+ }
11223
+ case 2: {
11224
+ if (!(message.params && message.params.length))
11225
+ message.params = [];
11226
+ message.params.push($root.sesame.v1.sources.VideoProcessorParam.decode(reader, reader.uint32()));
11227
+ break;
11228
+ }
11229
+ default:
11230
+ reader.skipType(tag & 7);
11231
+ break;
11232
+ }
11233
+ }
11234
+ return message;
11235
+ };
11236
+ VideoProcessorControlRequest.decodeDelimited = function decodeDelimited(reader) {
11237
+ if (!(reader instanceof $Reader))
11238
+ reader = new $Reader(reader);
11239
+ return this.decode(reader, reader.uint32());
11240
+ };
11241
+ VideoProcessorControlRequest.verify = function verify(message) {
11242
+ if (typeof message !== "object" || message === null)
11243
+ return "object expected";
11244
+ if (message.processorId != null && message.hasOwnProperty("processorId")) {
11245
+ if (!$util.isString(message.processorId))
11246
+ return "processorId: string expected";
11247
+ }
11248
+ if (message.params != null && message.hasOwnProperty("params")) {
11249
+ if (!Array.isArray(message.params))
11250
+ return "params: array expected";
11251
+ for (let i = 0; i < message.params.length; ++i) {
11252
+ let error = $root.sesame.v1.sources.VideoProcessorParam.verify(message.params[i]);
11253
+ if (error)
11254
+ return "params." + error;
11255
+ }
11256
+ }
11257
+ return null;
11258
+ };
11259
+ VideoProcessorControlRequest.fromObject = function fromObject(object) {
11260
+ if (object instanceof $root.sesame.v1.sources.VideoProcessorControlRequest)
11261
+ return object;
11262
+ let message = new $root.sesame.v1.sources.VideoProcessorControlRequest();
11263
+ if (object.processorId != null)
11264
+ message.processorId = String(object.processorId);
11265
+ if (object.params) {
11266
+ if (!Array.isArray(object.params))
11267
+ throw TypeError(".sesame.v1.sources.VideoProcessorControlRequest.params: array expected");
11268
+ message.params = [];
11269
+ for (let i = 0; i < object.params.length; ++i) {
11270
+ if (typeof object.params[i] !== "object")
11271
+ throw TypeError(".sesame.v1.sources.VideoProcessorControlRequest.params: object expected");
11272
+ message.params[i] = $root.sesame.v1.sources.VideoProcessorParam.fromObject(object.params[i]);
11273
+ }
11274
+ }
11275
+ return message;
11276
+ };
11277
+ VideoProcessorControlRequest.toObject = function toObject(message, options) {
11278
+ if (!options)
11279
+ options = {};
11280
+ let object = {};
11281
+ if (options.arrays || options.defaults)
11282
+ object.params = [];
11283
+ if (options.defaults)
11284
+ object.processorId = "";
11285
+ if (message.processorId != null && message.hasOwnProperty("processorId"))
11286
+ object.processorId = message.processorId;
11287
+ if (message.params && message.params.length) {
11288
+ object.params = [];
11289
+ for (let j = 0; j < message.params.length; ++j)
11290
+ object.params[j] = $root.sesame.v1.sources.VideoProcessorParam.toObject(message.params[j], options);
11291
+ }
11292
+ return object;
11293
+ };
11294
+ VideoProcessorControlRequest.prototype.toJSON = function toJSON() {
11295
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
11296
+ };
11297
+ VideoProcessorControlRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
11298
+ if (typeUrlPrefix === void 0) {
11299
+ typeUrlPrefix = "type.googleapis.com";
11300
+ }
11301
+ return typeUrlPrefix + "/sesame.v1.sources.VideoProcessorControlRequest";
11302
+ };
11303
+ return VideoProcessorControlRequest;
11304
+ }();
11305
+ sources.SourceControlRequest = function() {
11306
+ function SourceControlRequest(properties) {
11307
+ this.videoProcessors = [];
11308
+ this.resetProcessors = [];
11309
+ if (properties) {
11310
+ for (let keys = Object.keys(properties), i = 0; i < keys.length; ++i)
11311
+ if (properties[keys[i]] != null)
11312
+ this[keys[i]] = properties[keys[i]];
11313
+ }
11314
+ }
11315
+ SourceControlRequest.prototype.videoProcessors = $util.emptyArray;
11316
+ SourceControlRequest.prototype.audioLevel = null;
11317
+ SourceControlRequest.prototype.resetProcessors = $util.emptyArray;
11318
+ SourceControlRequest.prototype.sourceId = "";
11319
+ let $oneOfFields;
11320
+ Object.defineProperty(SourceControlRequest.prototype, "_audioLevel", {
11321
+ get: $util.oneOfGetter($oneOfFields = ["audioLevel"]),
11322
+ set: $util.oneOfSetter($oneOfFields)
11323
+ });
11324
+ SourceControlRequest.create = function create(properties) {
11325
+ return new SourceControlRequest(properties);
11326
+ };
11327
+ SourceControlRequest.encode = function encode(message, writer) {
11328
+ if (!writer)
11329
+ writer = $Writer.create();
11330
+ if (message.videoProcessors != null && message.videoProcessors.length)
11331
+ for (let i = 0; i < message.videoProcessors.length; ++i)
11332
+ $root.sesame.v1.sources.VideoProcessorControlRequest.encode(message.videoProcessors[i], writer.uint32(
11333
+ /* id 1, wireType 2 =*/
11334
+ 10
11335
+ ).fork()).ldelim();
11336
+ if (message.audioLevel != null && Object.hasOwnProperty.call(message, "audioLevel"))
11337
+ writer.uint32(
11338
+ /* id 2, wireType 5 =*/
11339
+ 21
11340
+ ).float(message.audioLevel);
11341
+ if (message.resetProcessors != null && message.resetProcessors.length)
11342
+ for (let i = 0; i < message.resetProcessors.length; ++i)
11343
+ writer.uint32(
11344
+ /* id 3, wireType 2 =*/
11345
+ 26
11346
+ ).string(message.resetProcessors[i]);
11347
+ if (message.sourceId != null && Object.hasOwnProperty.call(message, "sourceId"))
11348
+ writer.uint32(
11349
+ /* id 4, wireType 2 =*/
11350
+ 34
11351
+ ).string(message.sourceId);
11352
+ return writer;
11353
+ };
11354
+ SourceControlRequest.encodeDelimited = function encodeDelimited(message, writer) {
11355
+ return this.encode(message, writer).ldelim();
11356
+ };
11357
+ SourceControlRequest.decode = function decode(reader, length, error) {
11358
+ if (!(reader instanceof $Reader))
11359
+ reader = $Reader.create(reader);
11360
+ let end = length === void 0 ? reader.len : reader.pos + length, message = new $root.sesame.v1.sources.SourceControlRequest();
11361
+ while (reader.pos < end) {
11362
+ let tag = reader.uint32();
11363
+ if (tag === error)
11364
+ break;
11365
+ switch (tag >>> 3) {
11366
+ case 1: {
11367
+ if (!(message.videoProcessors && message.videoProcessors.length))
11368
+ message.videoProcessors = [];
11369
+ message.videoProcessors.push($root.sesame.v1.sources.VideoProcessorControlRequest.decode(reader, reader.uint32()));
11370
+ break;
11371
+ }
11372
+ case 2: {
11373
+ message.audioLevel = reader.float();
11374
+ break;
11375
+ }
11376
+ case 3: {
11377
+ if (!(message.resetProcessors && message.resetProcessors.length))
11378
+ message.resetProcessors = [];
11379
+ message.resetProcessors.push(reader.string());
11380
+ break;
11381
+ }
11382
+ case 4: {
11383
+ message.sourceId = reader.string();
11384
+ break;
11385
+ }
11386
+ default:
11387
+ reader.skipType(tag & 7);
11388
+ break;
11389
+ }
11390
+ }
11391
+ return message;
11392
+ };
11393
+ SourceControlRequest.decodeDelimited = function decodeDelimited(reader) {
11394
+ if (!(reader instanceof $Reader))
11395
+ reader = new $Reader(reader);
11396
+ return this.decode(reader, reader.uint32());
11397
+ };
11398
+ SourceControlRequest.verify = function verify(message) {
11399
+ if (typeof message !== "object" || message === null)
11400
+ return "object expected";
11401
+ let properties = {};
11402
+ if (message.videoProcessors != null && message.hasOwnProperty("videoProcessors")) {
11403
+ if (!Array.isArray(message.videoProcessors))
11404
+ return "videoProcessors: array expected";
11405
+ for (let i = 0; i < message.videoProcessors.length; ++i) {
11406
+ let error = $root.sesame.v1.sources.VideoProcessorControlRequest.verify(message.videoProcessors[i]);
11407
+ if (error)
11408
+ return "videoProcessors." + error;
11409
+ }
11410
+ }
11411
+ if (message.audioLevel != null && message.hasOwnProperty("audioLevel")) {
11412
+ properties._audioLevel = 1;
11413
+ if (typeof message.audioLevel !== "number")
11414
+ return "audioLevel: number expected";
11415
+ }
11416
+ if (message.resetProcessors != null && message.hasOwnProperty("resetProcessors")) {
11417
+ if (!Array.isArray(message.resetProcessors))
11418
+ return "resetProcessors: array expected";
11419
+ for (let i = 0; i < message.resetProcessors.length; ++i)
11420
+ if (!$util.isString(message.resetProcessors[i]))
11421
+ return "resetProcessors: string[] expected";
11422
+ }
11423
+ if (message.sourceId != null && message.hasOwnProperty("sourceId")) {
11424
+ if (!$util.isString(message.sourceId))
11425
+ return "sourceId: string expected";
11426
+ }
11427
+ return null;
11428
+ };
11429
+ SourceControlRequest.fromObject = function fromObject(object) {
11430
+ if (object instanceof $root.sesame.v1.sources.SourceControlRequest)
11431
+ return object;
11432
+ let message = new $root.sesame.v1.sources.SourceControlRequest();
11433
+ if (object.videoProcessors) {
11434
+ if (!Array.isArray(object.videoProcessors))
11435
+ throw TypeError(".sesame.v1.sources.SourceControlRequest.videoProcessors: array expected");
11436
+ message.videoProcessors = [];
11437
+ for (let i = 0; i < object.videoProcessors.length; ++i) {
11438
+ if (typeof object.videoProcessors[i] !== "object")
11439
+ throw TypeError(".sesame.v1.sources.SourceControlRequest.videoProcessors: object expected");
11440
+ message.videoProcessors[i] = $root.sesame.v1.sources.VideoProcessorControlRequest.fromObject(object.videoProcessors[i]);
11441
+ }
11442
+ }
11443
+ if (object.audioLevel != null)
11444
+ message.audioLevel = Number(object.audioLevel);
11445
+ if (object.resetProcessors) {
11446
+ if (!Array.isArray(object.resetProcessors))
11447
+ throw TypeError(".sesame.v1.sources.SourceControlRequest.resetProcessors: array expected");
11448
+ message.resetProcessors = [];
11449
+ for (let i = 0; i < object.resetProcessors.length; ++i)
11450
+ message.resetProcessors[i] = String(object.resetProcessors[i]);
11451
+ }
11452
+ if (object.sourceId != null)
11453
+ message.sourceId = String(object.sourceId);
11454
+ return message;
11455
+ };
11456
+ SourceControlRequest.toObject = function toObject(message, options) {
11457
+ if (!options)
11458
+ options = {};
11459
+ let object = {};
11460
+ if (options.arrays || options.defaults) {
11461
+ object.videoProcessors = [];
11462
+ object.resetProcessors = [];
11463
+ }
11464
+ if (options.defaults)
11465
+ object.sourceId = "";
11466
+ if (message.videoProcessors && message.videoProcessors.length) {
11467
+ object.videoProcessors = [];
11468
+ for (let j = 0; j < message.videoProcessors.length; ++j)
11469
+ object.videoProcessors[j] = $root.sesame.v1.sources.VideoProcessorControlRequest.toObject(message.videoProcessors[j], options);
11470
+ }
11471
+ if (message.audioLevel != null && message.hasOwnProperty("audioLevel")) {
11472
+ object.audioLevel = options.json && !isFinite(message.audioLevel) ? String(message.audioLevel) : message.audioLevel;
11473
+ if (options.oneofs)
11474
+ object._audioLevel = "audioLevel";
11475
+ }
11476
+ if (message.resetProcessors && message.resetProcessors.length) {
11477
+ object.resetProcessors = [];
11478
+ for (let j = 0; j < message.resetProcessors.length; ++j)
11479
+ object.resetProcessors[j] = message.resetProcessors[j];
11480
+ }
11481
+ if (message.sourceId != null && message.hasOwnProperty("sourceId"))
11482
+ object.sourceId = message.sourceId;
11483
+ return object;
11484
+ };
11485
+ SourceControlRequest.prototype.toJSON = function toJSON() {
11486
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
11487
+ };
11488
+ SourceControlRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
11489
+ if (typeUrlPrefix === void 0) {
11490
+ typeUrlPrefix = "type.googleapis.com";
11491
+ }
11492
+ return typeUrlPrefix + "/sesame.v1.sources.SourceControlRequest";
11493
+ };
11494
+ return SourceControlRequest;
11495
+ }();
10932
11496
  return sources;
10933
11497
  }();
10934
11498
  v1.recorder = function() {
@@ -26600,6 +27164,8 @@ var sesame = $root.sesame = (() => {
26600
27164
  case 7:
26601
27165
  case 8:
26602
27166
  case 9:
27167
+ case 10:
27168
+ case 11:
26603
27169
  break;
26604
27170
  }
26605
27171
  return null;
@@ -26665,6 +27231,14 @@ var sesame = $root.sesame = (() => {
26665
27231
  case 9:
26666
27232
  message.dataType = 9;
26667
27233
  break;
27234
+ case "DATA_TYPE_SOURCE_CONTROL":
27235
+ case 10:
27236
+ message.dataType = 10;
27237
+ break;
27238
+ case "DATA_TYPE_SOURCE_STATUS":
27239
+ case 11:
27240
+ message.dataType = 11;
27241
+ break;
26668
27242
  }
26669
27243
  return message;
26670
27244
  };
@@ -27383,6 +27957,8 @@ var sesame = $root.sesame = (() => {
27383
27957
  values[valuesById[7] = "DATA_TYPE_OUTPUT_STATUS"] = 7;
27384
27958
  values[valuesById[8] = "DATA_TYPE_OUTPUT_CONTROL"] = 8;
27385
27959
  values[valuesById[9] = "DATA_TYPE_ENGINE_STATUS"] = 9;
27960
+ values[valuesById[10] = "DATA_TYPE_SOURCE_CONTROL"] = 10;
27961
+ values[valuesById[11] = "DATA_TYPE_SOURCE_STATUS"] = 11;
27386
27962
  return values;
27387
27963
  }();
27388
27964
  wire.DataFrameData = function() {
@@ -27462,6 +28038,8 @@ var sesame = $root.sesame = (() => {
27462
28038
  case 7:
27463
28039
  case 8:
27464
28040
  case 9:
28041
+ case 10:
28042
+ case 11:
27465
28043
  break;
27466
28044
  }
27467
28045
  if (message.trackName != null && message.hasOwnProperty("trackName")) {
@@ -27521,6 +28099,14 @@ var sesame = $root.sesame = (() => {
27521
28099
  case 9:
27522
28100
  message.dataType = 9;
27523
28101
  break;
28102
+ case "DATA_TYPE_SOURCE_CONTROL":
28103
+ case 10:
28104
+ message.dataType = 10;
28105
+ break;
28106
+ case "DATA_TYPE_SOURCE_STATUS":
28107
+ case 11:
28108
+ message.dataType = 11;
28109
+ break;
27524
28110
  }
27525
28111
  if (object.trackName != null)
27526
28112
  message.trackName = String(object.trackName);
@@ -28271,6 +28857,16 @@ function buildTransportControlFrame(trackName, request) {
28271
28857
  payload
28272
28858
  );
28273
28859
  }
28860
+ function buildSourceControlFrame(trackName, request) {
28861
+ const payload = sesame.v1.sources.SourceControlRequest.encode(request).finish();
28862
+ return WireProtocol.serialize(
28863
+ {
28864
+ type: sesame.v1.wire.FrameType.FRAME_TYPE_DATA,
28865
+ data: { dataType: sesame.v1.wire.DataType.DATA_TYPE_SOURCE_CONTROL, trackName }
28866
+ },
28867
+ payload
28868
+ );
28869
+ }
28274
28870
  function buildBinaryDataFrame(trackName, payload) {
28275
28871
  return WireProtocol.serialize(
28276
28872
  {
@@ -28979,6 +29575,7 @@ export {
28979
29575
  WireProtocol,
28980
29576
  buildAudioControlFrame,
28981
29577
  buildBinaryDataFrame,
29578
+ buildSourceControlFrame,
28982
29579
  buildTransportControlFrame,
28983
29580
  getLogger,
28984
29581
  getSideData,