@camstack/addon-matter-broker 0.2.95 → 0.2.96

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/addon.js CHANGED
@@ -20778,6 +20778,14 @@ var NativeCropResultSchema = object({
20778
20778
  * set `encodeJpeg: true`; `bytes` is then absent.
20779
20779
  */
20780
20780
  jpeg: string$2().optional(),
20781
+ /**
20782
+ * The SAME compressed JPEG as `jpeg`, as bytes (D462). Present instead of
20783
+ * `jpeg` when the request set `acceptJpegBytes`; a request that did not gets
20784
+ * `jpeg` exactly as before. MsgPack and the mesh leg both carry binary —
20785
+ * `bytes` above has crossed this boundary as a `Uint8Array` all along — so
20786
+ * base64 was buying nothing but a multi-megabyte string in the relay's heap.
20787
+ */
20788
+ jpegBytes: _instanceof(Uint8Array).optional(),
20781
20789
  width: number().int().positive(),
20782
20790
  height: number().int().positive(),
20783
20791
  /**
@@ -20844,7 +20852,14 @@ var ParkTrackFrameResultSchema = discriminatedUnion("parked", [object({
20844
20852
  })]);
20845
20853
  /** A retrieved parcel — the runner's own JPEG, base64 for the wire. */
20846
20854
  var ParkedTrackFrameSchema = object({
20847
- jpeg: string$2(),
20855
+ /**
20856
+ * Base64 JPEG — the pre-D462 wire. OPTIONAL since D462: a request that set
20857
+ * `acceptJpegBytes` is answered in `jpegBytes` and this is then absent.
20858
+ * Exactly one of the two is present.
20859
+ */
20860
+ jpeg: string$2().optional(),
20861
+ /** The same JPEG as bytes, for a caller that declared it reads them (D462). */
20862
+ jpegBytes: _instanceof(Uint8Array).optional(),
20848
20863
  width: number().int().positive(),
20849
20864
  height: number().int().positive(),
20850
20865
  /** The frame instant the parcel shows (the caller's clock, echoed back). */
@@ -21431,6 +21446,13 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21431
21446
  bbox: NativeCropBboxSchema,
21432
21447
  maxWidth: number().int().positive().optional(),
21433
21448
  /**
21449
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21450
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21451
+ * wire — never assume consent: a pre-D462 caller parses the field as
21452
+ * base64 and bytes would decode to garbage rather than fail.
21453
+ */
21454
+ acceptJpegBytes: boolean().optional(),
21455
+ /**
21434
21456
  * When `true`, the runner encodes the resolved crop to JPEG ON THE
21435
21457
  * OWNING NODE and returns it in `jpeg` (base64) INSTEAD of raw `bytes`.
21436
21458
  * Callers set this for CROSS-NODE fetches (`handle.nodeId` is a remote
@@ -21498,7 +21520,14 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21498
21520
  }), ParkTrackFrameResultSchema, { kind: "mutation" }), method(object({
21499
21521
  deviceId: number(),
21500
21522
  trackId: string$2(),
21501
- kind: ParkedFrameKindSchema
21523
+ kind: ParkedFrameKindSchema,
21524
+ /**
21525
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21526
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21527
+ * wire — never assume consent: a pre-D462 caller parses the field as
21528
+ * base64 and bytes would decode to garbage rather than fail.
21529
+ */
21530
+ acceptJpegBytes: boolean().optional()
21502
21531
  }), ParkedTrackFrameSchema.nullable()), method(object({
21503
21532
  deviceId: number(),
21504
21533
  trackId: string$2()
package/dist/addon.mjs CHANGED
@@ -20776,6 +20776,14 @@ var NativeCropResultSchema = object({
20776
20776
  * set `encodeJpeg: true`; `bytes` is then absent.
20777
20777
  */
20778
20778
  jpeg: string$2().optional(),
20779
+ /**
20780
+ * The SAME compressed JPEG as `jpeg`, as bytes (D462). Present instead of
20781
+ * `jpeg` when the request set `acceptJpegBytes`; a request that did not gets
20782
+ * `jpeg` exactly as before. MsgPack and the mesh leg both carry binary —
20783
+ * `bytes` above has crossed this boundary as a `Uint8Array` all along — so
20784
+ * base64 was buying nothing but a multi-megabyte string in the relay's heap.
20785
+ */
20786
+ jpegBytes: _instanceof(Uint8Array).optional(),
20779
20787
  width: number().int().positive(),
20780
20788
  height: number().int().positive(),
20781
20789
  /**
@@ -20842,7 +20850,14 @@ var ParkTrackFrameResultSchema = discriminatedUnion("parked", [object({
20842
20850
  })]);
20843
20851
  /** A retrieved parcel — the runner's own JPEG, base64 for the wire. */
20844
20852
  var ParkedTrackFrameSchema = object({
20845
- jpeg: string$2(),
20853
+ /**
20854
+ * Base64 JPEG — the pre-D462 wire. OPTIONAL since D462: a request that set
20855
+ * `acceptJpegBytes` is answered in `jpegBytes` and this is then absent.
20856
+ * Exactly one of the two is present.
20857
+ */
20858
+ jpeg: string$2().optional(),
20859
+ /** The same JPEG as bytes, for a caller that declared it reads them (D462). */
20860
+ jpegBytes: _instanceof(Uint8Array).optional(),
20846
20861
  width: number().int().positive(),
20847
20862
  height: number().int().positive(),
20848
20863
  /** The frame instant the parcel shows (the caller's clock, echoed back). */
@@ -21429,6 +21444,13 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21429
21444
  bbox: NativeCropBboxSchema,
21430
21445
  maxWidth: number().int().positive().optional(),
21431
21446
  /**
21447
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21448
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21449
+ * wire — never assume consent: a pre-D462 caller parses the field as
21450
+ * base64 and bytes would decode to garbage rather than fail.
21451
+ */
21452
+ acceptJpegBytes: boolean().optional(),
21453
+ /**
21432
21454
  * When `true`, the runner encodes the resolved crop to JPEG ON THE
21433
21455
  * OWNING NODE and returns it in `jpeg` (base64) INSTEAD of raw `bytes`.
21434
21456
  * Callers set this for CROSS-NODE fetches (`handle.nodeId` is a remote
@@ -21496,7 +21518,14 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21496
21518
  }), ParkTrackFrameResultSchema, { kind: "mutation" }), method(object({
21497
21519
  deviceId: number(),
21498
21520
  trackId: string$2(),
21499
- kind: ParkedFrameKindSchema
21521
+ kind: ParkedFrameKindSchema,
21522
+ /**
21523
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21524
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21525
+ * wire — never assume consent: a pre-D462 caller parses the field as
21526
+ * base64 and bytes would decode to garbage rather than fail.
21527
+ */
21528
+ acceptJpegBytes: boolean().optional()
21500
21529
  }), ParkedTrackFrameSchema.nullable()), method(object({
21501
21530
  deviceId: number(),
21502
21531
  trackId: string$2()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-matter-broker",
3
- "version": "0.2.95",
3
+ "version": "0.2.96",
4
4
  "description": "Matter broker addon for CamStack — owns a Matter fabric (commissioning + the long-lived controller) via the matter.js controller and brokers commissioned Matter nodes into CamStack",
5
5
  "keywords": [
6
6
  "camstack",