camstreamerlib 4.0.0-beta.7 → 4.0.0-beta.71
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 +143 -38
- package/cjs/CamOverlayAPI.d.ts +863 -27
- package/cjs/CamOverlayAPI.js +135 -92
- package/cjs/CamScripterAPI.d.ts +44 -17
- package/cjs/CamScripterAPI.js +52 -42
- package/cjs/CamStreamerAPI.d.ts +62 -14
- package/cjs/CamStreamerAPI.js +82 -39
- package/cjs/CamSwitcherAPI.d.ts +158 -43
- package/cjs/CamSwitcherAPI.js +138 -122
- package/cjs/PlaneTrackerAPI.d.ts +233 -0
- package/cjs/PlaneTrackerAPI.js +247 -0
- package/cjs/VapixAPI.d.ts +94 -42
- package/cjs/VapixAPI.js +323 -233
- package/cjs/{CreatePackage.js → bin/CreatePackage.js} +44 -18
- package/cjs/errors/errors.d.ts +61 -4
- package/cjs/errors/errors.js +134 -7
- package/cjs/index.d.ts +20 -4
- package/cjs/index.js +28 -5
- package/cjs/internal/ProxyClient.d.ts +8 -9
- package/cjs/internal/ProxyClient.js +28 -32
- package/cjs/internal/WsEvents.d.ts +37 -0
- package/cjs/{CamSwitcherEvents.js → internal/WsEvents.js} +28 -22
- package/cjs/internal/types.d.ts +47 -0
- package/cjs/internal/types.js +2 -0
- package/cjs/internal/utils.d.ts +3 -1
- package/cjs/internal/utils.js +15 -3
- package/cjs/internal/versionCompare.d.ts +2 -2
- package/cjs/node/CamOverlayDrawingAPI.d.ts +41 -0
- package/cjs/{CamOverlayDrawingAPI.js → node/CamOverlayDrawingAPI.js} +28 -20
- package/cjs/{CamOverlayPainter → node/CamOverlayPainter}/Frame.d.ts +8 -37
- package/cjs/{CamOverlayPainter → node/CamOverlayPainter}/Frame.js +33 -0
- package/cjs/{CamOverlayPainter → node/CamOverlayPainter}/Painter.d.ts +5 -21
- package/cjs/{CamOverlayPainter → node/CamOverlayPainter}/Painter.js +5 -17
- package/cjs/node/CamOverlayPainter/ResourceManager.d.ts +15 -0
- package/cjs/node/CamOverlayPainter/ResourceManager.js +72 -0
- package/cjs/node/CamScripterAPICameraEventsGenerator.d.ts +31 -0
- package/cjs/{CamScripterAPICameraEventsGenerator.js → node/CamScripterAPICameraEventsGenerator.js} +13 -13
- package/cjs/node/DefaultClient.d.ts +6 -5
- package/cjs/node/DefaultClient.js +10 -12
- package/cjs/{internal → node}/Digest.js +24 -1
- package/cjs/node/Digest.test.js +13 -0
- package/cjs/node/HttpRequestSender.d.ts +1 -0
- package/cjs/node/HttpRequestSender.js +14 -4
- package/cjs/node/HttpServer.d.ts +1 -1
- package/cjs/node/HttpServer.js +29 -6
- package/cjs/node/TimeZoneDaemon.d.ts +6 -0
- package/cjs/node/TimeZoneDaemon.js +29 -0
- package/cjs/node/VapixEvents.d.ts +16 -0
- package/cjs/{VapixEvents.js → node/VapixEvents.js} +10 -10
- package/cjs/node/WsClient.d.ts +9 -18
- package/cjs/node/WsClient.js +27 -20
- package/cjs/node/events/AxisCameraStationEvents.d.ts +12 -0
- package/cjs/node/events/AxisCameraStationEvents.js +53 -0
- package/cjs/node/events/GenetecAgent.d.ts +16 -0
- package/cjs/node/events/GenetecAgent.js +124 -0
- package/cjs/node/index.d.ts +18 -2
- package/cjs/node/index.js +39 -5
- package/cjs/types/CamOverlayAPI/CamOverlayAPI.d.ts +4330 -0
- package/cjs/types/CamOverlayAPI/CamOverlayAPI.js +92 -0
- package/cjs/types/CamOverlayAPI/accuweatherSchema.d.ts +84 -0
- package/cjs/types/CamOverlayAPI/accuweatherSchema.js +47 -0
- package/cjs/types/CamOverlayAPI/customGraphicsSchema.d.ts +700 -0
- package/cjs/types/CamOverlayAPI/customGraphicsSchema.js +72 -0
- package/cjs/types/CamOverlayAPI/imagesSchema.d.ts +95 -0
- package/cjs/types/CamOverlayAPI/imagesSchema.js +9 -0
- package/cjs/types/CamOverlayAPI/index.d.ts +11 -0
- package/cjs/types/CamOverlayAPI/index.js +27 -0
- package/cjs/types/CamOverlayAPI/infotickerSchema.d.ts +96 -0
- package/cjs/types/CamOverlayAPI/infotickerSchema.js +26 -0
- package/cjs/types/CamOverlayAPI/pipSchema.d.ts +125 -0
- package/cjs/types/CamOverlayAPI/pipSchema.js +39 -0
- package/cjs/types/CamOverlayAPI/ptzCompassSchema.d.ts +96 -0
- package/cjs/types/CamOverlayAPI/ptzCompassSchema.js +26 -0
- package/cjs/types/CamOverlayAPI/ptzSchema.d.ts +118 -0
- package/cjs/types/CamOverlayAPI/ptzSchema.js +12 -0
- package/cjs/types/CamOverlayAPI/scoreBoardSchema.d.ts +357 -0
- package/cjs/types/CamOverlayAPI/scoreBoardSchema.js +132 -0
- package/cjs/types/CamOverlayAPI/screenSharingSchema.d.ts +58 -0
- package/cjs/types/CamOverlayAPI/screenSharingSchema.js +8 -0
- package/cjs/types/CamOverlayAPI/serviceCommonTypes.d.ts +145 -0
- package/cjs/types/CamOverlayAPI/serviceCommonTypes.js +91 -0
- package/cjs/types/CamOverlayAPI/webCameraSharingSchema.d.ts +58 -0
- package/cjs/types/CamOverlayAPI/webCameraSharingSchema.js +8 -0
- package/cjs/types/CamOverlayDrawingAPI.d.ts +48 -0
- package/cjs/types/CamOverlayDrawingAPI.js +2 -0
- package/cjs/types/CamOverlayPainter.d.ts +76 -0
- package/cjs/types/CamOverlayPainter.js +14 -0
- package/cjs/types/CamScripterAPI.d.ts +86 -23
- package/cjs/types/CamScripterAPI.js +24 -8
- package/cjs/types/CamScripterAPICameraEventsGenerator.d.ts +45 -0
- package/cjs/types/CamScripterAPICameraEventsGenerator.js +2 -0
- package/cjs/types/CamStreamerAPI.d.ts +180 -47
- package/cjs/types/CamStreamerAPI.js +34 -3
- package/cjs/types/CamSwitcherAPI.d.ts +145 -66
- package/cjs/types/CamSwitcherAPI.js +38 -1
- package/cjs/{events → types}/GenetecAgent.d.ts +47 -47
- package/cjs/types/GenetecAgent.js +31 -0
- package/cjs/types/PlaneTrackerAPI.d.ts +952 -0
- package/cjs/types/PlaneTrackerAPI.js +320 -0
- package/cjs/types/VapixAPI.d.ts +254 -164
- package/cjs/types/VapixAPI.js +66 -11
- package/cjs/types/VapixEvents.d.ts +15 -0
- package/cjs/types/VapixEvents.js +2 -0
- package/cjs/types/common.d.ts +17 -5
- package/cjs/types/common.js +4 -2
- package/cjs/types/ws/CamOverlayEvents.d.ts +88 -0
- package/cjs/types/ws/CamOverlayEvents.js +19 -0
- package/cjs/types/ws/CamStreamerEvents.d.ts +249 -0
- package/cjs/types/ws/CamStreamerEvents.js +32 -0
- package/cjs/types/ws/PlaneTrackerEvents.d.ts +1637 -0
- package/cjs/types/ws/PlaneTrackerEvents.js +196 -0
- package/cjs/web/DefaultClient.d.ts +7 -5
- package/cjs/web/DefaultClient.js +26 -10
- package/cjs/web/WsClient.d.ts +9 -5
- package/cjs/web/WsClient.js +16 -18
- package/cjs/ws/CamOverlayEvents.d.ts +8 -0
- package/cjs/ws/CamOverlayEvents.js +24 -0
- package/cjs/ws/CamStreamerEvents.d.ts +8 -0
- package/cjs/ws/CamStreamerEvents.js +24 -0
- package/cjs/ws/CamSwitcherEvents.d.ts +8 -0
- package/cjs/ws/CamSwitcherEvents.js +24 -0
- package/cjs/ws/PlaneTrackerEvents.d.ts +9 -0
- package/cjs/ws/PlaneTrackerEvents.js +30 -0
- package/esm/CamOverlayAPI.js +135 -92
- package/esm/CamScripterAPI.js +50 -40
- package/esm/CamStreamerAPI.js +81 -39
- package/esm/CamSwitcherAPI.js +136 -120
- package/esm/PlaneTrackerAPI.js +243 -0
- package/esm/VapixAPI.js +323 -233
- package/esm/{CreatePackage.js → bin/CreatePackage.js} +16 -16
- package/esm/errors/errors.js +116 -6
- package/esm/index.js +20 -4
- package/esm/internal/ProxyClient.js +28 -32
- package/esm/{CamSwitcherEvents.js → internal/WsEvents.js} +26 -20
- package/esm/internal/types.js +1 -0
- package/esm/internal/utils.js +11 -1
- package/esm/{CamOverlayDrawingAPI.js → node/CamOverlayDrawingAPI.js} +26 -18
- 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} +11 -11
- package/esm/node/DefaultClient.js +10 -12
- package/esm/node/Digest.test.js +11 -0
- package/esm/node/HttpRequestSender.js +14 -4
- package/esm/node/HttpServer.js +1 -1
- package/esm/node/TimeZoneDaemon.js +25 -0
- package/esm/{VapixEvents.js → node/VapixEvents.js} +10 -10
- package/esm/node/WsClient.js +22 -15
- package/esm/{events → node/events}/AxisCameraStationEvents.js +18 -13
- package/esm/node/events/GenetecAgent.js +120 -0
- package/esm/node/index.js +18 -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 +23 -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/CamOverlayDrawingAPI.js +1 -0
- package/esm/types/CamOverlayPainter.js +11 -0
- package/esm/types/CamScripterAPI.js +23 -7
- package/esm/types/CamScripterAPICameraEventsGenerator.js +1 -0
- package/esm/types/CamStreamerAPI.js +33 -2
- package/esm/types/CamSwitcherAPI.js +38 -1
- package/esm/types/GenetecAgent.js +28 -0
- package/esm/types/PlaneTrackerAPI.js +317 -0
- package/esm/types/VapixAPI.js +65 -10
- package/esm/types/VapixEvents.js +1 -0
- package/esm/types/common.js +3 -1
- package/esm/types/ws/CamOverlayEvents.js +16 -0
- package/esm/types/ws/CamStreamerEvents.js +29 -0
- package/esm/types/ws/PlaneTrackerEvents.js +193 -0
- package/esm/web/DefaultClient.js +26 -10
- package/esm/web/WsClient.js +16 -18
- package/esm/ws/CamOverlayEvents.js +20 -0
- package/esm/ws/CamStreamerEvents.js +20 -0
- package/esm/ws/CamSwitcherEvents.js +20 -0
- package/esm/ws/PlaneTrackerEvents.js +26 -0
- package/package.json +44 -11
- package/types/CamOverlayAPI.d.ts +867 -0
- package/types/CamScripterAPI.d.ts +46 -0
- package/types/CamStreamerAPI.d.ts +64 -0
- package/types/CamSwitcherAPI.d.ts +167 -0
- package/types/PlaneTrackerAPI.d.ts +233 -0
- package/types/VapixAPI.d.ts +118 -0
- package/types/bin/CreatePackage.d.ts +1 -0
- package/types/errors/errors.d.ts +91 -0
- package/types/index.d.ts +27 -0
- package/types/internal/ProxyClient.d.ts +10 -0
- package/types/internal/WsEvents.d.ts +37 -0
- package/types/internal/types.d.ts +47 -0
- package/{esm → types}/internal/utils.d.ts +3 -1
- package/{esm → 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/{esm → 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/types/node/Digest.test.d.ts +1 -0
- package/{esm → types}/node/HttpRequestSender.d.ts +1 -0
- package/{esm → types}/node/HttpServer.d.ts +1 -1
- package/types/node/TimeZoneDaemon.d.ts +6 -0
- package/types/node/VapixEvents.d.ts +16 -0
- package/types/node/WsClient.d.ts +30 -0
- package/types/node/events/AxisCameraStationEvents.d.ts +12 -0
- package/types/node/events/GenetecAgent.d.ts +16 -0
- package/types/node/index.d.ts +18 -0
- package/types/types/CamOverlayAPI/CamOverlayAPI.d.ts +4330 -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 +96 -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 +145 -66
- package/{esm/events → types/types}/GenetecAgent.d.ts +47 -47
- package/types/types/PlaneTrackerAPI.d.ts +952 -0
- package/{esm → types}/types/VapixAPI.d.ts +254 -164
- package/types/types/VapixEvents.d.ts +15 -0
- package/{esm → types}/types/common.d.ts +17 -5
- package/types/types/ws/CamOverlayEvents.d.ts +88 -0
- package/types/types/ws/CamStreamerEvents.d.ts +249 -0
- package/types/types/ws/PlaneTrackerEvents.d.ts +1637 -0
- package/types/web/DefaultClient.d.ts +8 -0
- package/types/web/WsClient.d.ts +17 -0
- package/types/ws/CamOverlayEvents.d.ts +8 -0
- package/types/ws/CamStreamerEvents.d.ts +8 -0
- package/types/ws/CamSwitcherEvents.d.ts +8 -0
- package/types/ws/PlaneTrackerEvents.d.ts +9 -0
- package/cjs/CamOverlayDrawingAPI.d.ts +0 -86
- package/cjs/CamOverlayPainter/ResourceManager.d.ts +0 -14
- package/cjs/CamOverlayPainter/ResourceManager.js +0 -46
- package/cjs/CamScripterAPICameraEventsGenerator.d.ts +0 -74
- package/cjs/CamSwitcherEvents.d.ts +0 -18
- package/cjs/VapixEvents.d.ts +0 -43
- package/cjs/events/AxisCameraStationEvents.d.ts +0 -9
- package/cjs/events/AxisCameraStationEvents.js +0 -48
- package/cjs/events/GenetecAgent.js +0 -123
- package/cjs/internal/common.d.ts +0 -39
- package/cjs/internal/common.js +0 -27
- 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/esm/CamOverlayAPI.d.ts +0 -31
- package/esm/CamOverlayDrawingAPI.d.ts +0 -86
- 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 -52
- 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/ProxyClient.d.ts +0 -11
- package/esm/internal/common.d.ts +0 -39
- package/esm/internal/common.js +0 -20
- package/esm/node/DefaultClient.d.ts +0 -15
- 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/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/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 → bin/CreatePackage.d.ts} +0 -0
- /package/cjs/{internal → node}/Digest.d.ts +0 -0
- /package/{esm/CreatePackage.d.ts → cjs/node/Digest.test.d.ts} +0 -0
- /package/cjs/types/{CamSwitcherEvents.d.ts → ws/CamSwitcherEvents.d.ts} +0 -0
- /package/cjs/types/{CamSwitcherEvents.js → ws/CamSwitcherEvents.js} +0 -0
- /package/esm/{internal → node}/Digest.js +0 -0
- /package/esm/types/{CamSwitcherEvents.js → ws/CamSwitcherEvents.js} +0 -0
- /package/{esm → types}/internal/constants.d.ts +0 -0
- /package/{esm → types}/internal/transformers.d.ts +0 -0
- /package/{esm/internal → types/node}/Digest.d.ts +0 -0
- /package/{esm/types → types/types/ws}/CamSwitcherEvents.d.ts +0 -0
- /package/{esm/node → types/web}/index.d.ts +0 -0
|
@@ -1,188 +0,0 @@
|
|
|
1
|
-
import { HttpOptions } from '../internal/common';
|
|
2
|
-
import { z } from 'zod';
|
|
3
|
-
export type CamOverlayOptions = HttpOptions;
|
|
4
|
-
export type TFileType = 'image' | 'font';
|
|
5
|
-
export type TCoordinates = 'top_left' | 'top_right' | 'top' | 'bottom_left' | 'bottom_right' | 'bottom' | 'left' | 'right' | 'center' | '';
|
|
6
|
-
export declare const serviceSchema: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
7
|
-
export type TService = z.infer<typeof serviceSchema>;
|
|
8
|
-
export type TServiceList = {
|
|
9
|
-
services: TService[];
|
|
10
|
-
};
|
|
11
|
-
export declare const fieldSchema: z.ZodObject<{
|
|
12
|
-
field_name: z.ZodString;
|
|
13
|
-
text: z.ZodString;
|
|
14
|
-
color: z.ZodOptional<z.ZodString>;
|
|
15
|
-
}, "strip", z.ZodTypeAny, {
|
|
16
|
-
field_name: string;
|
|
17
|
-
text: string;
|
|
18
|
-
color?: string | undefined;
|
|
19
|
-
}, {
|
|
20
|
-
field_name: string;
|
|
21
|
-
text: string;
|
|
22
|
-
color?: string | undefined;
|
|
23
|
-
}>;
|
|
24
|
-
export type TField = z.infer<typeof fieldSchema>;
|
|
25
|
-
export declare const fileSchema: z.ZodObject<{
|
|
26
|
-
name: z.ZodString;
|
|
27
|
-
path: z.ZodString;
|
|
28
|
-
storage: z.ZodString;
|
|
29
|
-
}, "strip", z.ZodTypeAny, {
|
|
30
|
-
path: string;
|
|
31
|
-
name: string;
|
|
32
|
-
storage: string;
|
|
33
|
-
}, {
|
|
34
|
-
path: string;
|
|
35
|
-
name: string;
|
|
36
|
-
storage: string;
|
|
37
|
-
}>;
|
|
38
|
-
export type TFile = z.infer<typeof fileSchema>;
|
|
39
|
-
export declare const fileListSchema: z.ZodArray<z.ZodObject<{
|
|
40
|
-
name: z.ZodString;
|
|
41
|
-
path: z.ZodString;
|
|
42
|
-
storage: z.ZodString;
|
|
43
|
-
}, "strip", z.ZodTypeAny, {
|
|
44
|
-
path: string;
|
|
45
|
-
name: string;
|
|
46
|
-
storage: string;
|
|
47
|
-
}, {
|
|
48
|
-
path: string;
|
|
49
|
-
name: string;
|
|
50
|
-
storage: string;
|
|
51
|
-
}>, "many">;
|
|
52
|
-
export type TFileList = z.infer<typeof fileListSchema>;
|
|
53
|
-
export declare enum ImageType {
|
|
54
|
-
PNG = 0,
|
|
55
|
-
JPEG = 1
|
|
56
|
-
}
|
|
57
|
-
export declare const fontStorageSchema: z.ZodTuple<[z.ZodObject<{
|
|
58
|
-
type: z.ZodLiteral<"SD0">;
|
|
59
|
-
state: z.ZodLiteral<"SD Card">;
|
|
60
|
-
}, "strip", z.ZodTypeAny, {
|
|
61
|
-
type: "SD0";
|
|
62
|
-
state: "SD Card";
|
|
63
|
-
}, {
|
|
64
|
-
type: "SD0";
|
|
65
|
-
state: "SD Card";
|
|
66
|
-
}>, z.ZodObject<{
|
|
67
|
-
type: z.ZodLiteral<"flash">;
|
|
68
|
-
state: z.ZodString;
|
|
69
|
-
}, "strip", z.ZodTypeAny, {
|
|
70
|
-
type: "flash";
|
|
71
|
-
state: string;
|
|
72
|
-
}, {
|
|
73
|
-
type: "flash";
|
|
74
|
-
state: string;
|
|
75
|
-
}>], null>;
|
|
76
|
-
export type TFontStorage = z.infer<typeof fontStorageSchema>;
|
|
77
|
-
export declare const imageStorageSchema: z.ZodTuple<[z.ZodObject<{
|
|
78
|
-
type: z.ZodLiteral<"SD0">;
|
|
79
|
-
state: z.ZodLiteral<"SD Card">;
|
|
80
|
-
}, "strip", z.ZodTypeAny, {
|
|
81
|
-
type: "SD0";
|
|
82
|
-
state: "SD Card";
|
|
83
|
-
}, {
|
|
84
|
-
type: "SD0";
|
|
85
|
-
state: "SD Card";
|
|
86
|
-
}>, z.ZodObject<{
|
|
87
|
-
type: z.ZodLiteral<"flash">;
|
|
88
|
-
state: z.ZodString;
|
|
89
|
-
}, "strip", z.ZodTypeAny, {
|
|
90
|
-
type: "flash";
|
|
91
|
-
state: string;
|
|
92
|
-
}, {
|
|
93
|
-
type: "flash";
|
|
94
|
-
state: string;
|
|
95
|
-
}>, z.ZodObject<{
|
|
96
|
-
type: z.ZodLiteral<"samba">;
|
|
97
|
-
state: z.ZodLiteral<"Microsoft Network Share">;
|
|
98
|
-
}, "strip", z.ZodTypeAny, {
|
|
99
|
-
type: "samba";
|
|
100
|
-
state: "Microsoft Network Share";
|
|
101
|
-
}, {
|
|
102
|
-
type: "samba";
|
|
103
|
-
state: "Microsoft Network Share";
|
|
104
|
-
}>, z.ZodObject<{
|
|
105
|
-
type: z.ZodLiteral<"url">;
|
|
106
|
-
state: z.ZodLiteral<"URL">;
|
|
107
|
-
}, "strip", z.ZodTypeAny, {
|
|
108
|
-
type: "url";
|
|
109
|
-
state: "URL";
|
|
110
|
-
}, {
|
|
111
|
-
type: "url";
|
|
112
|
-
state: "URL";
|
|
113
|
-
}>, z.ZodObject<{
|
|
114
|
-
type: z.ZodLiteral<"ftp">;
|
|
115
|
-
state: z.ZodLiteral<"FTP">;
|
|
116
|
-
}, "strip", z.ZodTypeAny, {
|
|
117
|
-
type: "ftp";
|
|
118
|
-
state: "FTP";
|
|
119
|
-
}, {
|
|
120
|
-
type: "ftp";
|
|
121
|
-
state: "FTP";
|
|
122
|
-
}>], null>;
|
|
123
|
-
export type TImageStorage = z.infer<typeof imageStorageSchema>;
|
|
124
|
-
export declare const storageSchema: z.ZodUnion<[z.ZodTuple<[z.ZodObject<{
|
|
125
|
-
type: z.ZodLiteral<"SD0">;
|
|
126
|
-
state: z.ZodLiteral<"SD Card">;
|
|
127
|
-
}, "strip", z.ZodTypeAny, {
|
|
128
|
-
type: "SD0";
|
|
129
|
-
state: "SD Card";
|
|
130
|
-
}, {
|
|
131
|
-
type: "SD0";
|
|
132
|
-
state: "SD Card";
|
|
133
|
-
}>, z.ZodObject<{
|
|
134
|
-
type: z.ZodLiteral<"flash">;
|
|
135
|
-
state: z.ZodString;
|
|
136
|
-
}, "strip", z.ZodTypeAny, {
|
|
137
|
-
type: "flash";
|
|
138
|
-
state: string;
|
|
139
|
-
}, {
|
|
140
|
-
type: "flash";
|
|
141
|
-
state: string;
|
|
142
|
-
}>], null>, z.ZodTuple<[z.ZodObject<{
|
|
143
|
-
type: z.ZodLiteral<"SD0">;
|
|
144
|
-
state: z.ZodLiteral<"SD Card">;
|
|
145
|
-
}, "strip", z.ZodTypeAny, {
|
|
146
|
-
type: "SD0";
|
|
147
|
-
state: "SD Card";
|
|
148
|
-
}, {
|
|
149
|
-
type: "SD0";
|
|
150
|
-
state: "SD Card";
|
|
151
|
-
}>, z.ZodObject<{
|
|
152
|
-
type: z.ZodLiteral<"flash">;
|
|
153
|
-
state: z.ZodString;
|
|
154
|
-
}, "strip", z.ZodTypeAny, {
|
|
155
|
-
type: "flash";
|
|
156
|
-
state: string;
|
|
157
|
-
}, {
|
|
158
|
-
type: "flash";
|
|
159
|
-
state: string;
|
|
160
|
-
}>, z.ZodObject<{
|
|
161
|
-
type: z.ZodLiteral<"samba">;
|
|
162
|
-
state: z.ZodLiteral<"Microsoft Network Share">;
|
|
163
|
-
}, "strip", z.ZodTypeAny, {
|
|
164
|
-
type: "samba";
|
|
165
|
-
state: "Microsoft Network Share";
|
|
166
|
-
}, {
|
|
167
|
-
type: "samba";
|
|
168
|
-
state: "Microsoft Network Share";
|
|
169
|
-
}>, z.ZodObject<{
|
|
170
|
-
type: z.ZodLiteral<"url">;
|
|
171
|
-
state: z.ZodLiteral<"URL">;
|
|
172
|
-
}, "strip", z.ZodTypeAny, {
|
|
173
|
-
type: "url";
|
|
174
|
-
state: "URL";
|
|
175
|
-
}, {
|
|
176
|
-
type: "url";
|
|
177
|
-
state: "URL";
|
|
178
|
-
}>, z.ZodObject<{
|
|
179
|
-
type: z.ZodLiteral<"ftp">;
|
|
180
|
-
state: z.ZodLiteral<"FTP">;
|
|
181
|
-
}, "strip", z.ZodTypeAny, {
|
|
182
|
-
type: "ftp";
|
|
183
|
-
state: "FTP";
|
|
184
|
-
}, {
|
|
185
|
-
type: "ftp";
|
|
186
|
-
state: "FTP";
|
|
187
|
-
}>], null>]>;
|
|
188
|
-
export type TStorage = z.infer<typeof storageSchema>;
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.storageSchema = exports.imageStorageSchema = exports.fontStorageSchema = exports.ImageType = exports.fileListSchema = exports.fileSchema = exports.fieldSchema = exports.serviceSchema = void 0;
|
|
4
|
-
const zod_1 = require("zod");
|
|
5
|
-
exports.serviceSchema = zod_1.z.record(zod_1.z.string(), zod_1.z.any());
|
|
6
|
-
exports.fieldSchema = zod_1.z.object({
|
|
7
|
-
field_name: zod_1.z.string(),
|
|
8
|
-
text: zod_1.z.string(),
|
|
9
|
-
color: zod_1.z.string().optional(),
|
|
10
|
-
});
|
|
11
|
-
exports.fileSchema = zod_1.z.object({
|
|
12
|
-
name: zod_1.z.string(),
|
|
13
|
-
path: zod_1.z.string(),
|
|
14
|
-
storage: zod_1.z.string(),
|
|
15
|
-
});
|
|
16
|
-
exports.fileListSchema = zod_1.z.array(exports.fileSchema);
|
|
17
|
-
var ImageType;
|
|
18
|
-
(function (ImageType) {
|
|
19
|
-
ImageType[ImageType["PNG"] = 0] = "PNG";
|
|
20
|
-
ImageType[ImageType["JPEG"] = 1] = "JPEG";
|
|
21
|
-
})(ImageType || (exports.ImageType = ImageType = {}));
|
|
22
|
-
exports.fontStorageSchema = zod_1.z.tuple([
|
|
23
|
-
zod_1.z.object({
|
|
24
|
-
type: zod_1.z.literal('SD0'),
|
|
25
|
-
state: zod_1.z.literal('SD Card'),
|
|
26
|
-
}),
|
|
27
|
-
zod_1.z.object({
|
|
28
|
-
type: zod_1.z.literal('flash'),
|
|
29
|
-
state: zod_1.z.string(),
|
|
30
|
-
}),
|
|
31
|
-
]);
|
|
32
|
-
exports.imageStorageSchema = zod_1.z.tuple([
|
|
33
|
-
...exports.fontStorageSchema.items,
|
|
34
|
-
zod_1.z.object({
|
|
35
|
-
type: zod_1.z.literal('samba'),
|
|
36
|
-
state: zod_1.z.literal('Microsoft Network Share'),
|
|
37
|
-
}),
|
|
38
|
-
zod_1.z.object({
|
|
39
|
-
type: zod_1.z.literal('url'),
|
|
40
|
-
state: zod_1.z.literal('URL'),
|
|
41
|
-
}),
|
|
42
|
-
zod_1.z.object({
|
|
43
|
-
type: zod_1.z.literal('ftp'),
|
|
44
|
-
state: zod_1.z.literal('FTP'),
|
|
45
|
-
}),
|
|
46
|
-
]);
|
|
47
|
-
exports.storageSchema = zod_1.z.union([exports.fontStorageSchema, exports.imageStorageSchema]);
|
package/esm/CamOverlayAPI.d.ts
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import { IClient } from './internal/common';
|
|
3
|
-
import { CamOverlayOptions, ImageType, TCoordinates, TField, TFile, TFileList, TFileType, TService, TServiceList, TStorage } from './types/CamOverlayAPI';
|
|
4
|
-
import { TNetworkCamera } from './types/common';
|
|
5
|
-
export declare class CamOverlayAPI {
|
|
6
|
-
private client;
|
|
7
|
-
constructor(options?: CamOverlayOptions | IClient);
|
|
8
|
-
checkCameraTime(): Promise<boolean>;
|
|
9
|
-
getNetworkCameraList(): Promise<TNetworkCamera[]>;
|
|
10
|
-
wsAutoratization(): Promise<string>;
|
|
11
|
-
getMjpegStreamImage(mjpegUrl: string): Promise<Blob>;
|
|
12
|
-
listFiles(fileType: TFileType): Promise<TFileList>;
|
|
13
|
-
uploadFile(fileType: TFileType, file: Blob, fileName: string): Promise<void>;
|
|
14
|
-
removeFile(fileType: TFileType, file: TFile): Promise<void>;
|
|
15
|
-
getFileStorage(fileType: TFileType): Promise<TStorage>;
|
|
16
|
-
updateInfoticker(serviceID: number, text: string): Promise<void>;
|
|
17
|
-
setEnabled(serviceID: number, enabled: boolean): Promise<void>;
|
|
18
|
-
isEnabled(serviceID: number): Promise<boolean>;
|
|
19
|
-
getSingleService(serviceId: number): Promise<TService>;
|
|
20
|
-
getServices(): Promise<TService[]>;
|
|
21
|
-
updateSingleService(serviceId: number, serviceJson: TService): Promise<void>;
|
|
22
|
-
updateServices(servicesJson: TServiceList): Promise<void>;
|
|
23
|
-
updateCGText(serviceID: number, fields: TField[]): Promise<void>;
|
|
24
|
-
updateCGImagePos(serviceID: number, coordinates?: TCoordinates, x?: number, y?: number): Promise<void>;
|
|
25
|
-
updateCGImage(serviceID: number, path: string, coordinates?: TCoordinates, x?: number, y?: number): Promise<void>;
|
|
26
|
-
updateCGImageFromData(serviceID: number, imageType: ImageType, imageData: Buffer, coordinates?: TCoordinates, x?: number, y?: number): Promise<void>;
|
|
27
|
-
private promiseCGUpdate;
|
|
28
|
-
private get;
|
|
29
|
-
private post;
|
|
30
|
-
private parseBlobResponse;
|
|
31
|
-
}
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
/// <reference types="node" />
|
|
3
|
-
import * as EventEmitter from 'events';
|
|
4
|
-
import { WsOptions } from './internal/common';
|
|
5
|
-
export type CamOverlayDrawingOptions = WsOptions & {
|
|
6
|
-
camera?: number | number[];
|
|
7
|
-
zIndex?: number;
|
|
8
|
-
};
|
|
9
|
-
export type TCairoResponse = {
|
|
10
|
-
message: string;
|
|
11
|
-
call_id: number;
|
|
12
|
-
};
|
|
13
|
-
export type TCairoCreateResponse = {
|
|
14
|
-
var: string;
|
|
15
|
-
call_id: number;
|
|
16
|
-
};
|
|
17
|
-
export type TUploadImageResponse = {
|
|
18
|
-
var: string;
|
|
19
|
-
width: number;
|
|
20
|
-
height: number;
|
|
21
|
-
call_id: number;
|
|
22
|
-
};
|
|
23
|
-
export type TErrorResponse = {
|
|
24
|
-
error: string;
|
|
25
|
-
call_id?: number;
|
|
26
|
-
};
|
|
27
|
-
export type TService = {
|
|
28
|
-
id: number;
|
|
29
|
-
enabled: number;
|
|
30
|
-
schedule: string;
|
|
31
|
-
name: string;
|
|
32
|
-
identifier: string;
|
|
33
|
-
cameraList: number[];
|
|
34
|
-
};
|
|
35
|
-
export type TServiceList = {
|
|
36
|
-
services: TService[];
|
|
37
|
-
};
|
|
38
|
-
export type TAlign = 'A_RIGHT' | 'A_LEFT' | 'A_CENTER';
|
|
39
|
-
export type TextFit = 'TFM_SCALE' | 'TFM_TRUNCATE' | 'TFM_OVERFLOW';
|
|
40
|
-
export type TWriteTextParams = [string, string, number, number, number, number, TAlign, TextFit?];
|
|
41
|
-
export interface CamOverlayDrawingAPI {
|
|
42
|
-
on(event: 'open', listener: () => void): this;
|
|
43
|
-
on(event: 'close', listener: () => void): this;
|
|
44
|
-
on(event: 'error', listener: (err: Error) => void): this;
|
|
45
|
-
on(event: 'message', listener: (msg: string) => void): this;
|
|
46
|
-
emit(event: 'open'): boolean;
|
|
47
|
-
emit(event: 'close'): boolean;
|
|
48
|
-
emit(event: 'error', err: Error): boolean;
|
|
49
|
-
emit(event: 'message', msg: string): boolean;
|
|
50
|
-
}
|
|
51
|
-
export declare class CamOverlayDrawingAPI extends EventEmitter {
|
|
52
|
-
private tls;
|
|
53
|
-
private tlsInsecure;
|
|
54
|
-
private ip;
|
|
55
|
-
private port;
|
|
56
|
-
private user;
|
|
57
|
-
private pass;
|
|
58
|
-
private cameraList;
|
|
59
|
-
private zIndex;
|
|
60
|
-
private callId;
|
|
61
|
-
private sendMessages;
|
|
62
|
-
private timeoutCheckTimer;
|
|
63
|
-
private wsConnected;
|
|
64
|
-
private ws;
|
|
65
|
-
constructor(options?: CamOverlayDrawingOptions);
|
|
66
|
-
connect(): void;
|
|
67
|
-
disconnect(): void;
|
|
68
|
-
isConnected(): boolean;
|
|
69
|
-
cairo(command: string, ...params: unknown[]): Promise<TCairoResponse | TCairoCreateResponse>;
|
|
70
|
-
writeText(...params: TWriteTextParams): Promise<TCairoResponse>;
|
|
71
|
-
uploadImageData(imgBuffer: Buffer): Promise<TUploadImageResponse>;
|
|
72
|
-
uploadFontData(fontBuffer: Buffer): Promise<TCairoCreateResponse>;
|
|
73
|
-
showCairoImage(cairoImage: string, posX: number, posY: number): Promise<TCairoResponse>;
|
|
74
|
-
showCairoImageAbsolute(cairoImage: string, posX: number, posY: number, width: number, height: number): Promise<TCairoResponse>;
|
|
75
|
-
removeImage(): Promise<TCairoResponse>;
|
|
76
|
-
private createWsClient;
|
|
77
|
-
private incomingWsMessageHandler;
|
|
78
|
-
private sendMessage;
|
|
79
|
-
private sendBinaryMessage;
|
|
80
|
-
private startMsgsTimeoutCheck;
|
|
81
|
-
private stopMsgsTimeoutCheck;
|
|
82
|
-
private reconnectWithError;
|
|
83
|
-
private reportMessage;
|
|
84
|
-
private reportError;
|
|
85
|
-
private reportClose;
|
|
86
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { CamOverlayDrawingAPI, TUploadImageResponse, TCairoCreateResponse } from '../CamOverlayDrawingAPI';
|
|
2
|
-
export default class ResourceManager {
|
|
3
|
-
private co;
|
|
4
|
-
private imgFileNames;
|
|
5
|
-
private fontFileNames;
|
|
6
|
-
private images;
|
|
7
|
-
private fonts;
|
|
8
|
-
constructor(co: CamOverlayDrawingAPI);
|
|
9
|
-
registerImage(moniker: string, fileName: string): void;
|
|
10
|
-
registerFont(moniker: string, fileName: string): void;
|
|
11
|
-
image(moniker: string): Promise<TUploadImageResponse>;
|
|
12
|
-
font(moniker: string): Promise<TCairoCreateResponse>;
|
|
13
|
-
clear(): void;
|
|
14
|
-
}
|
package/esm/CamScripterAPI.d.ts
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { IClient } from './internal/common';
|
|
2
|
-
import { CamScripterOptions, TNodeState, TPackageInfoList, TStorage, TStorageType } from './types/CamScripterAPI';
|
|
3
|
-
import { TNetworkCamera } from './types/common';
|
|
4
|
-
export declare class CamOverlayAPI {
|
|
5
|
-
private client;
|
|
6
|
-
constructor(options?: CamScripterOptions | IClient);
|
|
7
|
-
checkCameraTime(): Promise<boolean>;
|
|
8
|
-
getStorageInfo(): Promise<TStorage>;
|
|
9
|
-
getNetworkCameraList(): Promise<TNetworkCamera[]>;
|
|
10
|
-
getPackageList(): Promise<TPackageInfoList>;
|
|
11
|
-
installPackages(formData: FormData, storage: TStorageType): Promise<void>;
|
|
12
|
-
uninstallPackage(packageId: string): Promise<void>;
|
|
13
|
-
importSettings(packageId: string, formData: FormData): Promise<void>;
|
|
14
|
-
exportSettings(packageId: string, formData: FormData): Promise<void>;
|
|
15
|
-
getNodejsStatus(): Promise<TNodeState>;
|
|
16
|
-
installNodejs(storage: TStorageType): Promise<void>;
|
|
17
|
-
private get;
|
|
18
|
-
private post;
|
|
19
|
-
}
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import * as EventEmitter from 'events';
|
|
3
|
-
import { WsOptions } from './internal/common';
|
|
4
|
-
export type CamScripterOptions = WsOptions;
|
|
5
|
-
export type TDeclaration = {
|
|
6
|
-
type?: '' | 'SOURCE' | 'DATA';
|
|
7
|
-
namespace: string;
|
|
8
|
-
key: string;
|
|
9
|
-
value: string | boolean | number;
|
|
10
|
-
value_type: 'STRING' | 'INT' | 'BOOL' | 'DOUBLE';
|
|
11
|
-
key_nice_name?: string;
|
|
12
|
-
value_nice_name?: string;
|
|
13
|
-
};
|
|
14
|
-
export type TEventDeclaration = {
|
|
15
|
-
declaration_id: string;
|
|
16
|
-
stateless: boolean;
|
|
17
|
-
declaration: TDeclaration[];
|
|
18
|
-
};
|
|
19
|
-
export type TEventUndeclaration = {
|
|
20
|
-
declaration_id: string;
|
|
21
|
-
};
|
|
22
|
-
export type TEventData = {
|
|
23
|
-
namespace: string;
|
|
24
|
-
key: string;
|
|
25
|
-
value: string | boolean | number;
|
|
26
|
-
value_type: 'STRING' | 'INT' | 'BOOL' | 'DOUBLE';
|
|
27
|
-
};
|
|
28
|
-
export type TEvent = {
|
|
29
|
-
declaration_id: string;
|
|
30
|
-
event_data: TEventData[];
|
|
31
|
-
};
|
|
32
|
-
export type TResponse = {
|
|
33
|
-
call_id: number;
|
|
34
|
-
message: string;
|
|
35
|
-
};
|
|
36
|
-
export type TErrorResponse = {
|
|
37
|
-
error: string;
|
|
38
|
-
call_id?: number;
|
|
39
|
-
};
|
|
40
|
-
export interface CamScripterAPICameraEventsGenerator {
|
|
41
|
-
on(event: 'open', listener: () => void): this;
|
|
42
|
-
on(event: 'close', listener: () => void): this;
|
|
43
|
-
on(event: 'error', listener: (err: Error) => void): this;
|
|
44
|
-
emit(event: 'open'): boolean;
|
|
45
|
-
emit(event: 'close'): boolean;
|
|
46
|
-
emit(event: 'error', err: Error): boolean;
|
|
47
|
-
}
|
|
48
|
-
export declare class CamScripterAPICameraEventsGenerator extends EventEmitter {
|
|
49
|
-
private tls;
|
|
50
|
-
private tlsInsecure;
|
|
51
|
-
private ip;
|
|
52
|
-
private port;
|
|
53
|
-
private user;
|
|
54
|
-
private pass;
|
|
55
|
-
private callId;
|
|
56
|
-
private sendMessages;
|
|
57
|
-
private timeoutCheckTimer;
|
|
58
|
-
private wsConnected;
|
|
59
|
-
private ws;
|
|
60
|
-
constructor(options?: CamScripterOptions);
|
|
61
|
-
connect(): void;
|
|
62
|
-
disconnect(): void;
|
|
63
|
-
declareEvent(eventDeclaration: TEventDeclaration): Promise<TResponse>;
|
|
64
|
-
undeclareEvent(eventUndeclaration: TEventUndeclaration): Promise<TResponse>;
|
|
65
|
-
sendEvent(event: TEvent): Promise<TResponse>;
|
|
66
|
-
private createWsClient;
|
|
67
|
-
private incomingWsMessageHandler;
|
|
68
|
-
private sendMessage;
|
|
69
|
-
private startMsgsTimeoutCheck;
|
|
70
|
-
private stopMsgsTimeoutCheck;
|
|
71
|
-
private reconnectWithError;
|
|
72
|
-
private reportErr;
|
|
73
|
-
private reportClose;
|
|
74
|
-
}
|
package/esm/CamStreamerAPI.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { IClient } from './internal/common';
|
|
2
|
-
import { CamStreamerAPIOptions, TStreamAttributes, TStreamList } from './types/CamStreamerAPI';
|
|
3
|
-
export declare class CamStreamerAPI {
|
|
4
|
-
private client;
|
|
5
|
-
constructor(options?: CamStreamerAPIOptions | IClient);
|
|
6
|
-
getStreamList(): Promise<TStreamList>;
|
|
7
|
-
getStream(streamID: string): Promise<TStreamAttributes>;
|
|
8
|
-
getStreamParameter(streamID: string, paramName: string): Promise<string>;
|
|
9
|
-
setStream(streamID: string, params: Partial<TStreamAttributes>): Promise<void>;
|
|
10
|
-
setStreamParameter(streamID: string, paramName: string, value: string): Promise<void>;
|
|
11
|
-
isStreaming(streamID: string): Promise<boolean>;
|
|
12
|
-
deleteStream(streamID: string): Promise<void>;
|
|
13
|
-
wsAutoratization(): Promise<string>;
|
|
14
|
-
getUtcTime(): Promise<number>;
|
|
15
|
-
private get;
|
|
16
|
-
}
|
package/esm/CamSwitcherAPI.d.ts
DELETED
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { IClient } from './internal/common';
|
|
2
|
-
import { TAudioPushInfo, TOutputInfo, TStorageInfo, TStreamSaveList, TClipList, TStreamSaveLoadList, TClipSaveLoadList, TPlaylistSaveLoadList, TTrackerSaveList, TrackerSaveLoadList, TClipSaveList, TPlaylistSaveList, TCameraOptions, TGlobalAudioSettings, TSecondaryAudioSettings } from './types/CamSwitcherAPI';
|
|
3
|
-
import { TAudioChannel, TNetworkCamera, TStorageType } from './types/common';
|
|
4
|
-
export declare class CamSwitcherAPI<Client extends IClient = IClient> {
|
|
5
|
-
client: Client;
|
|
6
|
-
private CustomFormData;
|
|
7
|
-
private vapixAgent;
|
|
8
|
-
constructor(client: Client, CustomFormData?: {
|
|
9
|
-
new (form?: HTMLFormElement | undefined, submitter?: HTMLElement | null | undefined): FormData;
|
|
10
|
-
prototype: FormData;
|
|
11
|
-
});
|
|
12
|
-
static getProxyUrlPath: () => string;
|
|
13
|
-
static getWsEventsUrlPath: () => string;
|
|
14
|
-
static getClipPreviewUrlPath: (id: string, storage: TStorageType) => string;
|
|
15
|
-
generateSilence(sampleRate: number, channels: TAudioChannel): Promise<void>;
|
|
16
|
-
checkCameraTime(): Promise<boolean>;
|
|
17
|
-
getIpListFromNetworkCheck(): Promise<TNetworkCamera[]>;
|
|
18
|
-
getMaxFps(source: number): Promise<number>;
|
|
19
|
-
getStorageInfo(): Promise<TStorageInfo[]>;
|
|
20
|
-
wsAuthorization(): Promise<string>;
|
|
21
|
-
getOutputInfo(): Promise<TOutputInfo>;
|
|
22
|
-
getAudioPushInfo(): Promise<TAudioPushInfo>;
|
|
23
|
-
getStreamSaveList(): Promise<TStreamSaveLoadList>;
|
|
24
|
-
getClipSaveList(): Promise<TClipSaveLoadList>;
|
|
25
|
-
getPlaylistSaveList(): Promise<TPlaylistSaveLoadList>;
|
|
26
|
-
getTrackerSaveList(): Promise<TrackerSaveLoadList>;
|
|
27
|
-
setStreamSaveList(data: TStreamSaveList): Promise<boolean>;
|
|
28
|
-
setClipSaveList(data: TClipSaveList): Promise<boolean>;
|
|
29
|
-
setPlaylistSaveList(data: TPlaylistSaveList): Promise<boolean>;
|
|
30
|
-
setTrackerSaveList(data: TTrackerSaveList): Promise<boolean>;
|
|
31
|
-
playlistSwitch(playlistName: string): Promise<void>;
|
|
32
|
-
playlistQueuePush(playlistName: string): Promise<void>;
|
|
33
|
-
playlistQueueClear(): Promise<void>;
|
|
34
|
-
playlistQueueList(): Promise<string[]>;
|
|
35
|
-
playlistQueuePlayNext(): Promise<void>;
|
|
36
|
-
addNewClip(file: any, clipType: 'video' | 'audio', storage: TStorageType, id: string, fileName?: string): Promise<void>;
|
|
37
|
-
removeClip(id: string, storage: TStorageType): Promise<any>;
|
|
38
|
-
getClipList(): Promise<TClipList>;
|
|
39
|
-
setCamSwitchOptions(data: TCameraOptions, cameraFWVersion: string): Promise<boolean>;
|
|
40
|
-
setGlobalAudioSettings(settings: TGlobalAudioSettings): Promise<boolean>;
|
|
41
|
-
setSecondaryAudioSettings(settings: TSecondaryAudioSettings): Promise<boolean>;
|
|
42
|
-
setDefaultPlaylist(id: string): Promise<boolean>;
|
|
43
|
-
setPermanentRtspUrlToken(token: string): Promise<boolean>;
|
|
44
|
-
getCamSwitchOptions(): Promise<Partial<TCameraOptions>>;
|
|
45
|
-
getGlobalAudioSettings(): Promise<TGlobalAudioSettings>;
|
|
46
|
-
getSecondaryAudioSettings(): Promise<TSecondaryAudioSettings>;
|
|
47
|
-
getPermanentRtspUrlToken(): Promise<string>;
|
|
48
|
-
private get;
|
|
49
|
-
private set;
|
|
50
|
-
private setParamFromCameraJSON;
|
|
51
|
-
private getParamFromCameraAndJSONParse;
|
|
52
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { IWebsocket } from './internal/common';
|
|
2
|
-
import { TCamSwitcherEventOfType, TCamSwitcherEventType } from './types/CamSwitcherEvents';
|
|
3
|
-
type TListenerFunction<T extends TCamSwitcherEventType> = (data: TCamSwitcherEventOfType<T>, isInit: boolean) => void;
|
|
4
|
-
export declare class CamSwitcherEvents<Event extends {
|
|
5
|
-
data: string;
|
|
6
|
-
}> {
|
|
7
|
-
isDestroyed: boolean;
|
|
8
|
-
private ws;
|
|
9
|
-
private listeners;
|
|
10
|
-
setWebsocket(ws: IWebsocket<Event>): void;
|
|
11
|
-
resendInitData(): void;
|
|
12
|
-
addListener<T extends TCamSwitcherEventType>(type: T, listener: TListenerFunction<T>, id: string): void;
|
|
13
|
-
removeListener<T extends TCamSwitcherEventType>(type: T, id: string): void;
|
|
14
|
-
private onMessage;
|
|
15
|
-
private processMessage;
|
|
16
|
-
destroy(): void;
|
|
17
|
-
}
|
|
18
|
-
export {};
|
package/esm/VapixAPI.d.ts
DELETED
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
import { IClient, TParameters } from './internal/common';
|
|
2
|
-
import { TApplication, TAudioSampleRates, TSDCardInfo, TPtzOverview, TCameraPTZItem, TCameraPTZItemData, TAudioDevice } from './types/VapixAPI';
|
|
3
|
-
import { ProxyClient } from './internal/ProxyClient';
|
|
4
|
-
import { TCameraImageConfig, TProxyParam } from './types/common';
|
|
5
|
-
export declare class VapixAPI<Client extends IClient = IClient> {
|
|
6
|
-
client: ProxyClient<Client>;
|
|
7
|
-
constructor(client: Client, getProxyUrl: () => string);
|
|
8
|
-
getUrlEncoded(proxy: TProxyParam, path: string, parameters?: TParameters, headers?: Record<string, string>): Promise<import("./internal/common").TResponse>;
|
|
9
|
-
postJson(proxy: TProxyParam, path: string, jsonData: Record<string, any>, headers?: Record<string, string>): Promise<import("./internal/common").TResponse>;
|
|
10
|
-
getCameraImage(params: TCameraImageConfig, proxy?: TProxyParam): Promise<import("./internal/common").TResponse>;
|
|
11
|
-
getEventDeclarations(proxy?: TProxyParam): Promise<string>;
|
|
12
|
-
getSupportedAudioSampleRate(proxy?: TProxyParam): Promise<TAudioSampleRates[]>;
|
|
13
|
-
performAutofocus(proxy?: TProxyParam): Promise<void>;
|
|
14
|
-
checkSDCard(proxy?: TProxyParam): Promise<TSDCardInfo>;
|
|
15
|
-
mountSDCard(proxy?: TProxyParam): Promise<number>;
|
|
16
|
-
unmountSDCard(proxy?: TProxyParam): Promise<number>;
|
|
17
|
-
private _doSDCardMountAction;
|
|
18
|
-
fetchSDCardJobProgress(jobId: number, proxy?: TProxyParam): Promise<number>;
|
|
19
|
-
downloadCameraReport(proxy?: TProxyParam): Promise<import("./internal/common").TResponse>;
|
|
20
|
-
getSystemLog(proxy?: TProxyParam): Promise<import("./internal/common").TResponse>;
|
|
21
|
-
getMaxFps(channel: number, proxy?: TProxyParam): Promise<number>;
|
|
22
|
-
getTimezone(proxy?: TProxyParam): Promise<string>;
|
|
23
|
-
getDateTimeInfo(proxy?: TProxyParam): Promise<{
|
|
24
|
-
data: {
|
|
25
|
-
dateTime: string;
|
|
26
|
-
dstEnabled: boolean;
|
|
27
|
-
localDateTime: string;
|
|
28
|
-
posixTimeZone: string;
|
|
29
|
-
timeZone: string;
|
|
30
|
-
};
|
|
31
|
-
}>;
|
|
32
|
-
getDevicesSettings(proxy?: TProxyParam): Promise<TAudioDevice[]>;
|
|
33
|
-
fetchRemoteDeviceInfo<T extends Record<string, any>>(payload: T, proxy?: TProxyParam): Promise<any>;
|
|
34
|
-
getHeaders(proxy?: TProxyParam): Promise<Record<string, string>>;
|
|
35
|
-
setHeaders(headers: Record<string, string>, proxy?: TProxyParam): Promise<import("./internal/common").TResponse>;
|
|
36
|
-
getParameter(paramNames: string | string[], proxy?: TProxyParam): Promise<Record<string, string>>;
|
|
37
|
-
setParameter(params: Record<string, string | number | boolean>, proxy?: TProxyParam): Promise<boolean>;
|
|
38
|
-
getGuardTourList(proxy?: TProxyParam): Promise<{
|
|
39
|
-
name: string;
|
|
40
|
-
id: string;
|
|
41
|
-
running: string;
|
|
42
|
-
tour: {
|
|
43
|
-
moveSpeed?: unknown;
|
|
44
|
-
position?: unknown;
|
|
45
|
-
presetNbr?: unknown;
|
|
46
|
-
waitTime?: unknown;
|
|
47
|
-
waitTimeViewType?: unknown;
|
|
48
|
-
}[];
|
|
49
|
-
camNbr?: unknown;
|
|
50
|
-
randomEnabled?: unknown;
|
|
51
|
-
timeBetweenSequences?: unknown;
|
|
52
|
-
}[]>;
|
|
53
|
-
setGuardTourEnabled(guardTourID: string, enable: boolean, proxy?: TProxyParam): Promise<boolean>;
|
|
54
|
-
getPTZPresetList(channel: number, proxy?: TProxyParam): Promise<string[]>;
|
|
55
|
-
listPTZ(camera: number, proxy?: TProxyParam): Promise<TCameraPTZItem[]>;
|
|
56
|
-
listPtzVideoSourceOverview(proxy?: TProxyParam): Promise<TPtzOverview>;
|
|
57
|
-
goToPreset(channel: number, presetName: string, proxy?: TProxyParam): Promise<import("./internal/common").TResponse>;
|
|
58
|
-
getPtzPosition(camera: number, proxy?: TProxyParam): Promise<TCameraPTZItemData>;
|
|
59
|
-
getInputState(port: number, proxy?: TProxyParam): Promise<boolean>;
|
|
60
|
-
setOutputState(port: number, active: boolean, proxy?: TProxyParam): Promise<import("./internal/common").TResponse>;
|
|
61
|
-
getApplicationList(proxy?: TProxyParam): Promise<TApplication[]>;
|
|
62
|
-
startApplication(applicationID: string, proxy?: TProxyParam): Promise<void>;
|
|
63
|
-
restartApplication(applicationID: string, proxy?: TProxyParam): Promise<void>;
|
|
64
|
-
stopApplication(applicationID: string, proxy?: TProxyParam): Promise<void>;
|
|
65
|
-
installApplication(data: Blob, fileName: string): Promise<void>;
|
|
66
|
-
}
|
package/esm/VapixEvents.d.ts
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { EventEmitter2 as EventEmitter } from 'eventemitter2';
|
|
2
|
-
import { WsOptions } from './internal/common';
|
|
3
|
-
export type VapixEventsOptions = WsOptions;
|
|
4
|
-
type TEventMessage = {
|
|
5
|
-
apiVersion: string;
|
|
6
|
-
method: string;
|
|
7
|
-
params: {
|
|
8
|
-
notification: {
|
|
9
|
-
timestamp: number;
|
|
10
|
-
topic: string;
|
|
11
|
-
message: {
|
|
12
|
-
source: Record<string, string>;
|
|
13
|
-
data: Record<string, string>;
|
|
14
|
-
key: Record<string, string>;
|
|
15
|
-
};
|
|
16
|
-
};
|
|
17
|
-
};
|
|
18
|
-
};
|
|
19
|
-
export interface VapixEvents {
|
|
20
|
-
on(event: 'open', listener: () => void): this;
|
|
21
|
-
on(event: 'close', listener: () => void): this;
|
|
22
|
-
on(event: 'error', listener: (err: Error) => void): this;
|
|
23
|
-
on(event: string, listener: (data: TEventMessage) => void): this;
|
|
24
|
-
emit(event: 'open'): boolean;
|
|
25
|
-
emit(event: 'close'): boolean;
|
|
26
|
-
emit(event: 'error', err: Error): boolean;
|
|
27
|
-
emit(event: string, msg: TEventMessage): boolean;
|
|
28
|
-
}
|
|
29
|
-
export declare class VapixEvents extends EventEmitter {
|
|
30
|
-
private tls;
|
|
31
|
-
private tlsInsecure;
|
|
32
|
-
private ip;
|
|
33
|
-
private port;
|
|
34
|
-
private user;
|
|
35
|
-
private pass;
|
|
36
|
-
private ws;
|
|
37
|
-
constructor(options?: VapixEventsOptions);
|
|
38
|
-
connect(): void;
|
|
39
|
-
disconnect(): void;
|
|
40
|
-
private createWsClient;
|
|
41
|
-
private isReservedEventName;
|
|
42
|
-
}
|
|
43
|
-
export {};
|