camstack 1.2.166 → 1.2.168

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.
@@ -14522,7 +14522,7 @@ function date4(params) {
14522
14522
  // ../../node_modules/zod/v4/classic/external.js
14523
14523
  config(en_default());
14524
14524
 
14525
- // ../types/dist/sleep-BDR76Ykr.mjs
14525
+ // ../types/dist/sleep-B1y0Fo1U.mjs
14526
14526
  var AUDIO_CHUNK_FORMATS = [
14527
14527
  "f32le",
14528
14528
  "pcmu",
@@ -15384,7 +15384,7 @@ function sleep(ms) {
15384
15384
  return new Promise((resolve) => setTimeout(resolve, Math.max(0, ms)));
15385
15385
  }
15386
15386
 
15387
- // ../types/dist/canonical-hash-Ch5bSjFG.mjs
15387
+ // ../types/dist/canonical-hash-DBkl8q6V.mjs
15388
15388
  import { createHash } from "crypto";
15389
15389
  var DEFAULT_MAX_UNIT_BYTES = 16 * 1024 * 1024;
15390
15390
 
@@ -38683,14 +38683,36 @@ var privacyMaskCapability = {
38683
38683
  * whether persisting is worth a SQLite commit. */
38684
38684
  volatileStateFields: ["lastFetchedAt"]
38685
38685
  };
38686
+ var PtzPresetFunctionSchema = external_exports.enum([
38687
+ "home",
38688
+ "day-mode",
38689
+ "night-mode",
38690
+ "day-night-auto",
38691
+ "set-limits",
38692
+ "save-limits",
38693
+ "reboot",
38694
+ "osd-menu"
38695
+ ]);
38686
38696
  var PtzPresetSchema = external_exports.object({
38687
38697
  id: external_exports.string(),
38688
- name: external_exports.string()
38698
+ name: external_exports.string(),
38699
+ /**
38700
+ * The firmware function this id performs, when the provider KNOWS the id is
38701
+ * reserved. `null` = an ordinary stored position, OR a reserved id this
38702
+ * provider does not recognise -- the two are told apart by `writable`.
38703
+ */
38704
+ fn: PtzPresetFunctionSchema.nullable(),
38705
+ /**
38706
+ * Whether `savePreset` / `deletePreset` may target this id. A provider sets
38707
+ * it false only for a band it KNOWS is reserved; where the firmware is not
38708
+ * documented it stays true and a refusal comes from the camera, named.
38709
+ */
38710
+ writable: external_exports.boolean()
38689
38711
  });
38690
38712
  var PtzPositionSchema = external_exports.object({
38691
- pan: external_exports.number(),
38692
- tilt: external_exports.number(),
38693
- zoom: external_exports.number()
38713
+ pan: external_exports.number().nullable(),
38714
+ tilt: external_exports.number().nullable(),
38715
+ zoom: external_exports.number().nullable()
38694
38716
  });
38695
38717
  var PtzMoveCommandSchema = external_exports.object({
38696
38718
  pan: external_exports.number().optional(),
@@ -38708,7 +38730,42 @@ var PtzOptionsSchema = external_exports.object({
38708
38730
  maxPresets: external_exports.number().optional(),
38709
38731
  /** Whether the camera exposes a controllable autofocus toggle
38710
38732
  * (boolean `hasX` per the getOptions availability convention). */
38711
- hasAutofocus: external_exports.boolean()
38733
+ hasAutofocus: external_exports.boolean(),
38734
+ /**
38735
+ * How many distinct speeds this camera's NATIVE scale offers.
38736
+ *
38737
+ * The cap's `speed` is normalized 0..1 and each provider maps it down --
38738
+ * Baichuan 1..63, Dahua 1..8, ISAPI's percentage -100..100. The normalized
38739
+ * value hides how coarse that really is: asking an amcrest for `0.37` is
38740
+ * meaningless, because it has eight steps and three of them round to the
38741
+ * same one. A loop that tunes its own gain has to know the granularity of
38742
+ * the knob it is turning.
38743
+ *
38744
+ * `null` = the driver does not know, or the scale is continuous (ONVIF takes
38745
+ * a float). Never a made-up number.
38746
+ */
38747
+ speedSteps: external_exports.number().int().positive().nullable(),
38748
+ /**
38749
+ * How long ONE `move` pulse runs on this driver, ms.
38750
+ *
38751
+ * `move` is a self-terminating burst everywhere, but every provider hardcoded
38752
+ * its own duration in private -- 200 reolink, 350 amcrest, 500 hikvision,
38753
+ * 1000 onvif -- so no caller could read it. It is the DENOMINATOR of "how far
38754
+ * did the head travel per pulse": without it a measured displacement has no
38755
+ * gain to be divided into.
38756
+ *
38757
+ * `null` = the driver cannot say.
38758
+ */
38759
+ moveImpulseMs: external_exports.number().int().positive().nullable()
38760
+ });
38761
+ var PtzHomePresetSchema = external_exports.object({
38762
+ presetId: external_exports.string().nullable(),
38763
+ source: external_exports.enum([
38764
+ "operator",
38765
+ "firmware",
38766
+ "native",
38767
+ "none"
38768
+ ])
38712
38769
  });
38713
38770
  var ptzCapability = {
38714
38771
  name: "ptz",
@@ -38749,7 +38806,25 @@ var ptzCapability = {
38749
38806
  auth: "admin"
38750
38807
  }),
38751
38808
  getOptions: method(external_exports.object({ deviceId: external_exports.number() }), PtzOptionsSchema),
38809
+ /**
38810
+ * Move to the camera's configured home preset. THROWS when
38811
+ * `getHomePreset()` resolves to `none` -- a head that did not move must
38812
+ * never look like a head that went home.
38813
+ */
38752
38814
  goHome: method(external_exports.object({ deviceId: external_exports.number() }), external_exports.void(), { kind: "mutation" }),
38815
+ /** Which preset `goHome` targets, and who decided it. */
38816
+ getHomePreset: method(external_exports.object({ deviceId: external_exports.number() }), PtzHomePresetSchema),
38817
+ /**
38818
+ * Pin the home preset for this camera. `null` clears the operator's choice
38819
+ * and falls back to whatever the firmware names, or to `none`.
38820
+ */
38821
+ setHomePreset: method(external_exports.object({
38822
+ deviceId: external_exports.number(),
38823
+ presetId: external_exports.string().nullable()
38824
+ }), external_exports.void(), {
38825
+ kind: "mutation",
38826
+ auth: "admin"
38827
+ }),
38753
38828
  /**
38754
38829
  * Pull the current PTZ position. Redundant with the auto-injected
38755
38830
  * `getStatus` method (see `status` below); kept for callers that
@@ -46173,6 +46248,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
46173
46248
  addonId: null,
46174
46249
  access: "delete"
46175
46250
  },
46251
+ "ptz.getHomePreset": {
46252
+ capName: "ptz",
46253
+ capScope: "device",
46254
+ addonId: null,
46255
+ access: "view"
46256
+ },
46176
46257
  "ptz.getOptions": {
46177
46258
  capName: "ptz",
46178
46259
  capScope: "device",
@@ -46221,6 +46302,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
46221
46302
  addonId: null,
46222
46303
  access: "create"
46223
46304
  },
46305
+ "ptz.setHomePreset": {
46306
+ capName: "ptz",
46307
+ capScope: "device",
46308
+ addonId: null,
46309
+ access: "create"
46310
+ },
46224
46311
  "ptz.stop": {
46225
46312
  capName: "ptz",
46226
46313
  capScope: "device",
@@ -49394,6 +49481,11 @@ var METHOD_DEVICE_SELECTORS = Object.freeze({
49394
49481
  form: "single",
49395
49482
  optional: false
49396
49483
  }],
49484
+ "ptz.getHomePreset": [{
49485
+ name: "deviceId",
49486
+ form: "single",
49487
+ optional: false
49488
+ }],
49397
49489
  "ptz.getOptions": [{
49398
49490
  name: "deviceId",
49399
49491
  form: "single",
@@ -49434,6 +49526,11 @@ var METHOD_DEVICE_SELECTORS = Object.freeze({
49434
49526
  form: "single",
49435
49527
  optional: false
49436
49528
  }],
49529
+ "ptz.setHomePreset": [{
49530
+ name: "deviceId",
49531
+ form: "single",
49532
+ optional: false
49533
+ }],
49437
49534
  "ptz.stop": [{
49438
49535
  name: "deviceId",
49439
49536
  form: "single",
package/dist/cli.js CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  runDiscover
4
- } from "./chunk-MXBN3QZ5.js";
4
+ } from "./chunk-AWHVFK2L.js";
5
5
  import "./chunk-LMMQX4CK.js";
6
6
 
7
7
  // src/cli.ts
@@ -38,7 +38,7 @@ async function runServe(args) {
38
38
  ...typeof values.data === "string" ? { data: values.data } : {}
39
39
  };
40
40
  Object.assign(process.env, buildServeEnv(opts));
41
- await import("./launcher-F6TAVUCG.js");
41
+ await import("./launcher-PSI434KW.js");
42
42
  }
43
43
 
44
44
  // src/commands/agent.ts
@@ -83,7 +83,7 @@ async function runAgent(args) {
83
83
  ...typeof values.port === "string" ? { port: values.port } : {}
84
84
  };
85
85
  Object.assign(process.env, buildAgentEnv(opts));
86
- await import("./launcher-F6TAVUCG.js");
86
+ await import("./launcher-PSI434KW.js");
87
87
  }
88
88
 
89
89
  // src/commands/setup.ts
@@ -1140,7 +1140,7 @@ function isUnknown(_value) {
1140
1140
  return true;
1141
1141
  }
1142
1142
  async function resolveServerInteractive(presetNamespace) {
1143
- const { discoverNodes, resolveHubFromDiscovered, filterHubNodes, DEFAULT_HUB_HTTPS_PORT } = await import("./discover-7R72RWAY.js");
1143
+ const { discoverNodes, resolveHubFromDiscovered, filterHubNodes, DEFAULT_HUB_HTTPS_PORT } = await import("./discover-BCCPZRN4.js");
1144
1144
  if (presetNamespace) {
1145
1145
  const spinner4 = clack.spinner();
1146
1146
  spinner4.start(`Discovering hub on LAN (namespace "${presetNamespace}")`);
@@ -5,7 +5,7 @@ import {
5
5
  filterHubNodes,
6
6
  resolveHubFromDiscovered,
7
7
  runDiscover
8
- } from "./chunk-MXBN3QZ5.js";
8
+ } from "./chunk-AWHVFK2L.js";
9
9
  import "./chunk-LMMQX4CK.js";
10
10
  export {
11
11
  DEFAULT_HUB_HTTPS_PORT,
@@ -6434,6 +6434,9 @@ var require_first_boot_addon_plan = __commonJS({
6434
6434
  const target = d.action === "install-npm" ? "@latest" : "";
6435
6435
  lines.push(` ${d.pkg}${target} \u2014 ${d.action}: ${d.reason}`);
6436
6436
  }
6437
+ if (plan.decisions.length > 0 && plan.decisions.every((d) => d.closureVersion === null)) {
6438
+ lines.push(` the closure carries NO version for any of the ${plan.decisions.length} package(s) \u2014 either this is a dev layout, or the closure path does not resolve (it is <root>/node_modules, NOT <server>/node_modules; see closure-node-modules.ts)`);
6439
+ }
6437
6440
  if (plan.twoVersions.length > 0) {
6438
6441
  lines.push(` two versions on this node (installed vs this closure's own copy): ${plan.twoVersions.join(", ")} \u2014 INFO: the installed copy is the one that runs`);
6439
6442
  }
@@ -6501,6 +6504,56 @@ var require_addon_realign_plan = __commonJS({
6501
6504
  }
6502
6505
  });
6503
6506
 
6507
+ // ../../server/backend/dist/closure-node-modules.js
6508
+ var require_closure_node_modules = __commonJS({
6509
+ "../../server/backend/dist/closure-node-modules.js"(exports) {
6510
+ "use strict";
6511
+ var __createBinding = exports && exports.__createBinding || (Object.create ? (function(o, m, k, k2) {
6512
+ if (k2 === void 0) k2 = k;
6513
+ var desc = Object.getOwnPropertyDescriptor(m, k);
6514
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6515
+ desc = { enumerable: true, get: function() {
6516
+ return m[k];
6517
+ } };
6518
+ }
6519
+ Object.defineProperty(o, k2, desc);
6520
+ }) : (function(o, m, k, k2) {
6521
+ if (k2 === void 0) k2 = k;
6522
+ o[k2] = m[k];
6523
+ }));
6524
+ var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? (function(o, v) {
6525
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
6526
+ }) : function(o, v) {
6527
+ o["default"] = v;
6528
+ });
6529
+ var __importStar = exports && exports.__importStar || /* @__PURE__ */ (function() {
6530
+ var ownKeys = function(o) {
6531
+ ownKeys = Object.getOwnPropertyNames || function(o2) {
6532
+ var ar = [];
6533
+ for (var k in o2) if (Object.prototype.hasOwnProperty.call(o2, k)) ar[ar.length] = k;
6534
+ return ar;
6535
+ };
6536
+ return ownKeys(o);
6537
+ };
6538
+ return function(mod) {
6539
+ if (mod && mod.__esModule) return mod;
6540
+ var result = {};
6541
+ if (mod != null) {
6542
+ for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
6543
+ }
6544
+ __setModuleDefault(result, mod);
6545
+ return result;
6546
+ };
6547
+ })();
6548
+ Object.defineProperty(exports, "__esModule", { value: true });
6549
+ exports.resolveClosureNodeModules = resolveClosureNodeModules;
6550
+ var path = __importStar(__require("path"));
6551
+ function resolveClosureNodeModules(serverDistDir) {
6552
+ return path.resolve(serverDistDir, "..", "..", "..");
6553
+ }
6554
+ }
6555
+ });
6556
+
6504
6557
  // ../../server/backend/dist/framework-nodepath.js
6505
6558
  var require_framework_nodepath = __commonJS({
6506
6559
  "../../server/backend/dist/framework-nodepath.js"(exports) {
@@ -23689,9 +23742,9 @@ var require_zod = __commonJS({
23689
23742
  }
23690
23743
  });
23691
23744
 
23692
- // ../system/dist/dist-DluLUTzR.js
23693
- var require_dist_DluLUTzR = __commonJS({
23694
- "../system/dist/dist-DluLUTzR.js"(exports) {
23745
+ // ../system/dist/dist-BW7x4kAI.js
23746
+ var require_dist_BW7x4kAI = __commonJS({
23747
+ "../system/dist/dist-BW7x4kAI.js"(exports) {
23695
23748
  "use strict";
23696
23749
  var zod = require_zod();
23697
23750
  var EventCategory = /* @__PURE__ */ (function(EventCategory2) {
@@ -49305,14 +49358,36 @@ var require_dist_DluLUTzR = __commonJS({
49305
49358
  * whether persisting is worth a SQLite commit. */
49306
49359
  volatileStateFields: ["lastFetchedAt"]
49307
49360
  };
49361
+ var PtzPresetFunctionSchema = zod.z.enum([
49362
+ "home",
49363
+ "day-mode",
49364
+ "night-mode",
49365
+ "day-night-auto",
49366
+ "set-limits",
49367
+ "save-limits",
49368
+ "reboot",
49369
+ "osd-menu"
49370
+ ]);
49308
49371
  var PtzPresetSchema = zod.z.object({
49309
49372
  id: zod.z.string(),
49310
- name: zod.z.string()
49373
+ name: zod.z.string(),
49374
+ /**
49375
+ * The firmware function this id performs, when the provider KNOWS the id is
49376
+ * reserved. `null` = an ordinary stored position, OR a reserved id this
49377
+ * provider does not recognise -- the two are told apart by `writable`.
49378
+ */
49379
+ fn: PtzPresetFunctionSchema.nullable(),
49380
+ /**
49381
+ * Whether `savePreset` / `deletePreset` may target this id. A provider sets
49382
+ * it false only for a band it KNOWS is reserved; where the firmware is not
49383
+ * documented it stays true and a refusal comes from the camera, named.
49384
+ */
49385
+ writable: zod.z.boolean()
49311
49386
  });
49312
49387
  var PtzPositionSchema = zod.z.object({
49313
- pan: zod.z.number(),
49314
- tilt: zod.z.number(),
49315
- zoom: zod.z.number()
49388
+ pan: zod.z.number().nullable(),
49389
+ tilt: zod.z.number().nullable(),
49390
+ zoom: zod.z.number().nullable()
49316
49391
  });
49317
49392
  var PtzMoveCommandSchema = zod.z.object({
49318
49393
  pan: zod.z.number().optional(),
@@ -49330,7 +49405,42 @@ var require_dist_DluLUTzR = __commonJS({
49330
49405
  maxPresets: zod.z.number().optional(),
49331
49406
  /** Whether the camera exposes a controllable autofocus toggle
49332
49407
  * (boolean `hasX` per the getOptions availability convention). */
49333
- hasAutofocus: zod.z.boolean()
49408
+ hasAutofocus: zod.z.boolean(),
49409
+ /**
49410
+ * How many distinct speeds this camera's NATIVE scale offers.
49411
+ *
49412
+ * The cap's `speed` is normalized 0..1 and each provider maps it down --
49413
+ * Baichuan 1..63, Dahua 1..8, ISAPI's percentage -100..100. The normalized
49414
+ * value hides how coarse that really is: asking an amcrest for `0.37` is
49415
+ * meaningless, because it has eight steps and three of them round to the
49416
+ * same one. A loop that tunes its own gain has to know the granularity of
49417
+ * the knob it is turning.
49418
+ *
49419
+ * `null` = the driver does not know, or the scale is continuous (ONVIF takes
49420
+ * a float). Never a made-up number.
49421
+ */
49422
+ speedSteps: zod.z.number().int().positive().nullable(),
49423
+ /**
49424
+ * How long ONE `move` pulse runs on this driver, ms.
49425
+ *
49426
+ * `move` is a self-terminating burst everywhere, but every provider hardcoded
49427
+ * its own duration in private -- 200 reolink, 350 amcrest, 500 hikvision,
49428
+ * 1000 onvif -- so no caller could read it. It is the DENOMINATOR of "how far
49429
+ * did the head travel per pulse": without it a measured displacement has no
49430
+ * gain to be divided into.
49431
+ *
49432
+ * `null` = the driver cannot say.
49433
+ */
49434
+ moveImpulseMs: zod.z.number().int().positive().nullable()
49435
+ });
49436
+ var PtzHomePresetSchema = zod.z.object({
49437
+ presetId: zod.z.string().nullable(),
49438
+ source: zod.z.enum([
49439
+ "operator",
49440
+ "firmware",
49441
+ "native",
49442
+ "none"
49443
+ ])
49334
49444
  });
49335
49445
  var ptzCapability = {
49336
49446
  name: "ptz",
@@ -49371,7 +49481,25 @@ var require_dist_DluLUTzR = __commonJS({
49371
49481
  auth: "admin"
49372
49482
  }),
49373
49483
  getOptions: method(zod.z.object({ deviceId: zod.z.number() }), PtzOptionsSchema),
49484
+ /**
49485
+ * Move to the camera's configured home preset. THROWS when
49486
+ * `getHomePreset()` resolves to `none` -- a head that did not move must
49487
+ * never look like a head that went home.
49488
+ */
49374
49489
  goHome: method(zod.z.object({ deviceId: zod.z.number() }), zod.z.void(), { kind: "mutation" }),
49490
+ /** Which preset `goHome` targets, and who decided it. */
49491
+ getHomePreset: method(zod.z.object({ deviceId: zod.z.number() }), PtzHomePresetSchema),
49492
+ /**
49493
+ * Pin the home preset for this camera. `null` clears the operator's choice
49494
+ * and falls back to whatever the firmware names, or to `none`.
49495
+ */
49496
+ setHomePreset: method(zod.z.object({
49497
+ deviceId: zod.z.number(),
49498
+ presetId: zod.z.string().nullable()
49499
+ }), zod.z.void(), {
49500
+ kind: "mutation",
49501
+ auth: "admin"
49502
+ }),
49375
49503
  /**
49376
49504
  * Pull the current PTZ position. Redundant with the auto-injected
49377
49505
  * `getStatus` method (see `status` below); kept for callers that
@@ -57625,6 +57753,12 @@ var require_dist_DluLUTzR = __commonJS({
57625
57753
  addonId: null,
57626
57754
  access: "delete"
57627
57755
  },
57756
+ "ptz.getHomePreset": {
57757
+ capName: "ptz",
57758
+ capScope: "device",
57759
+ addonId: null,
57760
+ access: "view"
57761
+ },
57628
57762
  "ptz.getOptions": {
57629
57763
  capName: "ptz",
57630
57764
  capScope: "device",
@@ -57673,6 +57807,12 @@ var require_dist_DluLUTzR = __commonJS({
57673
57807
  addonId: null,
57674
57808
  access: "create"
57675
57809
  },
57810
+ "ptz.setHomePreset": {
57811
+ capName: "ptz",
57812
+ capScope: "device",
57813
+ addonId: null,
57814
+ access: "create"
57815
+ },
57676
57816
  "ptz.stop": {
57677
57817
  capName: "ptz",
57678
57818
  capScope: "device",
@@ -60846,6 +60986,11 @@ var require_dist_DluLUTzR = __commonJS({
60846
60986
  form: "single",
60847
60987
  optional: false
60848
60988
  }],
60989
+ "ptz.getHomePreset": [{
60990
+ name: "deviceId",
60991
+ form: "single",
60992
+ optional: false
60993
+ }],
60849
60994
  "ptz.getOptions": [{
60850
60995
  name: "deviceId",
60851
60996
  form: "single",
@@ -60886,6 +61031,11 @@ var require_dist_DluLUTzR = __commonJS({
60886
61031
  form: "single",
60887
61032
  optional: false
60888
61033
  }],
61034
+ "ptz.setHomePreset": [{
61035
+ name: "deviceId",
61036
+ form: "single",
61037
+ optional: false
61038
+ }],
60889
61039
  "ptz.stop": [{
60890
61040
  name: "deviceId",
60891
61041
  form: "single",
@@ -62913,7 +63063,7 @@ var require_alerts_addon = __commonJS({
62913
63063
  [Symbol.toStringTag]: { value: "Module" }
62914
63064
  });
62915
63065
  require_chunk_Cek0wNdY();
62916
- var require_dist10 = require_dist_DluLUTzR();
63066
+ var require_dist10 = require_dist_BW7x4kAI();
62917
63067
  function selectExpired(alerts, cutoffMs) {
62918
63068
  return alerts.filter((a) => a.createdAt < cutoffMs).sort((a, b) => a.createdAt - b.createdAt).map((a) => a.id);
62919
63069
  }
@@ -63732,7 +63882,7 @@ var require_console_logging = __commonJS({
63732
63882
  [Symbol.toStringTag]: { value: "Module" }
63733
63883
  });
63734
63884
  require_chunk_Cek0wNdY();
63735
- var require_dist10 = require_dist_DluLUTzR();
63885
+ var require_dist10 = require_dist_BW7x4kAI();
63736
63886
  var require_formatter = require_formatter_DqAKDlvN();
63737
63887
  var LEVEL_RANK = {
63738
63888
  debug: 0,
@@ -63826,7 +63976,7 @@ var require_core_blocks_addon = __commonJS({
63826
63976
  "use strict";
63827
63977
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
63828
63978
  var require_chunk = require_chunk_Cek0wNdY();
63829
- var require_dist10 = require_dist_DluLUTzR();
63979
+ var require_dist10 = require_dist_BW7x4kAI();
63830
63980
  var node_crypto = __require("crypto");
63831
63981
  var node_fs_promises = __require("fs/promises");
63832
63982
  node_fs_promises = require_chunk.__toESM(node_fs_promises);
@@ -64723,11 +64873,11 @@ var require_core_blocks = __commonJS({
64723
64873
  }
64724
64874
  });
64725
64875
 
64726
- // ../system/dist/retired-settings-keys-VcrnwKN0.js
64727
- var require_retired_settings_keys_VcrnwKN0 = __commonJS({
64728
- "../system/dist/retired-settings-keys-VcrnwKN0.js"(exports) {
64876
+ // ../system/dist/retired-settings-keys-CeaYCDU4.js
64877
+ var require_retired_settings_keys_CeaYCDU4 = __commonJS({
64878
+ "../system/dist/retired-settings-keys-CeaYCDU4.js"(exports) {
64729
64879
  "use strict";
64730
- var require_dist10 = require_dist_DluLUTzR();
64880
+ var require_dist10 = require_dist_BW7x4kAI();
64731
64881
  function settingsStoreIsAuthoritativeHere(env) {
64732
64882
  const raw = (env["CAMSTACK_ROLE"] ?? "").trim().toLowerCase();
64733
64883
  return raw === "" || raw === "hub";
@@ -65007,9 +65157,9 @@ var require_retired_settings_keys_VcrnwKN0 = __commonJS({
65007
65157
  }
65008
65158
  });
65009
65159
 
65010
- // ../types/dist/canonical-hash-9lydiEzx.js
65011
- var require_canonical_hash_9lydiEzx = __commonJS({
65012
- "../types/dist/canonical-hash-9lydiEzx.js"(exports) {
65160
+ // ../types/dist/canonical-hash-CZ2JqJc3.js
65161
+ var require_canonical_hash_CZ2JqJc3 = __commonJS({
65162
+ "../types/dist/canonical-hash-CZ2JqJc3.js"(exports) {
65013
65163
  "use strict";
65014
65164
  var node_crypto = __require("crypto");
65015
65165
  var AUDIO_ENCODER_BY_CODEC = {
@@ -65061,7 +65211,27 @@ var require_canonical_hash_9lydiEzx = __commonJS({
65061
65211
  args.push("-i", input.url);
65062
65212
  return args;
65063
65213
  }
65064
- function buildVideoFilterArgs(scale, outputArgs) {
65214
+ function resolveStreamMaps(selection) {
65215
+ const graph = selection.filterGraph;
65216
+ if (graph) return {
65217
+ video: `[${graph.videoOutLabel}]`,
65218
+ audio: graph.audioOutLabel ? `[${graph.audioOutLabel}]` : "0:a:0?"
65219
+ };
65220
+ if (selection.extraInputs?.length) return {
65221
+ video: "0:v:0",
65222
+ audio: "0:a:0?"
65223
+ };
65224
+ return {
65225
+ video: null,
65226
+ audio: null
65227
+ };
65228
+ }
65229
+ function buildVideoFilterArgs(scale, outputArgs, filterGraph) {
65230
+ if (filterGraph) {
65231
+ if (scale) throw new Error("FfmpegInvocation: video.scale cannot be combined with a filter graph \u2014 scale inside the graph instead (the -vf would feed an output the graph already feeds)");
65232
+ if (outputArgs.some((a) => a === "-vf")) throw new Error("FfmpegInvocation: outputArgs carries a -vf while a filter graph feeds the same output \u2014 fold the filter into the graph");
65233
+ return [];
65234
+ }
65065
65235
  if (!scale) return [];
65066
65236
  if (outputArgs.some((a) => a === "-vf")) return [];
65067
65237
  if (scale.mode === "exact") return ["-vf", `scale=${scale.width}:${scale.height}`];
@@ -65083,14 +65253,17 @@ var require_canonical_hash_9lydiEzx = __commonJS({
65083
65253
  `${bufsize}k`
65084
65254
  ];
65085
65255
  }
65086
- function buildVideoArgs(video, outputArgs) {
65087
- if (video.kind === "copy") return [
65088
- "-c:v",
65089
- "copy",
65090
- ...video.bitstreamFilter ? ["-bsf:v", video.bitstreamFilter] : []
65091
- ];
65256
+ function buildVideoArgs(video, outputArgs, filterGraph) {
65257
+ if (video.kind === "copy") {
65258
+ if (filterGraph) throw new Error("FfmpegInvocation: a filter graph produces a NEW picture, so video.kind must be `encode`");
65259
+ return [
65260
+ "-c:v",
65261
+ "copy",
65262
+ ...video.bitstreamFilter ? ["-bsf:v", video.bitstreamFilter] : []
65263
+ ];
65264
+ }
65092
65265
  const args = [
65093
- ...buildVideoFilterArgs(video.scale, outputArgs),
65266
+ ...buildVideoFilterArgs(video.scale, outputArgs, filterGraph),
65094
65267
  "-c:v",
65095
65268
  video.encoder
65096
65269
  ];
@@ -65181,14 +65354,23 @@ var require_canonical_hash_9lydiEzx = __commonJS({
65181
65354
  ];
65182
65355
  }
65183
65356
  function buildFfmpegArgs(inv) {
65184
- const head = [...logBannerArgs(inv.logLevel), ...buildInputArgs(inv.input, inv.decodeHwAccel)];
65357
+ const graph = inv.filterGraph ?? null;
65358
+ const head = [
65359
+ ...logBannerArgs(inv.logLevel),
65360
+ ...buildInputArgs(inv.input, inv.decodeHwAccel),
65361
+ ...(inv.extraInputs ?? []).flatMap((extra) => buildInputArgs(extra, inv.decodeHwAccel)),
65362
+ ...graph ? ["-filter_complex", graph.graph] : []
65363
+ ];
65185
65364
  const threadArgs = inv.threadCount > 0 ? ["-threads", String(inv.threadCount)] : [];
65365
+ const maps = resolveStreamMaps(inv);
65366
+ const videoMapArgs = maps.video ? ["-map", maps.video] : [];
65367
+ const audioMapArgs = maps.audio ? ["-map", maps.audio] : [];
65186
65368
  if (inv.sink.kind === "rtp-outputs") {
65187
65369
  const videoLeg = inv.sink.video ? [
65188
65370
  "-an",
65189
65371
  "-map",
65190
- "0:v:0",
65191
- ...buildVideoArgs(inv.video, inv.outputArgs),
65372
+ maps.video ?? "0:v:0",
65373
+ ...buildVideoArgs(inv.video, inv.outputArgs, graph),
65192
65374
  ...threadArgs,
65193
65375
  ...inv.outputArgs,
65194
65376
  ...buildRtpOutputArgs(inv.sink.video)
@@ -65196,7 +65378,7 @@ var require_canonical_hash_9lydiEzx = __commonJS({
65196
65378
  const audioLeg = inv.sink.audio ? [
65197
65379
  "-vn",
65198
65380
  "-map",
65199
- "0:a:0?",
65381
+ maps.audio ?? "0:a:0?",
65200
65382
  ...buildAudioArgs(inv.audio),
65201
65383
  ...buildRtpOutputArgs(inv.sink.audio)
65202
65384
  ] : [];
@@ -65206,15 +65388,17 @@ var require_canonical_hash_9lydiEzx = __commonJS({
65206
65388
  ...audioLeg
65207
65389
  ];
65208
65390
  }
65391
+ const mutedAudio = isElementaryVideoSink(inv.sink) || inv.audio.kind === "none";
65209
65392
  const audioArgs = isElementaryVideoSink(inv.sink) ? ["-an"] : buildAudioArgs(inv.audio);
65210
- const sinkArgs = buildStdoutOrRtspSinkArgs(inv.sink);
65211
65393
  return [
65212
65394
  ...head,
65213
- ...buildVideoArgs(inv.video, inv.outputArgs),
65395
+ ...videoMapArgs,
65396
+ ...buildVideoArgs(inv.video, inv.outputArgs, graph),
65214
65397
  ...threadArgs,
65398
+ ...mutedAudio ? [] : audioMapArgs,
65215
65399
  ...audioArgs,
65216
65400
  ...inv.outputArgs,
65217
- ...sinkArgs,
65401
+ ...buildStdoutOrRtspSinkArgs(inv.sink),
65218
65402
  ...inv.audioSidecar ? buildAudioSidecarArgs(inv.audioSidecar) : []
65219
65403
  ];
65220
65404
  }
@@ -65565,6 +65749,12 @@ var require_canonical_hash_9lydiEzx = __commonJS({
65565
65749
  return pickVideoEncoder;
65566
65750
  }
65567
65751
  });
65752
+ Object.defineProperty(exports, "resolveStreamMaps", {
65753
+ enumerable: true,
65754
+ get: function() {
65755
+ return resolveStreamMaps;
65756
+ }
65757
+ });
65568
65758
  }
65569
65759
  });
65570
65760
 
@@ -65611,7 +65801,7 @@ var require_node = __commonJS({
65611
65801
  value: mod,
65612
65802
  enumerable: true
65613
65803
  }) : target, mod));
65614
- var require_canonical_hash = require_canonical_hash_9lydiEzx();
65804
+ var require_canonical_hash = require_canonical_hash_CZ2JqJc3();
65615
65805
  var require_err_msg = require_err_msg_COpsHMw2();
65616
65806
  var node_crypto = __require("crypto");
65617
65807
  var node_fs = __require("fs");
@@ -66964,8 +67154,8 @@ var require_device_manager_addon = __commonJS({
66964
67154
  [Symbol.toStringTag]: { value: "Module" }
66965
67155
  });
66966
67156
  require_chunk_Cek0wNdY();
66967
- var require_dist10 = require_dist_DluLUTzR();
66968
- var require_retired_settings_keys = require_retired_settings_keys_VcrnwKN0();
67157
+ var require_dist10 = require_dist_BW7x4kAI();
67158
+ var require_retired_settings_keys = require_retired_settings_keys_CeaYCDU4();
66969
67159
  var node_crypto = __require("crypto");
66970
67160
  var _camstack_types_node = require_node();
66971
67161
  var JOB_HISTORY = 20;
@@ -72973,7 +73163,7 @@ var require_hub_forwarder = __commonJS({
72973
73163
  [Symbol.toStringTag]: { value: "Module" }
72974
73164
  });
72975
73165
  require_chunk_Cek0wNdY();
72976
- var require_dist10 = require_dist_DluLUTzR();
73166
+ var require_dist10 = require_dist_BW7x4kAI();
72977
73167
  var require_formatter = require_formatter_DqAKDlvN();
72978
73168
  var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
72979
73169
  var HubForwarderDestination = class {
@@ -73110,7 +73300,7 @@ var require_liveness_monitor_addon = __commonJS({
73110
73300
  "use strict";
73111
73301
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
73112
73302
  require_chunk_Cek0wNdY();
73113
- var require_dist10 = require_dist_DluLUTzR();
73303
+ var require_dist10 = require_dist_BW7x4kAI();
73114
73304
  var NO_DEVICES = "liveness:no-devices";
73115
73305
  var ALL_OFFLINE = "liveness:all-devices-offline";
73116
73306
  var NO_FOOTAGE_PREFIX = "liveness:no-footage:";
@@ -73306,7 +73496,7 @@ var require_local_auth_addon = __commonJS({
73306
73496
  [Symbol.toStringTag]: { value: "Module" }
73307
73497
  });
73308
73498
  var require_chunk = require_chunk_Cek0wNdY();
73309
- var require_dist10 = require_dist_DluLUTzR();
73499
+ var require_dist10 = require_dist_BW7x4kAI();
73310
73500
  var node_crypto = __require("crypto");
73311
73501
  node_crypto = require_chunk.__toESM(node_crypto);
73312
73502
  var crypto$1 = __require("crypto");
@@ -81119,7 +81309,7 @@ var require_loki_logging = __commonJS({
81119
81309
  [Symbol.toStringTag]: { value: "Module" }
81120
81310
  });
81121
81311
  require_chunk_Cek0wNdY();
81122
- var require_dist10 = require_dist_DluLUTzR();
81312
+ var require_dist10 = require_dist_BW7x4kAI();
81123
81313
  function sanitizeLabelName(raw) {
81124
81314
  const replaced = raw.replaceAll(/[^a-zA-Z0-9_]/g, "_");
81125
81315
  return /^[a-zA-Z_]/.test(replaced) ? replaced : `_${replaced}`;
@@ -81706,7 +81896,7 @@ var require_native_metrics_addon = __commonJS({
81706
81896
  [Symbol.toStringTag]: { value: "Module" }
81707
81897
  });
81708
81898
  var require_chunk = require_chunk_Cek0wNdY();
81709
- var require_dist10 = require_dist_DluLUTzR();
81899
+ var require_dist10 = require_dist_BW7x4kAI();
81710
81900
  var node_fs_promises = __require("fs/promises");
81711
81901
  var node_fs = __require("fs");
81712
81902
  node_fs = require_chunk.__toESM(node_fs);
@@ -84459,7 +84649,7 @@ var require_filesystem_storage_addon = __commonJS({
84459
84649
  [Symbol.toStringTag]: { value: "Module" }
84460
84650
  });
84461
84651
  var require_chunk = require_chunk_Cek0wNdY();
84462
- var require_dist10 = require_dist_DluLUTzR();
84652
+ var require_dist10 = require_dist_BW7x4kAI();
84463
84653
  var node_crypto = __require("crypto");
84464
84654
  var node_fs_promises = __require("fs/promises");
84465
84655
  var node_path = __require("path");
@@ -85686,8 +85876,8 @@ var require_sqlite_settings_addon = __commonJS({
85686
85876
  [Symbol.toStringTag]: { value: "Module" }
85687
85877
  });
85688
85878
  var require_chunk = require_chunk_Cek0wNdY();
85689
- var require_dist10 = require_dist_DluLUTzR();
85690
- var require_retired_settings_keys = require_retired_settings_keys_VcrnwKN0();
85879
+ var require_dist10 = require_dist_BW7x4kAI();
85880
+ var require_retired_settings_keys = require_retired_settings_keys_CeaYCDU4();
85691
85881
  var require_wal_checkpoint_policy = require_wal_checkpoint_policy_CCJZngds();
85692
85882
  var node_crypto = __require("crypto");
85693
85883
  var node_path = __require("path");
@@ -88474,7 +88664,7 @@ var require_storage_orchestrator_addon = __commonJS({
88474
88664
  [Symbol.toStringTag]: { value: "Module" }
88475
88665
  });
88476
88666
  var require_chunk = require_chunk_Cek0wNdY();
88477
- var require_dist10 = require_dist_DluLUTzR();
88667
+ var require_dist10 = require_dist_BW7x4kAI();
88478
88668
  var require_hub_cap_forward = require_hub_cap_forward_DmHNjbB0();
88479
88669
  var zod = require_zod();
88480
88670
  var node_crypto = __require("crypto");
@@ -92201,7 +92391,7 @@ var require_system_config_addon = __commonJS({
92201
92391
  [Symbol.toStringTag]: { value: "Module" }
92202
92392
  });
92203
92393
  require_chunk_Cek0wNdY();
92204
- var require_dist10 = require_dist_DluLUTzR();
92394
+ var require_dist10 = require_dist_BW7x4kAI();
92205
92395
  var SECTION_TITLES = {
92206
92396
  server: "Server",
92207
92397
  auth: "Authentication"
@@ -110262,7 +110452,7 @@ var require_winston_logging = __commonJS({
110262
110452
  [Symbol.toStringTag]: { value: "Module" }
110263
110453
  });
110264
110454
  var require_chunk = require_chunk_Cek0wNdY();
110265
- var require_dist10 = require_dist_DluLUTzR();
110455
+ var require_dist10 = require_dist_BW7x4kAI();
110266
110456
  var require_formatter = require_formatter_DqAKDlvN();
110267
110457
  var node_path = __require("path");
110268
110458
  node_path = require_chunk.__toESM(node_path);
@@ -112300,9 +112490,9 @@ var require_event_category_BVfsrBYA = __commonJS({
112300
112490
  }
112301
112491
  });
112302
112492
 
112303
- // ../types/dist/sleep-DqtlfkSS.js
112304
- var require_sleep_DqtlfkSS = __commonJS({
112305
- "../types/dist/sleep-DqtlfkSS.js"(exports) {
112493
+ // ../types/dist/sleep-BAAUFDCk.js
112494
+ var require_sleep_BAAUFDCk = __commonJS({
112495
+ "../types/dist/sleep-BAAUFDCk.js"(exports) {
112306
112496
  "use strict";
112307
112497
  var require_event_category = require_event_category_BVfsrBYA();
112308
112498
  var zod = require_zod();
@@ -115205,6 +115395,8 @@ var require_sleep_DqtlfkSS = __commonJS({
115205
115395
  deletePreset: (input) => dispatch("ptz", "ptz", "deletePreset", "mutation", input),
115206
115396
  getOptions: (input) => dispatch("ptz", "ptz", "getOptions", "query", input),
115207
115397
  goHome: (input) => dispatch("ptz", "ptz", "goHome", "mutation", input),
115398
+ getHomePreset: (input) => dispatch("ptz", "ptz", "getHomePreset", "query", input),
115399
+ setHomePreset: (input) => dispatch("ptz", "ptz", "setHomePreset", "mutation", input),
115208
115400
  getPosition: (input) => dispatch("ptz", "ptz", "getPosition", "query", input),
115209
115401
  setAutofocus: (input) => dispatch("ptz", "ptz", "setAutofocus", "mutation", input),
115210
115402
  getStatus: (input) => dispatch("ptz", "ptz", "getStatus", "query", input)
@@ -116203,7 +116395,7 @@ var require_addon = __commonJS({
116203
116395
  "../types/dist/addon.js"(exports) {
116204
116396
  "use strict";
116205
116397
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
116206
- var require_sleep = require_sleep_DqtlfkSS();
116398
+ var require_sleep = require_sleep_BAAUFDCk();
116207
116399
  var require_event_category = require_event_category_BVfsrBYA();
116208
116400
  var require_err_msg = require_err_msg_COpsHMw2();
116209
116401
  var CAP_INPUT_DEFAULTS = Object.freeze({
@@ -136529,7 +136721,7 @@ var require_dist3 = __commonJS({
136529
136721
  "use strict";
136530
136722
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
136531
136723
  var require_chunk = require_chunk_Cek0wNdY();
136532
- var require_dist10 = require_dist_DluLUTzR();
136724
+ var require_dist10 = require_dist_BW7x4kAI();
136533
136725
  var require_builtins_alerts_alerts_addon = require_alerts_addon();
136534
136726
  require_alerts();
136535
136727
  var require_formatter = require_formatter_DqAKDlvN();
@@ -217693,9 +217885,9 @@ var require_dist4 = __commonJS({
217693
217885
  "../types/dist/index.js"(exports) {
217694
217886
  "use strict";
217695
217887
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
217696
- var require_sleep = require_sleep_DqtlfkSS();
217888
+ var require_sleep = require_sleep_BAAUFDCk();
217697
217889
  var require_event_category = require_event_category_BVfsrBYA();
217698
- var require_canonical_hash = require_canonical_hash_9lydiEzx();
217890
+ var require_canonical_hash = require_canonical_hash_CZ2JqJc3();
217699
217891
  var require_enums2 = require_enums();
217700
217892
  var require_err_msg = require_err_msg_COpsHMw2();
217701
217893
  var zod = require_zod();
@@ -244502,14 +244694,36 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
244502
244694
  if (profiles.length === 0) return null;
244503
244695
  return profiles.some((p) => p.audioEnabled);
244504
244696
  }
244697
+ var PtzPresetFunctionSchema = zod.z.enum([
244698
+ "home",
244699
+ "day-mode",
244700
+ "night-mode",
244701
+ "day-night-auto",
244702
+ "set-limits",
244703
+ "save-limits",
244704
+ "reboot",
244705
+ "osd-menu"
244706
+ ]);
244505
244707
  var PtzPresetSchema = zod.z.object({
244506
244708
  id: zod.z.string(),
244507
- name: zod.z.string()
244709
+ name: zod.z.string(),
244710
+ /**
244711
+ * The firmware function this id performs, when the provider KNOWS the id is
244712
+ * reserved. `null` = an ordinary stored position, OR a reserved id this
244713
+ * provider does not recognise -- the two are told apart by `writable`.
244714
+ */
244715
+ fn: PtzPresetFunctionSchema.nullable(),
244716
+ /**
244717
+ * Whether `savePreset` / `deletePreset` may target this id. A provider sets
244718
+ * it false only for a band it KNOWS is reserved; where the firmware is not
244719
+ * documented it stays true and a refusal comes from the camera, named.
244720
+ */
244721
+ writable: zod.z.boolean()
244508
244722
  });
244509
244723
  var PtzPositionSchema = zod.z.object({
244510
- pan: zod.z.number(),
244511
- tilt: zod.z.number(),
244512
- zoom: zod.z.number()
244724
+ pan: zod.z.number().nullable(),
244725
+ tilt: zod.z.number().nullable(),
244726
+ zoom: zod.z.number().nullable()
244513
244727
  });
244514
244728
  var PtzMoveCommandSchema = zod.z.object({
244515
244729
  pan: zod.z.number().optional(),
@@ -244527,7 +244741,42 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
244527
244741
  maxPresets: zod.z.number().optional(),
244528
244742
  /** Whether the camera exposes a controllable autofocus toggle
244529
244743
  * (boolean `hasX` per the getOptions availability convention). */
244530
- hasAutofocus: zod.z.boolean()
244744
+ hasAutofocus: zod.z.boolean(),
244745
+ /**
244746
+ * How many distinct speeds this camera's NATIVE scale offers.
244747
+ *
244748
+ * The cap's `speed` is normalized 0..1 and each provider maps it down --
244749
+ * Baichuan 1..63, Dahua 1..8, ISAPI's percentage -100..100. The normalized
244750
+ * value hides how coarse that really is: asking an amcrest for `0.37` is
244751
+ * meaningless, because it has eight steps and three of them round to the
244752
+ * same one. A loop that tunes its own gain has to know the granularity of
244753
+ * the knob it is turning.
244754
+ *
244755
+ * `null` = the driver does not know, or the scale is continuous (ONVIF takes
244756
+ * a float). Never a made-up number.
244757
+ */
244758
+ speedSteps: zod.z.number().int().positive().nullable(),
244759
+ /**
244760
+ * How long ONE `move` pulse runs on this driver, ms.
244761
+ *
244762
+ * `move` is a self-terminating burst everywhere, but every provider hardcoded
244763
+ * its own duration in private -- 200 reolink, 350 amcrest, 500 hikvision,
244764
+ * 1000 onvif -- so no caller could read it. It is the DENOMINATOR of "how far
244765
+ * did the head travel per pulse": without it a measured displacement has no
244766
+ * gain to be divided into.
244767
+ *
244768
+ * `null` = the driver cannot say.
244769
+ */
244770
+ moveImpulseMs: zod.z.number().int().positive().nullable()
244771
+ });
244772
+ var PtzHomePresetSchema = zod.z.object({
244773
+ presetId: zod.z.string().nullable(),
244774
+ source: zod.z.enum([
244775
+ "operator",
244776
+ "firmware",
244777
+ "native",
244778
+ "none"
244779
+ ])
244531
244780
  });
244532
244781
  var ptzCapability = {
244533
244782
  name: "ptz",
@@ -244568,7 +244817,25 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
244568
244817
  auth: "admin"
244569
244818
  }),
244570
244819
  getOptions: require_sleep.method(zod.z.object({ deviceId: zod.z.number() }), PtzOptionsSchema),
244820
+ /**
244821
+ * Move to the camera's configured home preset. THROWS when
244822
+ * `getHomePreset()` resolves to `none` -- a head that did not move must
244823
+ * never look like a head that went home.
244824
+ */
244571
244825
  goHome: require_sleep.method(zod.z.object({ deviceId: zod.z.number() }), zod.z.void(), { kind: "mutation" }),
244826
+ /** Which preset `goHome` targets, and who decided it. */
244827
+ getHomePreset: require_sleep.method(zod.z.object({ deviceId: zod.z.number() }), PtzHomePresetSchema),
244828
+ /**
244829
+ * Pin the home preset for this camera. `null` clears the operator's choice
244830
+ * and falls back to whatever the firmware names, or to `none`.
244831
+ */
244832
+ setHomePreset: require_sleep.method(zod.z.object({
244833
+ deviceId: zod.z.number(),
244834
+ presetId: zod.z.string().nullable()
244835
+ }), zod.z.void(), {
244836
+ kind: "mutation",
244837
+ auth: "admin"
244838
+ }),
244572
244839
  /**
244573
244840
  * Pull the current PTZ position. Redundant with the auto-injected
244574
244841
  * `getStatus` method (see `status` below); kept for callers that
@@ -256196,6 +256463,12 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
256196
256463
  addonId: null,
256197
256464
  access: "delete"
256198
256465
  },
256466
+ "ptz.getHomePreset": {
256467
+ capName: "ptz",
256468
+ capScope: "device",
256469
+ addonId: null,
256470
+ access: "view"
256471
+ },
256199
256472
  "ptz.getOptions": {
256200
256473
  capName: "ptz",
256201
256474
  capScope: "device",
@@ -256244,6 +256517,12 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
256244
256517
  addonId: null,
256245
256518
  access: "create"
256246
256519
  },
256520
+ "ptz.setHomePreset": {
256521
+ capName: "ptz",
256522
+ capScope: "device",
256523
+ addonId: null,
256524
+ access: "create"
256525
+ },
256247
256526
  "ptz.stop": {
256248
256527
  capName: "ptz",
256249
256528
  capScope: "device",
@@ -259683,6 +259962,11 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
259683
259962
  form: "single",
259684
259963
  optional: false
259685
259964
  }],
259965
+ "ptz.getHomePreset": [{
259966
+ name: "deviceId",
259967
+ form: "single",
259968
+ optional: false
259969
+ }],
259686
259970
  "ptz.getOptions": [{
259687
259971
  name: "deviceId",
259688
259972
  form: "single",
@@ -259723,6 +260007,11 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
259723
260007
  form: "single",
259724
260008
  optional: false
259725
260009
  }],
260010
+ "ptz.setHomePreset": [{
260011
+ name: "deviceId",
260012
+ form: "single",
260013
+ optional: false
260014
+ }],
259726
260015
  "ptz.stop": [{
259727
260016
  name: "deviceId",
259728
260017
  form: "single",
@@ -264872,9 +265161,11 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
264872
265161
  exports.PtzAutotrackSettingsSchema = PtzAutotrackSettingsSchema;
264873
265162
  exports.PtzAutotrackStatusSchema = PtzAutotrackStatusSchema;
264874
265163
  exports.PtzAutotrackTargetOptionSchema = PtzAutotrackTargetOptionSchema;
265164
+ exports.PtzHomePresetSchema = PtzHomePresetSchema;
264875
265165
  exports.PtzMoveCommandSchema = PtzMoveCommandSchema;
264876
265166
  exports.PtzOptionsSchema = PtzOptionsSchema;
264877
265167
  exports.PtzPositionSchema = PtzPositionSchema;
265168
+ exports.PtzPresetFunctionSchema = PtzPresetFunctionSchema;
264878
265169
  exports.PtzPresetSchema = PtzPresetSchema;
264879
265170
  exports.PtzStatusSchema = PtzStatusSchema;
264880
265171
  exports.QueryFilterSchema = QueryFilterSchema;
@@ -265595,6 +265886,7 @@ ${recipe.triggers.map((t, i) => emitTrigger(t, i)).join("\n\n")}
265595
265886
  exports.resolvePoolMemoryPolicy = resolvePoolMemoryPolicy;
265596
265887
  exports.resolveRecordingProfiles = resolveRecordingProfiles;
265597
265888
  exports.resolveRunnerId = resolveRunnerId;
265889
+ exports.resolveStreamMaps = require_canonical_hash.resolveStreamMaps;
265598
265890
  exports.resolveVariantModelId = resolveVariantModelId;
265599
265891
  exports.resolveViewableDeviceIds = resolveViewableDeviceIds;
265600
265892
  exports.roleSpec = roleSpec;
@@ -439978,6 +440270,7 @@ var require_launcher = __commonJS({
439978
440270
  var bootstrap_packages_js_1 = require_bootstrap_packages();
439979
440271
  var first_boot_addon_plan_js_1 = require_first_boot_addon_plan();
439980
440272
  var addon_realign_plan_js_1 = require_addon_realign_plan();
440273
+ var closure_node_modules_js_1 = require_closure_node_modules();
439981
440274
  var framework_nodepath_js_1 = require_framework_nodepath();
439982
440275
  var package_inventory_js_1 = require_package_inventory();
439983
440276
  var ARCHIVE_MANIFEST_NAME = ".camstack-backup-manifest.json";
@@ -440159,7 +440452,7 @@ var require_launcher = __commonJS({
440159
440452
  const bootstrapRequired = readBootstrapRequiredAddons(dataDir, bootstrapSchema) ?? roleDefaultBootstrap;
440160
440453
  console.log(`[launcher] bootstrap (${role}): ${bootstrapRequired.length} required package(s)`);
440161
440454
  try {
440162
- const closureNodeModules = path.resolve(__dirname, "..", "node_modules");
440455
+ const closureNodeModules = (0, closure_node_modules_js_1.resolveClosureNodeModules)(__dirname);
440163
440456
  const plan = (0, first_boot_addon_plan_js_1.planFirstBootAddons)({
440164
440457
  required: bootstrapRequired,
440165
440458
  installed: readInstalledAddonVersions(addonsDir, bootstrapRequired),
@@ -440183,7 +440476,7 @@ var require_launcher = __commonJS({
440183
440476
  }
440184
440477
  await installer.ensureRequiredPackages(bootstrapRequired);
440185
440478
  try {
440186
- const closureNodeModules = path.resolve(__dirname, "..", "node_modules");
440479
+ const closureNodeModules = (0, closure_node_modules_js_1.resolveClosureNodeModules)(__dirname);
440187
440480
  const decisions = (0, addon_realign_plan_js_1.planAddonRealignment)(bootstrapRequired.flatMap((pkg) => {
440188
440481
  const installedVersion = readInstalledAddonVersions(addonsDir, [pkg])[pkg];
440189
440482
  if (typeof installedVersion !== "string")
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "camstack",
3
- "version": "1.2.166",
3
+ "version": "1.2.168",
4
4
  "description": "CLI tool for managing and running CamStack server",
5
5
  "keywords": [
6
6
  "camstack",