{"id":15997835,"url":"https://github.com/rparrett/template-match","last_synced_at":"2025-02-22T19:50:01.151Z","repository":{"id":152725793,"uuid":"115756426","full_name":"rparrett/template-match","owner":"rparrett","description":"A slightly rusty alternative to ImageSearchDLL","archived":false,"fork":false,"pushed_at":"2018-01-02T17:35:55.000Z","size":848,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-15T20:15:45.996Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rparrett.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-12-29T21:52:29.000Z","updated_at":"2020-06-23T07:16:50.000Z","dependencies_parsed_at":null,"dependency_job_id":"cce6717f-d849-4ff2-b10b-31dad5a82485","html_url":"https://github.com/rparrett/template-match","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rparrett%2Ftemplate-match","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rparrett%2Ftemplate-match/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rparrett%2Ftemplate-match/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rparrett%2Ftemplate-match/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rparrett","download_url":"https://codeload.github.com/rparrett/template-match/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240229935,"owners_count":19768588,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-08T08:04:24.520Z","updated_at":"2025-02-22T19:50:01.125Z","avatar_url":"https://github.com/rparrett.png","language":"Rust","readme":"# Template Match\n\nA slghtly rusty alternative to [ImageSearchDll](https://github.com/MyBotRun/Libraries/blob/master/ImageSearchDLL) for AutoIt3.\n\nRelies on [imageproc](https://github.com/PistonDevelopers/imageproc) and a lot of `unsafe`.\n\n### Why?\n\nIf you currently rely on ImageSearchDll and want something with a different license, this may interest you.\n\n### Build\n\nTested with\n```\nstable-x86_64-pc-windows-gnu / rustc 1.22.1\nnightly-x86_64-pc-windows-gnu / rustc 1.24.0-nightly\n```\n\n```\ncargo build --release\ncp target/release/template_match.dll autoit_project_directory\ncp au3/template-match.au3 autoit_project_directory\n```\n\n### Usage\n\n```AutoIt\n; usage.au3\n\n#include \u003ctemplate-match.au3\u003e\n\nFunc Main()\n    Local $result = TemplateMatch(\"needle.png\")\n    ; $error = TemplateMatchRect(\"needle.png\", $x, $y, $w, $h);\n\n    If ($result[3] \u003c\u003e 0) Then\n        ConsoleWrite(\"Error #\" \u0026 $result[3] \u0026 @CRLF)\n        Return\n    EndIf\n\n    ConsoleWrite(\"Best X \" \u0026 $result[0] \u0026 @CRLF)\n    ConsoleWrite(\"Best Y \" \u0026 $result[1] \u0026 @CRLF)\n    ConsoleWrite(\"Root Mean Square Error \" \u0026 $result[2] \u0026 @CRLF)\n\n    If ($result[2] \u003c 10.0) Then\n        ConsoleWrite(\"Found a good match!\" \u0026 @CRLF)\n    EndIf\nEndFunc\n\nMain()\n```\n\n### TODO\n\n* Some way to return multiple matches with a threshold\n* Optionally pass a HWND\n* What's the situation with multiple displays?\n* Transparency\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frparrett%2Ftemplate-match","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frparrett%2Ftemplate-match","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frparrett%2Ftemplate-match/lists"}