@camstack/addon-provider-hikvision 1.2.104 → 1.2.105

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
@@ -21005,6 +21005,14 @@ var NativeCropResultSchema = object({
21005
21005
  * set `encodeJpeg: true`; `bytes` is then absent.
21006
21006
  */
21007
21007
  jpeg: string().optional(),
21008
+ /**
21009
+ * The SAME compressed JPEG as `jpeg`, as bytes (D462). Present instead of
21010
+ * `jpeg` when the request set `acceptJpegBytes`; a request that did not gets
21011
+ * `jpeg` exactly as before. MsgPack and the mesh leg both carry binary —
21012
+ * `bytes` above has crossed this boundary as a `Uint8Array` all along — so
21013
+ * base64 was buying nothing but a multi-megabyte string in the relay's heap.
21014
+ */
21015
+ jpegBytes: _instanceof(Uint8Array).optional(),
21008
21016
  width: number().int().positive(),
21009
21017
  height: number().int().positive(),
21010
21018
  /**
@@ -21071,7 +21079,14 @@ var ParkTrackFrameResultSchema = discriminatedUnion("parked", [object({
21071
21079
  })]);
21072
21080
  /** A retrieved parcel — the runner's own JPEG, base64 for the wire. */
21073
21081
  var ParkedTrackFrameSchema = object({
21074
- jpeg: string(),
21082
+ /**
21083
+ * Base64 JPEG — the pre-D462 wire. OPTIONAL since D462: a request that set
21084
+ * `acceptJpegBytes` is answered in `jpegBytes` and this is then absent.
21085
+ * Exactly one of the two is present.
21086
+ */
21087
+ jpeg: string().optional(),
21088
+ /** The same JPEG as bytes, for a caller that declared it reads them (D462). */
21089
+ jpegBytes: _instanceof(Uint8Array).optional(),
21075
21090
  width: number().int().positive(),
21076
21091
  height: number().int().positive(),
21077
21092
  /** The frame instant the parcel shows (the caller's clock, echoed back). */
@@ -21658,6 +21673,13 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21658
21673
  bbox: NativeCropBboxSchema,
21659
21674
  maxWidth: number().int().positive().optional(),
21660
21675
  /**
21676
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21677
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21678
+ * wire — never assume consent: a pre-D462 caller parses the field as
21679
+ * base64 and bytes would decode to garbage rather than fail.
21680
+ */
21681
+ acceptJpegBytes: boolean().optional(),
21682
+ /**
21661
21683
  * When `true`, the runner encodes the resolved crop to JPEG ON THE
21662
21684
  * OWNING NODE and returns it in `jpeg` (base64) INSTEAD of raw `bytes`.
21663
21685
  * Callers set this for CROSS-NODE fetches (`handle.nodeId` is a remote
@@ -21725,7 +21747,14 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21725
21747
  }), ParkTrackFrameResultSchema, { kind: "mutation" }), method(object({
21726
21748
  deviceId: number(),
21727
21749
  trackId: string(),
21728
- kind: ParkedFrameKindSchema
21750
+ kind: ParkedFrameKindSchema,
21751
+ /**
21752
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21753
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21754
+ * wire — never assume consent: a pre-D462 caller parses the field as
21755
+ * base64 and bytes would decode to garbage rather than fail.
21756
+ */
21757
+ acceptJpegBytes: boolean().optional()
21729
21758
  }), ParkedTrackFrameSchema.nullable()), method(object({
21730
21759
  deviceId: number(),
21731
21760
  trackId: string()
package/dist/addon.mjs CHANGED
@@ -21006,6 +21006,14 @@ var NativeCropResultSchema = object({
21006
21006
  * set `encodeJpeg: true`; `bytes` is then absent.
21007
21007
  */
21008
21008
  jpeg: string().optional(),
21009
+ /**
21010
+ * The SAME compressed JPEG as `jpeg`, as bytes (D462). Present instead of
21011
+ * `jpeg` when the request set `acceptJpegBytes`; a request that did not gets
21012
+ * `jpeg` exactly as before. MsgPack and the mesh leg both carry binary —
21013
+ * `bytes` above has crossed this boundary as a `Uint8Array` all along — so
21014
+ * base64 was buying nothing but a multi-megabyte string in the relay's heap.
21015
+ */
21016
+ jpegBytes: _instanceof(Uint8Array).optional(),
21009
21017
  width: number().int().positive(),
21010
21018
  height: number().int().positive(),
21011
21019
  /**
@@ -21072,7 +21080,14 @@ var ParkTrackFrameResultSchema = discriminatedUnion("parked", [object({
21072
21080
  })]);
21073
21081
  /** A retrieved parcel — the runner's own JPEG, base64 for the wire. */
21074
21082
  var ParkedTrackFrameSchema = object({
21075
- jpeg: string(),
21083
+ /**
21084
+ * Base64 JPEG — the pre-D462 wire. OPTIONAL since D462: a request that set
21085
+ * `acceptJpegBytes` is answered in `jpegBytes` and this is then absent.
21086
+ * Exactly one of the two is present.
21087
+ */
21088
+ jpeg: string().optional(),
21089
+ /** The same JPEG as bytes, for a caller that declared it reads them (D462). */
21090
+ jpegBytes: _instanceof(Uint8Array).optional(),
21076
21091
  width: number().int().positive(),
21077
21092
  height: number().int().positive(),
21078
21093
  /** The frame instant the parcel shows (the caller's clock, echoed back). */
@@ -21659,6 +21674,13 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21659
21674
  bbox: NativeCropBboxSchema,
21660
21675
  maxWidth: number().int().positive().optional(),
21661
21676
  /**
21677
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21678
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21679
+ * wire — never assume consent: a pre-D462 caller parses the field as
21680
+ * base64 and bytes would decode to garbage rather than fail.
21681
+ */
21682
+ acceptJpegBytes: boolean().optional(),
21683
+ /**
21662
21684
  * When `true`, the runner encodes the resolved crop to JPEG ON THE
21663
21685
  * OWNING NODE and returns it in `jpeg` (base64) INSTEAD of raw `bytes`.
21664
21686
  * Callers set this for CROSS-NODE fetches (`handle.nodeId` is a remote
@@ -21726,7 +21748,14 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
21726
21748
  }), ParkTrackFrameResultSchema, { kind: "mutation" }), method(object({
21727
21749
  deviceId: number(),
21728
21750
  trackId: string(),
21729
- kind: ParkedFrameKindSchema
21751
+ kind: ParkedFrameKindSchema,
21752
+ /**
21753
+ * The caller reads a `Uint8Array` (D462). When set, a JPEG answer comes
21754
+ * back in `jpegBytes` instead of base64 `jpeg`. Absent means the old
21755
+ * wire — never assume consent: a pre-D462 caller parses the field as
21756
+ * base64 and bytes would decode to garbage rather than fail.
21757
+ */
21758
+ acceptJpegBytes: boolean().optional()
21730
21759
  }), ParkedTrackFrameSchema.nullable()), method(object({
21731
21760
  deviceId: number(),
21732
21761
  trackId: string()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-hikvision",
3
- "version": "1.2.104",
3
+ "version": "1.2.105",
4
4
  "description": "Hikvision camera device provider addon for CamStack — ISAPI over HTTP(S) with digest auth (snapshot, alarm stream, RTSP discovery)",
5
5
  "keywords": [
6
6
  "camstack",