ms-types 0.10.9 → 0.10.11
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/package.json +1 -1
- package/types/cryptoUtils.d.ts +50 -36
- package/types/dotocr.d.ts +9 -2
- package/types/file.d.ts +1 -1
- package/types/hid.d.ts +47 -5
- package/types/image.d.ts +447 -447
- package/types/lua/action.lua +6 -6
- package/types/lua/cryptoUtils.lua +7 -7
- package/types/lua/cv.lua +142 -142
- package/types/lua/dotocr.lua +4 -4
- package/types/lua/file.lua +1 -1
- package/types/lua/global.lua +5 -3
- package/types/lua/hid.lua +23 -23
- package/types/lua/http.lua +26 -11
- package/types/lua/image.lua +9 -5
- package/types/lua/node.lua +1 -1
- package/types/lua/pip.lua +6 -6
- package/types/lua/yolo.lua +1 -1
- package/types/lua/yolocls.lua +1 -1
- package/types/node.d.ts +1 -0
- package/types/opencv.d.ts +571 -38
- package/types/paddleocr.d.ts +1 -0
- package/types/pip.d.ts +11 -0
- package/types/system.d.ts +1 -0
- package/types/tts.d.ts +1 -1
- package/types/ui.d.ts +2 -0
- package/types/web.d.ts +16 -0
- package/types/zh/HID/346/250/241/345/235/227.d.ts +47 -5
- package/types/zh/PaddleOCR/346/250/241/345/235/227.d.ts +1 -0
- package/types/zh//345/212/250/344/275/234/346/250/241/345/235/227.d.ts +1 -1
- package/types/zh//346/202/254/346/265/256/347/252/227/346/250/241/345/235/227.d.ts +10 -0
- package/types/zh//346/226/207/344/273/266/346/250/241/345/235/227.d.ts +1 -1
- package/types/zh//347/202/271/351/230/265OCR/346/250/241/345/235/227.d.ts +9 -2
- package/types/zh//347/263/273/347/273/237/346/250/241/345/235/227.d.ts +1 -0
- package/types/zh//350/212/202/347/202/271/346/250/241/345/235/227.d.ts +1 -0
- package/types/zh//350/247/206/345/233/276/346/250/241/345/235/227.d.ts +2 -0
|
@@ -22,13 +22,18 @@ declare namespace $点阵OCR {
|
|
|
22
22
|
* 常见路径如 `/fonts/default.json`;运行时会解析 `res` 目录。
|
|
23
23
|
* 字库 JSON 中每个字符自带前景色/偏色(`threshold`),识别时按各字颜色匹配。
|
|
24
24
|
* @returns 成功返回字库 ID,失败返回 `null`
|
|
25
|
+
* @example $点阵OCR.加载字库("/fonts/default.json")
|
|
25
26
|
*/
|
|
26
27
|
function 加载字库(字库资源路径: 字符串): 字符串 | null;
|
|
27
28
|
|
|
28
|
-
/** 释放指定字库。未加载也视为成功。
|
|
29
|
+
/** 释放指定字库。未加载也视为成功。
|
|
30
|
+
* @example $点阵OCR.释放("fontId")
|
|
31
|
+
*/
|
|
29
32
|
function 释放(字库ID: 字符串): void;
|
|
30
33
|
|
|
31
|
-
/** 释放全部已加载的点阵字库。
|
|
34
|
+
/** 释放全部已加载的点阵字库。
|
|
35
|
+
* @example $点阵OCR.释放全部()
|
|
36
|
+
*/
|
|
32
37
|
function 释放全部(): void;
|
|
33
38
|
|
|
34
39
|
/**
|
|
@@ -36,6 +41,7 @@ declare namespace $点阵OCR {
|
|
|
36
41
|
* 颜色按字库逐字自带的前景色/偏色匹配,无需额外传色。
|
|
37
42
|
* 结果按行从上到下、同行从左到右排列。
|
|
38
43
|
* @param 置信度阈值 相似度下限;`<=0` 时按 `0.95`;`>0.95` 时要求像素完全一致
|
|
44
|
+
* @example $点阵OCR.识别绝对坐标("fontId", "screen", 100, 100, 200, 200, 0.95)
|
|
39
45
|
*/
|
|
40
46
|
function 识别绝对坐标(
|
|
41
47
|
字库ID: 字符串,
|
|
@@ -51,6 +57,7 @@ declare namespace $点阵OCR {
|
|
|
51
57
|
* 先识别再按行查找目标串,返回命中位置的绝对坐标。
|
|
52
58
|
* `完整匹配=false`:行内子串包含;`完整匹配=true`:整行文本必须完全等于目标。
|
|
53
59
|
* 每个目标最多返回一次命中(最先匹配到的行)。
|
|
60
|
+
* @example $点阵OCR.查找文本绝对坐标("fontId", "screen", ["开始"], 100, 100, 200, 200, 0.95, false)
|
|
54
61
|
*/
|
|
55
62
|
function 查找文本绝对坐标(
|
|
56
63
|
字库ID: 字符串,
|