camstreamerlib 4.0.0-beta.4 → 4.0.0-beta.41
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/README.md +112 -0
- package/cjs/CamOverlayAPI.js +135 -92
- package/cjs/CamScripterAPI.js +52 -42
- package/cjs/CamStreamerAPI.js +83 -39
- package/cjs/CamSwitcherAPI.js +141 -123
- package/cjs/CamSwitcherEvents.js +4 -60
- package/cjs/PlaneTrackerAPI.js +210 -0
- package/cjs/VapixAPI.js +323 -233
- package/cjs/{CreatePackage.js → bin/CreatePackage.js} +22 -19
- package/cjs/errors/errors.js +78 -1
- package/cjs/index.js +17 -4
- package/cjs/internal/ProxyClient.js +28 -32
- package/cjs/internal/WsEvents.js +72 -0
- package/cjs/internal/types.js +2 -0
- package/cjs/internal/utils.js +22 -3
- package/cjs/{CamOverlayDrawingAPI.js → node/CamOverlayDrawingAPI.js} +7 -4
- package/cjs/{CamOverlayPainter → node/CamOverlayPainter}/Frame.js +33 -0
- package/cjs/{CamOverlayPainter → node/CamOverlayPainter}/Painter.js +5 -17
- package/cjs/node/CamOverlayPainter/ResourceManager.js +72 -0
- package/cjs/{CamScripterAPICameraEventsGenerator.js → node/CamScripterAPICameraEventsGenerator.js} +7 -4
- package/cjs/node/DefaultClient.js +10 -12
- package/cjs/{internal → node}/Digest.js +8 -5
- package/cjs/node/HttpRequestSender.js +14 -4
- package/cjs/node/HttpServer.js +15 -12
- package/cjs/{VapixEvents.js → node/VapixEvents.js} +1 -1
- package/cjs/node/WsClient.js +12 -9
- package/cjs/node/events/AxisCameraStationEvents.js +53 -0
- package/cjs/node/events/GenetecAgent.js +123 -0
- package/cjs/node/index.js +38 -5
- package/cjs/types/CamOverlayAPI/CamOverlayAPI.js +92 -0
- package/cjs/types/CamOverlayAPI/accuweatherSchema.js +47 -0
- package/cjs/types/CamOverlayAPI/customGraphicsSchema.js +72 -0
- package/cjs/types/CamOverlayAPI/imagesSchema.js +9 -0
- package/cjs/types/CamOverlayAPI/index.js +27 -0
- package/cjs/types/CamOverlayAPI/infotickerSchema.js +26 -0
- package/cjs/types/CamOverlayAPI/pipSchema.js +39 -0
- package/cjs/types/CamOverlayAPI/ptzCompassSchema.js +25 -0
- package/cjs/types/CamOverlayAPI/ptzSchema.js +12 -0
- package/cjs/types/CamOverlayAPI/scoreBoardSchema.js +132 -0
- package/cjs/types/CamOverlayAPI/screenSharingSchema.js +8 -0
- package/cjs/types/CamOverlayAPI/serviceCommonTypes.js +91 -0
- package/cjs/types/CamOverlayAPI/webCameraSharingSchema.js +8 -0
- package/cjs/types/CamOverlayDrawingAPI.js +2 -0
- package/cjs/types/CamOverlayPainter.js +14 -0
- package/cjs/types/CamScripterAPI.js +22 -7
- package/cjs/types/CamScripterAPICameraEventsGenerator.js +2 -0
- package/cjs/types/CamStreamerAPI.js +34 -3
- package/cjs/types/CamSwitcherAPI.js +38 -1
- package/cjs/types/CamSwitcherEvents.js +8 -0
- package/cjs/types/GenetecAgent.js +31 -0
- package/cjs/types/PlaneTrackerAPI.js +286 -0
- package/cjs/types/VapixAPI.js +71 -13
- package/cjs/types/VapixEvents.js +2 -0
- package/cjs/web/DefaultClient.js +22 -10
- package/cjs/web/WsClient.js +3 -3
- package/esm/CamOverlayAPI.js +131 -88
- package/esm/CamScripterAPI.js +48 -38
- package/esm/CamStreamerAPI.js +81 -38
- package/esm/CamSwitcherAPI.js +137 -119
- package/esm/CamSwitcherEvents.js +5 -61
- package/esm/PlaneTrackerAPI.js +206 -0
- package/esm/VapixAPI.js +315 -225
- package/esm/{CreatePackage.js → bin/CreatePackage.js} +3 -3
- package/esm/errors/errors.js +66 -0
- package/esm/index.js +12 -3
- package/esm/internal/ProxyClient.js +28 -32
- package/esm/internal/WsEvents.js +68 -0
- package/esm/internal/utils.js +17 -1
- package/esm/{CamOverlayDrawingAPI.js → node/CamOverlayDrawingAPI.js} +2 -2
- package/esm/{CamOverlayPainter → node/CamOverlayPainter}/Frame.js +33 -0
- package/esm/{CamOverlayPainter → node/CamOverlayPainter}/Painter.js +2 -13
- package/esm/{CamOverlayPainter → node/CamOverlayPainter}/ResourceManager.js +7 -5
- package/esm/{CamScripterAPICameraEventsGenerator.js → node/CamScripterAPICameraEventsGenerator.js} +2 -2
- package/esm/node/DefaultClient.js +10 -12
- package/esm/{internal → node}/Digest.js +1 -1
- package/esm/node/HttpRequestSender.js +14 -4
- package/esm/node/HttpServer.js +5 -5
- package/esm/{VapixEvents.js → node/VapixEvents.js} +1 -1
- package/esm/node/WsClient.js +3 -3
- package/esm/{events → node/events}/AxisCameraStationEvents.js +18 -13
- package/esm/node/events/GenetecAgent.js +119 -0
- package/esm/node/index.js +17 -2
- package/esm/types/CamOverlayAPI/CamOverlayAPI.js +76 -0
- package/esm/types/CamOverlayAPI/accuweatherSchema.js +44 -0
- package/esm/types/CamOverlayAPI/customGraphicsSchema.js +69 -0
- package/esm/types/CamOverlayAPI/imagesSchema.js +6 -0
- package/esm/types/CamOverlayAPI/index.js +11 -0
- package/esm/types/CamOverlayAPI/infotickerSchema.js +23 -0
- package/esm/types/CamOverlayAPI/pipSchema.js +36 -0
- package/esm/types/CamOverlayAPI/ptzCompassSchema.js +22 -0
- package/esm/types/CamOverlayAPI/ptzSchema.js +9 -0
- package/esm/types/CamOverlayAPI/scoreBoardSchema.js +129 -0
- package/esm/types/CamOverlayAPI/screenSharingSchema.js +5 -0
- package/esm/types/CamOverlayAPI/serviceCommonTypes.js +88 -0
- package/esm/types/CamOverlayAPI/webCameraSharingSchema.js +5 -0
- package/esm/types/CamOverlayPainter.js +11 -0
- package/esm/types/CamScripterAPI.js +21 -6
- package/esm/types/CamScripterAPICameraEventsGenerator.js +1 -0
- package/esm/types/CamStreamerAPI.js +33 -2
- package/esm/types/CamSwitcherAPI.js +38 -1
- package/esm/types/CamSwitcherEvents.js +8 -0
- package/esm/types/GenetecAgent.js +28 -0
- package/esm/types/PlaneTrackerAPI.js +283 -0
- package/esm/types/VapixAPI.js +70 -12
- package/esm/types/VapixEvents.js +1 -0
- package/esm/web/DefaultClient.js +22 -10
- package/esm/web/WsClient.js +3 -3
- package/package.json +30 -12
- package/types/CamOverlayAPI.d.ts +865 -0
- package/types/CamScripterAPI.d.ts +47 -0
- package/types/CamStreamerAPI.d.ts +64 -0
- package/types/CamSwitcherAPI.d.ts +167 -0
- package/types/CamSwitcherEvents.d.ts +8 -0
- package/types/PlaneTrackerAPI.d.ts +230 -0
- package/types/VapixAPI.d.ts +118 -0
- package/types/bin/CreatePackage.d.ts +1 -0
- package/types/errors/errors.d.ts +68 -0
- package/types/index.d.ts +20 -0
- package/types/internal/ProxyClient.d.ts +10 -0
- package/types/internal/WsEvents.d.ts +41 -0
- package/types/internal/types.d.ts +45 -0
- package/{cjs → types}/internal/utils.d.ts +4 -1
- package/{cjs → types}/internal/versionCompare.d.ts +2 -2
- package/types/node/CamOverlayDrawingAPI.d.ts +41 -0
- package/{esm → types/node}/CamOverlayPainter/Frame.d.ts +8 -37
- package/{cjs → types/node}/CamOverlayPainter/Painter.d.ts +5 -21
- package/types/node/CamOverlayPainter/ResourceManager.d.ts +15 -0
- package/types/node/CamScripterAPICameraEventsGenerator.d.ts +31 -0
- package/types/node/DefaultClient.d.ts +16 -0
- package/{esm → types}/node/HttpRequestSender.d.ts +1 -0
- package/{cjs → types}/node/HttpServer.d.ts +2 -2
- package/types/node/VapixEvents.d.ts +16 -0
- package/{cjs → types}/node/WsClient.d.ts +3 -2
- package/types/node/events/AxisCameraStationEvents.d.ts +12 -0
- package/types/node/events/GenetecAgent.d.ts +16 -0
- package/types/node/index.d.ts +17 -0
- package/types/types/CamOverlayAPI/CamOverlayAPI.d.ts +4321 -0
- package/types/types/CamOverlayAPI/accuweatherSchema.d.ts +84 -0
- package/types/types/CamOverlayAPI/customGraphicsSchema.d.ts +700 -0
- package/types/types/CamOverlayAPI/imagesSchema.d.ts +95 -0
- package/types/types/CamOverlayAPI/index.d.ts +11 -0
- package/types/types/CamOverlayAPI/infotickerSchema.d.ts +96 -0
- package/types/types/CamOverlayAPI/pipSchema.d.ts +125 -0
- package/types/types/CamOverlayAPI/ptzCompassSchema.d.ts +93 -0
- package/types/types/CamOverlayAPI/ptzSchema.d.ts +118 -0
- package/types/types/CamOverlayAPI/scoreBoardSchema.d.ts +357 -0
- package/types/types/CamOverlayAPI/screenSharingSchema.d.ts +58 -0
- package/types/types/CamOverlayAPI/serviceCommonTypes.d.ts +145 -0
- package/types/types/CamOverlayAPI/webCameraSharingSchema.d.ts +58 -0
- package/types/types/CamOverlayDrawingAPI.d.ts +48 -0
- package/types/types/CamOverlayPainter.d.ts +76 -0
- package/types/types/CamScripterAPI.d.ts +130 -0
- package/types/types/CamScripterAPICameraEventsGenerator.d.ts +45 -0
- package/types/types/CamStreamerAPI.d.ts +272 -0
- package/{esm → types}/types/CamSwitcherAPI.d.ts +115 -36
- package/{cjs → types}/types/CamSwitcherEvents.d.ts +77 -0
- package/{esm/events → types/types}/GenetecAgent.d.ts +47 -47
- package/types/types/PlaneTrackerAPI.d.ts +890 -0
- package/{cjs → types}/types/VapixAPI.d.ts +647 -465
- package/types/types/VapixEvents.d.ts +15 -0
- package/{esm → types}/types/common.d.ts +15 -5
- package/types/web/DefaultClient.d.ts +6 -0
- package/cjs/CamOverlayAPI.d.ts +0 -31
- package/cjs/CamOverlayDrawingAPI.d.ts +0 -86
- package/cjs/CamOverlayPainter/Frame.d.ts +0 -96
- package/cjs/CamOverlayPainter/ResourceManager.d.ts +0 -14
- package/cjs/CamOverlayPainter/ResourceManager.js +0 -46
- package/cjs/CamScripterAPI.d.ts +0 -19
- package/cjs/CamScripterAPICameraEventsGenerator.d.ts +0 -74
- package/cjs/CamStreamerAPI.d.ts +0 -16
- package/cjs/CamSwitcherAPI.d.ts +0 -48
- package/cjs/CamSwitcherEvents.d.ts +0 -18
- package/cjs/VapixAPI.d.ts +0 -66
- package/cjs/VapixEvents.d.ts +0 -43
- package/cjs/errors/errors.d.ts +0 -34
- package/cjs/events/AxisCameraStationEvents.d.ts +0 -9
- package/cjs/events/AxisCameraStationEvents.js +0 -48
- package/cjs/events/GenetecAgent.d.ts +0 -174
- package/cjs/events/GenetecAgent.js +0 -123
- package/cjs/index.d.ts +0 -11
- package/cjs/internal/ProxyClient.d.ts +0 -11
- package/cjs/internal/common.d.ts +0 -39
- package/cjs/internal/common.js +0 -27
- package/cjs/node/DefaultClient.d.ts +0 -15
- package/cjs/node/HttpRequestSender.d.ts +0 -28
- package/cjs/node/WsEventClient.d.ts +0 -13
- package/cjs/node/WsEventClient.js +0 -22
- package/cjs/types/CamOverlayAPI.d.ts +0 -188
- package/cjs/types/CamOverlayAPI.js +0 -47
- package/cjs/types/CamScripterAPI.d.ts +0 -67
- package/cjs/types/CamStreamerAPI.d.ts +0 -139
- package/cjs/types/CamSwitcherAPI.d.ts +0 -814
- package/cjs/types/common.d.ts +0 -37
- package/cjs/web/DefaultClient.d.ts +0 -6
- package/cjs/web/index.d.ts +0 -2
- package/esm/CamOverlayAPI.d.ts +0 -31
- package/esm/CamOverlayDrawingAPI.d.ts +0 -86
- package/esm/CamOverlayPainter/Painter.d.ts +0 -48
- package/esm/CamOverlayPainter/ResourceManager.d.ts +0 -14
- package/esm/CamScripterAPI.d.ts +0 -19
- package/esm/CamScripterAPICameraEventsGenerator.d.ts +0 -74
- package/esm/CamStreamerAPI.d.ts +0 -16
- package/esm/CamSwitcherAPI.d.ts +0 -48
- package/esm/CamSwitcherEvents.d.ts +0 -18
- package/esm/VapixAPI.d.ts +0 -66
- package/esm/VapixEvents.d.ts +0 -43
- package/esm/errors/errors.d.ts +0 -34
- package/esm/events/AxisCameraStationEvents.d.ts +0 -9
- package/esm/events/GenetecAgent.js +0 -119
- package/esm/index.d.ts +0 -11
- package/esm/internal/Digest.d.ts +0 -4
- package/esm/internal/ProxyClient.d.ts +0 -11
- package/esm/internal/common.d.ts +0 -39
- package/esm/internal/common.js +0 -20
- package/esm/internal/constants.d.ts +0 -1
- package/esm/internal/transformers.d.ts +0 -5
- package/esm/internal/utils.d.ts +0 -11
- package/esm/internal/versionCompare.d.ts +0 -6
- package/esm/node/DefaultClient.d.ts +0 -15
- package/esm/node/HttpServer.d.ts +0 -21
- package/esm/node/WsClient.d.ts +0 -39
- package/esm/node/WsEventClient.d.ts +0 -13
- package/esm/node/WsEventClient.js +0 -18
- package/esm/node/index.d.ts +0 -2
- package/esm/types/CamOverlayAPI.d.ts +0 -188
- package/esm/types/CamOverlayAPI.js +0 -44
- package/esm/types/CamScripterAPI.d.ts +0 -67
- package/esm/types/CamStreamerAPI.d.ts +0 -139
- package/esm/types/CamSwitcherEvents.d.ts +0 -491
- package/esm/types/VapixAPI.d.ts +0 -1683
- package/esm/web/DefaultClient.d.ts +0 -6
- package/esm/web/WsClient.d.ts +0 -13
- package/esm/web/index.d.ts +0 -2
- /package/{cjs/CreatePackage.d.ts → esm/internal/types.js} +0 -0
- /package/esm/{CreatePackage.d.ts → types/CamOverlayDrawingAPI.js} +0 -0
- /package/{cjs → types}/internal/constants.d.ts +0 -0
- /package/{cjs → types}/internal/transformers.d.ts +0 -0
- /package/{cjs/internal → types/node}/Digest.d.ts +0 -0
- /package/{cjs → types}/web/WsClient.d.ts +0 -0
- /package/{cjs/node → types/web}/index.d.ts +0 -0
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.fieldSchema = exports.customGraphicsSchema = exports.mappingZoneSchema = exports.mappingZonesCountdownSettingsSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
const mappingZonesCommonSchema = zod_1.z.object({
|
|
7
|
+
name: zod_1.z.string(),
|
|
8
|
+
pos_x: zod_1.z.number(),
|
|
9
|
+
pos_y: zod_1.z.number(),
|
|
10
|
+
text: zod_1.z
|
|
11
|
+
.array(zod_1.z.object({
|
|
12
|
+
source: zod_1.z.string(),
|
|
13
|
+
active: zod_1.z.boolean(),
|
|
14
|
+
}))
|
|
15
|
+
.optional(),
|
|
16
|
+
wrapText: zod_1.z.boolean(),
|
|
17
|
+
textLines: zod_1.z.number().positive(),
|
|
18
|
+
textWidth: zod_1.z.number().nonnegative(),
|
|
19
|
+
textAlign: zod_1.z.union([zod_1.z.literal('A_LEFT'), zod_1.z.literal('A_CENTER'), zod_1.z.literal('A_RIGHT')]),
|
|
20
|
+
textVerticalAlign: zod_1.z.union([zod_1.z.literal('VA_TOP'), zod_1.z.literal('VA_CENTER'), zod_1.z.literal('VA_BOTTOM')]),
|
|
21
|
+
textColor: zod_1.z.string(),
|
|
22
|
+
font: serviceCommonTypes_1.fontSchema,
|
|
23
|
+
fontSize: zod_1.z.number().nonnegative(),
|
|
24
|
+
switchingTime: zod_1.z.number().nonnegative(),
|
|
25
|
+
});
|
|
26
|
+
exports.mappingZonesCountdownSettingsSchema = zod_1.z.object({
|
|
27
|
+
startDate: zod_1.z.number().nonnegative(),
|
|
28
|
+
targetDate: zod_1.z.number().nonnegative(),
|
|
29
|
+
countdown: zod_1.z.boolean(),
|
|
30
|
+
countup: zod_1.z.boolean(),
|
|
31
|
+
displayDay: zod_1.z.boolean(),
|
|
32
|
+
displayHour: zod_1.z.boolean(),
|
|
33
|
+
displayMinute: zod_1.z.boolean(),
|
|
34
|
+
displaySeconds: zod_1.z.boolean(),
|
|
35
|
+
idleText: zod_1.z.string(),
|
|
36
|
+
hideZeros: zod_1.z.boolean(),
|
|
37
|
+
delimiter: zod_1.z.union([zod_1.z.literal('colon'), zod_1.z.literal('letters')]),
|
|
38
|
+
suffixSeconds: zod_1.z.string(),
|
|
39
|
+
suffixMinute: zod_1.z.string(),
|
|
40
|
+
suffixHour: zod_1.z.string(),
|
|
41
|
+
suffixDay: zod_1.z.string(),
|
|
42
|
+
loop: zod_1.z.boolean(),
|
|
43
|
+
loopPeriod: zod_1.z.number().nonnegative(),
|
|
44
|
+
waitingPeriod: zod_1.z.number().nonnegative(),
|
|
45
|
+
});
|
|
46
|
+
const mappingZonePlainSchema = mappingZonesCommonSchema.extend({
|
|
47
|
+
type: zod_1.z.literal('plain'),
|
|
48
|
+
});
|
|
49
|
+
const mappingZoneCountdownSchema = mappingZonesCommonSchema.extend({
|
|
50
|
+
type: zod_1.z.literal('countdown'),
|
|
51
|
+
settings: exports.mappingZonesCountdownSettingsSchema,
|
|
52
|
+
});
|
|
53
|
+
exports.mappingZoneSchema = zod_1.z.discriminatedUnion('type', [mappingZonePlainSchema, mappingZoneCountdownSchema]);
|
|
54
|
+
exports.customGraphicsSchema = serviceCommonTypes_1.serviceCommonSchema.extend({
|
|
55
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.customGraphics),
|
|
56
|
+
pos_x: zod_1.z.number(),
|
|
57
|
+
pos_y: zod_1.z.number(),
|
|
58
|
+
coordSystem: serviceCommonTypes_1.coordinateSystemSchema,
|
|
59
|
+
clockFormat: zod_1.z.union([zod_1.z.literal('12h'), zod_1.z.literal('24h')]),
|
|
60
|
+
background: zod_1.z.enum(['custom', 'image']),
|
|
61
|
+
image: zod_1.z.string(),
|
|
62
|
+
customAreaColor: zod_1.z.string(),
|
|
63
|
+
customAreaWidth: zod_1.z.number().nonnegative(),
|
|
64
|
+
customAreaHeight: zod_1.z.number().nonnegative(),
|
|
65
|
+
customAreaCorners: zod_1.z.union([zod_1.z.literal('sharp'), zod_1.z.literal('rounded')]),
|
|
66
|
+
mappingZones: zod_1.z.array(exports.mappingZoneSchema),
|
|
67
|
+
});
|
|
68
|
+
exports.fieldSchema = zod_1.z.object({
|
|
69
|
+
field_name: zod_1.z.string(),
|
|
70
|
+
text: zod_1.z.string(),
|
|
71
|
+
color: zod_1.z.string().optional(),
|
|
72
|
+
});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.imagesSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.imagesSchema = serviceCommonTypes_1.serviceCommonSchema.extend({
|
|
7
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.images),
|
|
8
|
+
overlayList: zod_1.z.array(serviceCommonTypes_1.overlaySchema),
|
|
9
|
+
});
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./CamOverlayAPI"), exports);
|
|
18
|
+
__exportStar(require("./serviceCommonTypes"), exports);
|
|
19
|
+
__exportStar(require("./accuweatherSchema"), exports);
|
|
20
|
+
__exportStar(require("./customGraphicsSchema"), exports);
|
|
21
|
+
__exportStar(require("./imagesSchema"), exports);
|
|
22
|
+
__exportStar(require("./infotickerSchema"), exports);
|
|
23
|
+
__exportStar(require("./pipSchema"), exports);
|
|
24
|
+
__exportStar(require("./ptzCompassSchema"), exports);
|
|
25
|
+
__exportStar(require("./ptzSchema"), exports);
|
|
26
|
+
__exportStar(require("./screenSharingSchema"), exports);
|
|
27
|
+
__exportStar(require("./webCameraSharingSchema"), exports);
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.infoTickerSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.infoTickerSchema = serviceCommonTypes_1.serviceCommonSchema.extend({
|
|
7
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.infoticker),
|
|
8
|
+
showClock: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
9
|
+
clockType: zod_1.z.union([zod_1.z.literal('12h'), zod_1.z.literal('24h')]),
|
|
10
|
+
textColor: zod_1.z.string(),
|
|
11
|
+
bgColor: zod_1.z.string(),
|
|
12
|
+
weatherLocation: zod_1.z.string(),
|
|
13
|
+
weatherLocationName: zod_1.z.string(),
|
|
14
|
+
weatherLang: serviceCommonTypes_1.languageSchema,
|
|
15
|
+
weatherUnits: serviceCommonTypes_1.weatherUnitSchema,
|
|
16
|
+
numberOfLines: zod_1.z.number().positive(),
|
|
17
|
+
switchingTime: zod_1.z.number().nonnegative(),
|
|
18
|
+
crawlLeft: zod_1.z.boolean(),
|
|
19
|
+
crawlSpeed: zod_1.z.number(),
|
|
20
|
+
coordSystem: zod_1.z.union([zod_1.z.literal('top'), zod_1.z.literal('bottom')]),
|
|
21
|
+
pos_y: zod_1.z.number(),
|
|
22
|
+
font: serviceCommonTypes_1.fontSchema,
|
|
23
|
+
fontSize: zod_1.z.number().nonnegative(),
|
|
24
|
+
sourceType: zod_1.z.union([zod_1.z.literal('text'), zod_1.z.literal('url')]),
|
|
25
|
+
source: zod_1.z.string(),
|
|
26
|
+
});
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.pipSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.pipSchema = serviceCommonTypes_1.serviceCommonSchema.extend({
|
|
7
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.pip),
|
|
8
|
+
coordSystem: serviceCommonTypes_1.coordinateSystemSchema,
|
|
9
|
+
pos_x: zod_1.z.number(),
|
|
10
|
+
pos_y: zod_1.z.number(),
|
|
11
|
+
fps: zod_1.z.number(),
|
|
12
|
+
compression: zod_1.z.number().nonnegative(),
|
|
13
|
+
screenSize: zod_1.z.number().nonnegative(),
|
|
14
|
+
source_type: zod_1.z.union([zod_1.z.literal('axis_camera'), zod_1.z.literal('mjpeg_url')]),
|
|
15
|
+
mjpeg_url: zod_1.z.union([zod_1.z.string().url(), zod_1.z.literal('')]),
|
|
16
|
+
camera_ip: zod_1.z.union([zod_1.z.string().ip(), zod_1.z.literal('')]),
|
|
17
|
+
camera_port: zod_1.z.number().nonnegative(),
|
|
18
|
+
camera_user: zod_1.z.string(),
|
|
19
|
+
camera_pass: zod_1.z.string(),
|
|
20
|
+
camera_width: zod_1.z.number().nonnegative(),
|
|
21
|
+
camera_height: zod_1.z.number().nonnegative(),
|
|
22
|
+
camera_view_area: zod_1.z.string(),
|
|
23
|
+
camera_overlay_params: zod_1.z.union([
|
|
24
|
+
zod_1.z.literal('overlays=off'),
|
|
25
|
+
zod_1.z.literal('overlays=all'),
|
|
26
|
+
zod_1.z.literal('overlays=text'),
|
|
27
|
+
zod_1.z.literal('overlays=image'),
|
|
28
|
+
zod_1.z.literal('overlays=application'),
|
|
29
|
+
]),
|
|
30
|
+
rotate: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(90), zod_1.z.literal(180), zod_1.z.literal(270)]),
|
|
31
|
+
dewarping: zod_1.z.object({
|
|
32
|
+
enabled: zod_1.z.boolean(),
|
|
33
|
+
rectangle: zod_1.z.array(zod_1.z.tuple([zod_1.z.number(), zod_1.z.number()])),
|
|
34
|
+
aspectRatioCorrection: zod_1.z.number(),
|
|
35
|
+
}),
|
|
36
|
+
borderColor: zod_1.z.string(),
|
|
37
|
+
borderWidth: zod_1.z.number(),
|
|
38
|
+
scale: zod_1.z.number(),
|
|
39
|
+
});
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ptzCompassSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.ptzCompassSchema = serviceCommonTypes_1.serviceCommonSchema.extend({
|
|
7
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.ptzCompass),
|
|
8
|
+
pos_x: zod_1.z.number(),
|
|
9
|
+
pos_y: zod_1.z.number(),
|
|
10
|
+
coordSystem: serviceCommonTypes_1.coordinateSystemSchema,
|
|
11
|
+
scale: zod_1.z.number().nonnegative(),
|
|
12
|
+
type: zod_1.z.union([zod_1.z.literal('compass'), zod_1.z.literal('map'), zod_1.z.literal('image')]),
|
|
13
|
+
image: zod_1.z.union([zod_1.z.string().url(), zod_1.z.literal('')]),
|
|
14
|
+
northPan: zod_1.z.number(),
|
|
15
|
+
cameraPosX: zod_1.z.number(),
|
|
16
|
+
cameraPosY: zod_1.z.number(),
|
|
17
|
+
colorScheme: zod_1.z.enum(['black', 'white', 'orange']),
|
|
18
|
+
generalLng: zod_1.z.number().optional(),
|
|
19
|
+
generalLat: zod_1.z.number().optional(),
|
|
20
|
+
generalZoom: zod_1.z.number().nonnegative().optional(),
|
|
21
|
+
generalMapType: zod_1.z.string().optional(),
|
|
22
|
+
generalIframeWidth: zod_1.z.number().optional(),
|
|
23
|
+
generalIframeHeight: zod_1.z.number().optional(),
|
|
24
|
+
generalAddress: zod_1.z.string().optional(),
|
|
25
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ptzSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.ptzSchema = serviceCommonTypes_1.serviceCommonSchema.extend({
|
|
7
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.ptz),
|
|
8
|
+
ptz_positions: zod_1.z.record(zod_1.z.string(), zod_1.z.object({
|
|
9
|
+
overlayList: zod_1.z.array(serviceCommonTypes_1.overlaySchema.omit({ active: true, fps: true })),
|
|
10
|
+
loop: zod_1.z.boolean(),
|
|
11
|
+
})),
|
|
12
|
+
});
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.scoreOverviewSchema = exports.baseballScoreBoardAutomaticSchema = exports.baseballScoreBoardSchema = exports.scoreBoardSchema = exports.sportFontSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.sportFontSchema = zod_1.z.union([
|
|
7
|
+
zod_1.z.literal('classic'),
|
|
8
|
+
zod_1.z.custom((val) => {
|
|
9
|
+
return typeof val === 'string';
|
|
10
|
+
}),
|
|
11
|
+
]);
|
|
12
|
+
exports.scoreBoardSchema = zod_1.z.object({
|
|
13
|
+
id: zod_1.z.number().nonnegative(),
|
|
14
|
+
enabled: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
15
|
+
schedule: zod_1.z.string().optional(),
|
|
16
|
+
cameraList: zod_1.z.array(zod_1.z.number()),
|
|
17
|
+
zIndex: zod_1.z.number().nonnegative(),
|
|
18
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.scoreBoard),
|
|
19
|
+
pos_x: zod_1.z.number(),
|
|
20
|
+
pos_y: zod_1.z.number(),
|
|
21
|
+
coordSystem: serviceCommonTypes_1.coordinateSystemSchema,
|
|
22
|
+
width: zod_1.z.number(),
|
|
23
|
+
height: zod_1.z.number(),
|
|
24
|
+
scale: zod_1.z.number(),
|
|
25
|
+
teamHomeShortname: zod_1.z.string(),
|
|
26
|
+
teamGuestShortname: zod_1.z.string(),
|
|
27
|
+
teamHomeBackgroundColor: zod_1.z.string(),
|
|
28
|
+
teamGuestBackgroundColor: zod_1.z.string(),
|
|
29
|
+
teamHomeTextColor: zod_1.z.string(),
|
|
30
|
+
teamGuestTextColor: zod_1.z.string(),
|
|
31
|
+
teamHomeImgPath: zod_1.z.string(),
|
|
32
|
+
teamGuestImgPath: zod_1.z.string(),
|
|
33
|
+
teamHomeCurrentScore: zod_1.z.number(),
|
|
34
|
+
teamGuestCurrentScore: zod_1.z.number(),
|
|
35
|
+
baseTimeTimestamp: zod_1.z.number(),
|
|
36
|
+
baseTimePlaytime: zod_1.z.number(),
|
|
37
|
+
currentPeriodPlaytime: zod_1.z.number(),
|
|
38
|
+
timeIsRunning: zod_1.z.boolean(),
|
|
39
|
+
currentPeriodLength: zod_1.z.number(),
|
|
40
|
+
currentPeriod: zod_1.z.number(),
|
|
41
|
+
font: exports.sportFontSchema.default('classic'),
|
|
42
|
+
});
|
|
43
|
+
exports.baseballScoreBoardSchema = zod_1.z.object({
|
|
44
|
+
id: zod_1.z.number().nonnegative(),
|
|
45
|
+
enabled: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
46
|
+
schedule: zod_1.z.string().optional(),
|
|
47
|
+
cameraList: zod_1.z.array(zod_1.z.number()),
|
|
48
|
+
zIndex: zod_1.z.number().nonnegative(),
|
|
49
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.baseballScoreBoard),
|
|
50
|
+
pos_x: zod_1.z.number(),
|
|
51
|
+
pos_y: zod_1.z.number(),
|
|
52
|
+
coordSystem: serviceCommonTypes_1.coordinateSystemSchema,
|
|
53
|
+
width: zod_1.z.number(),
|
|
54
|
+
height: zod_1.z.number(),
|
|
55
|
+
scale: zod_1.z.number(),
|
|
56
|
+
matchFinished: zod_1.z.boolean(),
|
|
57
|
+
bases: zod_1.z.tuple([zod_1.z.boolean(), zod_1.z.boolean(), zod_1.z.boolean()]),
|
|
58
|
+
homeInning: zod_1.z.boolean(),
|
|
59
|
+
inning: zod_1.z.number().nonnegative(),
|
|
60
|
+
outs: zod_1.z.number().nonnegative(),
|
|
61
|
+
balls: zod_1.z.number().nonnegative(),
|
|
62
|
+
strikes: zod_1.z.number().nonnegative(),
|
|
63
|
+
baseTimeTimestamp: zod_1.z.number(),
|
|
64
|
+
baseTimePlaytime: zod_1.z.number(),
|
|
65
|
+
timeIsRunning: zod_1.z.boolean(),
|
|
66
|
+
teamHomeShortname: zod_1.z.string(),
|
|
67
|
+
teamGuestShortname: zod_1.z.string(),
|
|
68
|
+
teamHomeBackgroundColor: zod_1.z.string(),
|
|
69
|
+
teamGuestBackgroundColor: zod_1.z.string(),
|
|
70
|
+
teamHomeTextColor: zod_1.z.string(),
|
|
71
|
+
teamGuestTextColor: zod_1.z.string(),
|
|
72
|
+
teamHomeCurrentScore: zod_1.z.number(),
|
|
73
|
+
teamGuestCurrentScore: zod_1.z.number(),
|
|
74
|
+
footerImgPath: zod_1.z.string().optional(),
|
|
75
|
+
footerText: zod_1.z.string().optional(),
|
|
76
|
+
footerBackgroundColor: zod_1.z.string().optional(),
|
|
77
|
+
footerTextColor: zod_1.z.string().optional(),
|
|
78
|
+
font: exports.sportFontSchema.default('classic'),
|
|
79
|
+
});
|
|
80
|
+
exports.baseballScoreBoardAutomaticSchema = zod_1.z.object({
|
|
81
|
+
id: zod_1.z.number().nonnegative(),
|
|
82
|
+
enabled: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
83
|
+
schedule: zod_1.z.string().optional(),
|
|
84
|
+
cameraList: zod_1.z.array(zod_1.z.number()),
|
|
85
|
+
zIndex: zod_1.z.number().nonnegative(),
|
|
86
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.myBallBaseballWidgets),
|
|
87
|
+
width: zod_1.z.number(),
|
|
88
|
+
height: zod_1.z.number(),
|
|
89
|
+
scale: zod_1.z.number(),
|
|
90
|
+
matchDetailLink: zod_1.z.string(),
|
|
91
|
+
matchListLink: zod_1.z.string(),
|
|
92
|
+
mirrored: zod_1.z.boolean(),
|
|
93
|
+
pregameWidgetText: zod_1.z.string(),
|
|
94
|
+
teamHomeBackgroundColor: zod_1.z.string(),
|
|
95
|
+
teamGuestBackgroundColor: zod_1.z.string(),
|
|
96
|
+
teamHomeTextColor: zod_1.z.string(),
|
|
97
|
+
teamGuestTextColor: zod_1.z.string(),
|
|
98
|
+
homeLogoPath: zod_1.z.string(),
|
|
99
|
+
guestLogoPath: zod_1.z.string(),
|
|
100
|
+
footerImgPath: zod_1.z.string().optional(),
|
|
101
|
+
footerText: zod_1.z.string().optional(),
|
|
102
|
+
footerBackgroundColor: zod_1.z.string().optional(),
|
|
103
|
+
footerTextColor: zod_1.z.string().optional(),
|
|
104
|
+
font: exports.sportFontSchema.default('classic'),
|
|
105
|
+
});
|
|
106
|
+
exports.scoreOverviewSchema = zod_1.z.object({
|
|
107
|
+
id: zod_1.z.number().nonnegative(),
|
|
108
|
+
enabled: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
109
|
+
cameraList: zod_1.z.array(zod_1.z.number()),
|
|
110
|
+
zIndex: zod_1.z.number().nonnegative(),
|
|
111
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.scoreOverview),
|
|
112
|
+
pos_x: zod_1.z.number(),
|
|
113
|
+
pos_y: zod_1.z.number(),
|
|
114
|
+
coordSystem: serviceCommonTypes_1.coordinateSystemSchema,
|
|
115
|
+
width: zod_1.z.number(),
|
|
116
|
+
height: zod_1.z.number(),
|
|
117
|
+
scale: zod_1.z.number(),
|
|
118
|
+
teamHomeName: zod_1.z.string(),
|
|
119
|
+
teamGuestName: zod_1.z.string(),
|
|
120
|
+
teamHomeBackgroundColor: zod_1.z.string(),
|
|
121
|
+
teamGuestBackgroundColor: zod_1.z.string(),
|
|
122
|
+
teamHomeTextColor: zod_1.z.string(),
|
|
123
|
+
teamGuestTextColor: zod_1.z.string(),
|
|
124
|
+
teamHomeImgPath: zod_1.z.string(),
|
|
125
|
+
teamGuestImgPath: zod_1.z.string(),
|
|
126
|
+
teamHomeCurrentScore: zod_1.z.number(),
|
|
127
|
+
teamGuestCurrentScore: zod_1.z.number(),
|
|
128
|
+
scoreVisible: zod_1.z.boolean(),
|
|
129
|
+
description: zod_1.z.string(),
|
|
130
|
+
textFont: exports.sportFontSchema.default('classic'),
|
|
131
|
+
scoreFont: zod_1.z.literal('classic'),
|
|
132
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.screenSharingSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.screenSharingSchema = serviceCommonTypes_1.sharingSchema.extend({
|
|
7
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.screenSharing),
|
|
8
|
+
});
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.overlaySchema = exports.sharingSchema = exports.serviceCommonSchema = exports.weatherUnitSchema = exports.fontSchema = exports.languageSchema = exports.coordinateSystemSchema = exports.serviceNames = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.serviceNames = {
|
|
6
|
+
accuweather: 'accuweather',
|
|
7
|
+
infoticker: 'infoticker',
|
|
8
|
+
customGraphics: 'customGraphics',
|
|
9
|
+
ptzCompass: 'ptzCompass',
|
|
10
|
+
images: 'images',
|
|
11
|
+
ptz: 'ptz',
|
|
12
|
+
pip: 'pip',
|
|
13
|
+
screenSharing: 'screenSharing',
|
|
14
|
+
web_camera: 'web_camera',
|
|
15
|
+
scoreBoard: 'scoreBoard',
|
|
16
|
+
baseballScoreBoard: 'baseballScoreBoard',
|
|
17
|
+
myBallBaseballWidgets: 'myBallBaseballWidgets',
|
|
18
|
+
scoreOverview: 'scoreOverview',
|
|
19
|
+
};
|
|
20
|
+
exports.coordinateSystemSchema = zod_1.z.union([
|
|
21
|
+
zod_1.z.literal('top_left'),
|
|
22
|
+
zod_1.z.literal('top'),
|
|
23
|
+
zod_1.z.literal('top_right'),
|
|
24
|
+
zod_1.z.literal('left'),
|
|
25
|
+
zod_1.z.literal('center'),
|
|
26
|
+
zod_1.z.literal('right'),
|
|
27
|
+
zod_1.z.literal('bottom_left'),
|
|
28
|
+
zod_1.z.literal('bottom'),
|
|
29
|
+
zod_1.z.literal('bottom_right'),
|
|
30
|
+
]);
|
|
31
|
+
exports.languageSchema = zod_1.z.union([
|
|
32
|
+
zod_1.z.literal('en-us'),
|
|
33
|
+
zod_1.z.literal('fr-fr'),
|
|
34
|
+
zod_1.z.literal('ja-jp'),
|
|
35
|
+
zod_1.z.literal('pt-pt'),
|
|
36
|
+
zod_1.z.literal('es-es'),
|
|
37
|
+
zod_1.z.literal('de-de'),
|
|
38
|
+
zod_1.z.literal('ko-kr'),
|
|
39
|
+
zod_1.z.literal('zh-hk'),
|
|
40
|
+
zod_1.z.literal('zh-cn'),
|
|
41
|
+
zod_1.z.literal('nl-nl'),
|
|
42
|
+
zod_1.z.literal('cs-cz'),
|
|
43
|
+
zod_1.z.literal('ru-ru'),
|
|
44
|
+
zod_1.z.literal('sv-se'),
|
|
45
|
+
]);
|
|
46
|
+
exports.fontSchema = zod_1.z.union([
|
|
47
|
+
zod_1.z.literal('classic'),
|
|
48
|
+
zod_1.z.literal('digital'),
|
|
49
|
+
zod_1.z.custom((val) => {
|
|
50
|
+
return typeof val === 'string';
|
|
51
|
+
}),
|
|
52
|
+
]);
|
|
53
|
+
exports.weatherUnitSchema = zod_1.z.union([zod_1.z.literal('Metric'), zod_1.z.literal('Imperial')]);
|
|
54
|
+
exports.serviceCommonSchema = zod_1.z.object({
|
|
55
|
+
id: zod_1.z.number().nonnegative(),
|
|
56
|
+
enabled: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
57
|
+
automationType: zod_1.z.union([
|
|
58
|
+
zod_1.z.literal('time'),
|
|
59
|
+
zod_1.z.literal('manual'),
|
|
60
|
+
zod_1.z.literal('schedule'),
|
|
61
|
+
zod_1.z.custom((val) => {
|
|
62
|
+
return typeof val === 'string' ? /^input\d+$/.test(val) : false;
|
|
63
|
+
}),
|
|
64
|
+
]),
|
|
65
|
+
invertInput: zod_1.z.boolean().optional(),
|
|
66
|
+
cameraList: zod_1.z.array(zod_1.z.number()),
|
|
67
|
+
camera: zod_1.z.number().nonnegative().optional(),
|
|
68
|
+
schedule: zod_1.z.string().optional(),
|
|
69
|
+
customName: zod_1.z.string(),
|
|
70
|
+
zIndex: zod_1.z.number().optional(),
|
|
71
|
+
width: zod_1.z.number().nonnegative(),
|
|
72
|
+
height: zod_1.z.number().nonnegative(),
|
|
73
|
+
});
|
|
74
|
+
exports.sharingSchema = exports.serviceCommonSchema.extend({
|
|
75
|
+
pos_x: zod_1.z.number().nonnegative(),
|
|
76
|
+
pos_y: zod_1.z.number().nonnegative(),
|
|
77
|
+
coordSystem: exports.coordinateSystemSchema,
|
|
78
|
+
screenSize: zod_1.z.number().positive(),
|
|
79
|
+
fps: zod_1.z.number(),
|
|
80
|
+
});
|
|
81
|
+
exports.overlaySchema = zod_1.z.object({
|
|
82
|
+
active: zod_1.z.boolean(),
|
|
83
|
+
coordSystem: exports.coordinateSystemSchema,
|
|
84
|
+
pos_x: zod_1.z.number(),
|
|
85
|
+
pos_y: zod_1.z.number(),
|
|
86
|
+
imgPath: zod_1.z.string(),
|
|
87
|
+
imgName: zod_1.z.string(),
|
|
88
|
+
duration: zod_1.z.number(),
|
|
89
|
+
scale: zod_1.z.number(),
|
|
90
|
+
fps: zod_1.z.number().optional(),
|
|
91
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.webCameraSharingSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const serviceCommonTypes_1 = require("./serviceCommonTypes");
|
|
6
|
+
exports.webCameraSharingSchema = serviceCommonTypes_1.sharingSchema.extend({
|
|
7
|
+
name: zod_1.z.literal(serviceCommonTypes_1.serviceNames.web_camera),
|
|
8
|
+
});
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.COORD = void 0;
|
|
4
|
+
exports.COORD = {
|
|
5
|
+
top_left: [-1, -1],
|
|
6
|
+
center_left: [-1, 0],
|
|
7
|
+
bottom_left: [-1, 1],
|
|
8
|
+
top_center: [0, -1],
|
|
9
|
+
center: [0, 0],
|
|
10
|
+
bottom_center: [0, 1],
|
|
11
|
+
top_right: [1, -1],
|
|
12
|
+
center_right: [1, 0],
|
|
13
|
+
bottom_right: [1, 1],
|
|
14
|
+
};
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.cameraTimeResponseSchema = exports.camscripterApiResponseSchema = exports.cameraStorageSchema = exports.packageConfigSchema = exports.packageInfoListSchema = exports.nodeStateSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
|
+
exports.nodeStateSchema = zod_1.z.object({
|
|
6
|
+
node_state: zod_1.z.union([zod_1.z.literal('OK'), zod_1.z.literal('NOT_INSTALLED'), zod_1.z.literal('NOT_FOUND')]),
|
|
7
|
+
});
|
|
5
8
|
exports.packageInfoListSchema = zod_1.z.array(zod_1.z.object({
|
|
6
9
|
storage: zod_1.z.union([zod_1.z.literal('SD_CARD'), zod_1.z.literal('INTERNAL')]),
|
|
7
10
|
manifest: zod_1.z.object({
|
|
@@ -9,12 +12,24 @@ exports.packageInfoListSchema = zod_1.z.array(zod_1.z.object({
|
|
|
9
12
|
package_menu_name: zod_1.z.string(),
|
|
10
13
|
package_version: zod_1.z.string(),
|
|
11
14
|
vendor: zod_1.z.string(),
|
|
12
|
-
required_camscripter_version: zod_1.z.string(),
|
|
13
|
-
required_camscripter_rbi_version: zod_1.z.string(),
|
|
15
|
+
required_camscripter_version: zod_1.z.string().optional(),
|
|
16
|
+
required_camscripter_rbi_version: zod_1.z.string().optional(),
|
|
14
17
|
ui_link: zod_1.z.string(),
|
|
15
18
|
}),
|
|
16
19
|
}));
|
|
17
|
-
exports.
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
})
|
|
20
|
+
exports.packageConfigSchema = zod_1.z.record(zod_1.z.string(), zod_1.z.object({ enabled: zod_1.z.boolean() }));
|
|
21
|
+
exports.cameraStorageSchema = zod_1.z.union([
|
|
22
|
+
zod_1.z.tuple([
|
|
23
|
+
zod_1.z.object({ type: zod_1.z.literal('INTERNAL'), capacity_mb: zod_1.z.number() }),
|
|
24
|
+
zod_1.z.object({ type: zod_1.z.literal('SD_CARD'), capacity_mb: zod_1.z.number() }),
|
|
25
|
+
]),
|
|
26
|
+
zod_1.z.tuple([zod_1.z.object({ type: zod_1.z.literal('INTERNAL'), capacity_mb: zod_1.z.number() })]),
|
|
27
|
+
]);
|
|
28
|
+
exports.camscripterApiResponseSchema = zod_1.z.object({
|
|
29
|
+
status: zod_1.z.number(),
|
|
30
|
+
message: zod_1.z.string(),
|
|
31
|
+
});
|
|
32
|
+
exports.cameraTimeResponseSchema = zod_1.z.object({
|
|
33
|
+
state: zod_1.z.boolean(),
|
|
34
|
+
code: zod_1.z.number(),
|
|
35
|
+
});
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.camstreamerServerResponseSchema = exports.cameraStreamResponseSchema = exports.streamSchema = exports.cameraStreamSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
|
-
exports.
|
|
5
|
+
exports.cameraStreamSchema = zod_1.z.object({
|
|
6
6
|
enabled: zod_1.z.string(),
|
|
7
7
|
active: zod_1.z.string(),
|
|
8
8
|
audioSource: zod_1.z.string(),
|
|
@@ -25,4 +25,35 @@ exports.streamAttributesSchema = zod_1.z.object({
|
|
|
25
25
|
startTime: zod_1.z.string(),
|
|
26
26
|
stopTime: zod_1.z.string(),
|
|
27
27
|
});
|
|
28
|
-
exports.
|
|
28
|
+
exports.streamSchema = zod_1.z.object({
|
|
29
|
+
enabled: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
30
|
+
active: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
31
|
+
audioSource: zod_1.z.string(),
|
|
32
|
+
avSyncMsec: zod_1.z.number().int(),
|
|
33
|
+
internalVapixParameters: zod_1.z.string(),
|
|
34
|
+
userVapixParameters: zod_1.z.string(),
|
|
35
|
+
outputParameters: zod_1.z.string(),
|
|
36
|
+
outputType: zod_1.z.union([zod_1.z.literal('video'), zod_1.z.literal('images'), zod_1.z.literal('none')]),
|
|
37
|
+
mediaServerUrl: zod_1.z.string(),
|
|
38
|
+
inputType: zod_1.z.union([zod_1.z.literal('CSw'), zod_1.z.literal('CRS'), zod_1.z.literal('RTSP_URL')]),
|
|
39
|
+
inputUrl: zod_1.z.string(),
|
|
40
|
+
forceStereo: zod_1.z.union([zod_1.z.literal(0), zod_1.z.literal(1)]),
|
|
41
|
+
streamDelay: zod_1.z.number().nullable(),
|
|
42
|
+
statusLed: zod_1.z.number(),
|
|
43
|
+
statusPort: zod_1.z.string(),
|
|
44
|
+
callApi: zod_1.z.number().int(),
|
|
45
|
+
trigger: zod_1.z.string(),
|
|
46
|
+
schedule: zod_1.z.string(),
|
|
47
|
+
prepareAhead: zod_1.z.number().int(),
|
|
48
|
+
startTime: zod_1.z.number().nullable(),
|
|
49
|
+
stopTime: zod_1.z.number().nullable(),
|
|
50
|
+
});
|
|
51
|
+
exports.cameraStreamResponseSchema = zod_1.z.object({
|
|
52
|
+
data: exports.cameraStreamSchema,
|
|
53
|
+
code: zod_1.z.number(),
|
|
54
|
+
message: zod_1.z.string(),
|
|
55
|
+
});
|
|
56
|
+
exports.camstreamerServerResponseSchema = zod_1.z.object({
|
|
57
|
+
code: zod_1.z.number(),
|
|
58
|
+
message: zod_1.z.string(),
|
|
59
|
+
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.clipListSchema = exports.playlistQueueSchema = exports.trackerSaveLoadSchema = exports.trackerSaveSchema = exports.playlistSaveLoadSchema = exports.clipSaveLoadSchema = exports.clipSaveSchema = exports.streamSaveLoadSchema = exports.audioPushInfoSchema = exports.outputInfoSchema = exports.storageInfoListSchema = void 0;
|
|
3
|
+
exports.secondaryAudioSettingsSchema = exports.globalAudioSettingsSchema = exports.globalAudioSettingsTypeSchema = exports.cameraOptionsSchema = exports.bitrateVapixParamsSchema = exports.bitrateModeSchema = exports.clipListSchema = exports.playlistQueueSchema = exports.trackerSaveLoadSchema = exports.trackerSaveSchema = exports.playlistSaveLoadSchema = exports.clipSaveLoadSchema = exports.clipSaveSchema = exports.streamSaveLoadSchema = exports.audioPushInfoSchema = exports.outputInfoSchema = exports.storageInfoListSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const transformers_1 = require("../internal/transformers");
|
|
6
6
|
const common_1 = require("./common");
|
|
@@ -135,3 +135,40 @@ exports.clipListSchema = zod_1.z.object({
|
|
|
135
135
|
])),
|
|
136
136
|
})),
|
|
137
137
|
});
|
|
138
|
+
exports.bitrateModeSchema = zod_1.z.union([zod_1.z.literal('VBR'), zod_1.z.literal('MBR'), zod_1.z.literal('ABR')]);
|
|
139
|
+
exports.bitrateVapixParamsSchema = zod_1.z.object({
|
|
140
|
+
bitrateMode: exports.bitrateModeSchema,
|
|
141
|
+
maximumBitRate: zod_1.z.number(),
|
|
142
|
+
retentionTime: zod_1.z.number(),
|
|
143
|
+
bitRateLimit: zod_1.z.number(),
|
|
144
|
+
});
|
|
145
|
+
exports.cameraOptionsSchema = exports.bitrateVapixParamsSchema
|
|
146
|
+
.extend({
|
|
147
|
+
resolution: zod_1.z.string(),
|
|
148
|
+
h264Profile: common_1.h264ProfileSchema,
|
|
149
|
+
fps: zod_1.z.number(),
|
|
150
|
+
compression: zod_1.z.number().min(0).max(100),
|
|
151
|
+
govLength: zod_1.z.number(),
|
|
152
|
+
bitrateVapixParams: zod_1.z.string().nullable(),
|
|
153
|
+
audioSampleRate: zod_1.z.number(),
|
|
154
|
+
audioChannelCount: common_1.audioChannelCountSchema,
|
|
155
|
+
keyboard: zod_1.z.object({
|
|
156
|
+
fromSource: common_1.keyboardShortcutSchema,
|
|
157
|
+
none: common_1.keyboardShortcutSchema,
|
|
158
|
+
}),
|
|
159
|
+
})
|
|
160
|
+
.partial();
|
|
161
|
+
exports.globalAudioSettingsTypeSchema = zod_1.z.union([zod_1.z.literal('fromSource'), zod_1.z.literal('source')]);
|
|
162
|
+
exports.globalAudioSettingsSchema = zod_1.z.object({
|
|
163
|
+
type: exports.globalAudioSettingsTypeSchema,
|
|
164
|
+
source: zod_1.z.string(),
|
|
165
|
+
storage: zod_1.z.string().optional(),
|
|
166
|
+
});
|
|
167
|
+
exports.secondaryAudioSettingsSchema = zod_1.z.object({
|
|
168
|
+
type: zod_1.z.union([zod_1.z.literal('CLIP'), zod_1.z.literal('STREAM'), zod_1.z.literal('NONE')]),
|
|
169
|
+
streamName: zod_1.z.string().optional(),
|
|
170
|
+
clipName: zod_1.z.string().optional(),
|
|
171
|
+
storage: common_1.storageTypeSchema,
|
|
172
|
+
secondaryAudioLevel: zod_1.z.number(),
|
|
173
|
+
masterAudioLevel: zod_1.z.number(),
|
|
174
|
+
});
|
|
@@ -19,6 +19,14 @@ const cswEventsDataSchema = zod_1.z.discriminatedUnion('type', [
|
|
|
19
19
|
clip_name: zod_1.z.string().optional(),
|
|
20
20
|
master_audio: zod_1.z.boolean(),
|
|
21
21
|
}),
|
|
22
|
+
zod_1.z.object({
|
|
23
|
+
type: zod_1.z.literal('StreamSwitchVideoError'),
|
|
24
|
+
playlist_name: zod_1.z.string(),
|
|
25
|
+
playlist_active_stream: zod_1.z.number(),
|
|
26
|
+
stream_name: zod_1.z.string().optional(),
|
|
27
|
+
clip_name: zod_1.z.string().optional(),
|
|
28
|
+
info: zod_1.z.string(),
|
|
29
|
+
}),
|
|
22
30
|
zod_1.z.object({
|
|
23
31
|
type: zod_1.z.literal('StreamSwitchAudioError'),
|
|
24
32
|
stream_name: zod_1.z.string().optional(),
|