// similarity = e.g. 0.99f static FoundImg rgbRawImageSearch_searchHereOnly(RGBImage big, RGBImage pat, float similarity, Pt searchHereOnly) { int wp = pat.getWidth(), hp = pat.getHeight(); int w = big.getWidth(), h = big.getHeight(); float maxError = (1f-similarity)*wp*hp; float diff = rgbImageSectionsSimilarity(big, pat, searchHereOnly.x, searchHereOnly.y, maxError); if (diff <= maxError) { float sim = 1-diff/(wp*hp); ret new FoundImg(new Rect(searchHereOnly.x, searchHereOnly.y, wp, hp), sim); } null; }
Began life as a copy of #1006913
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1007101 |
Snippet name: | rgbRawImageSearch_searchHereOnly |
Eternal ID of this version: | #1007101/3 |
Text MD5: | 15eec31de72e03ea16ea78a365e18088 |
Author: | stefan |
Category: | javax / imaging |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-03-03 01:17:35 |
Source code size: | 543 bytes / 12 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 438 / 484 |
Version history: | 2 change(s) |
Referenced in: | [show references] |