Implement OCR
This commit is contained in:
parent
f58c7e3668
commit
c6c9337e8b
10
main.cjs
10
main.cjs
@ -217,13 +217,13 @@ function getMatchingPhrase(inputString, targetCharacter) {
|
|||||||
checkString = ret.data.text;
|
checkString = ret.data.text;
|
||||||
await worker.terminate();
|
await worker.terminate();
|
||||||
})();
|
})();
|
||||||
if (checkLoop(message, checkString)) {
|
console.log("Checking OCR contents...");
|
||||||
return;
|
if (checkLoop(message, checkString)) {
|
||||||
}
|
return;
|
||||||
|
}
|
||||||
checkString = checkString.replace(/[^a-zA-Z0-9]/g, '');
|
checkString = checkString.replace(/[^a-zA-Z0-9]/g, '');
|
||||||
checkLoop(message, checkString);
|
checkLoop(message, checkString);
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user