Skip to content

Commit 7bf3f65

Browse files
authored
Update README.md
1 parent 97fd4a0 commit 7bf3f65

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,22 @@ pip3 install -U pyobjc
3737
```
3838
I have not tested myself as I don't own a mac, but it was tested and documented in this issue : https://github.com/drov0/python-imagesearch/issues/5
3939

40+
## Quick start
41+
42+
The simplest example to do image search with python is this:
43+
44+
```
45+
from python_imagesearch.imagesearch import imagesearch
46+
47+
pos = imagesearch("./github.png")
48+
if pos[0] != -1:
49+
print("position : ", pos[0], pos[1])
50+
else:
51+
print("image not found")
52+
```
53+
54+
this searches for one occurrence of the image “github.png” on the screen and print its x/y position
55+
56+
Some advanced examples exists here (yes I shut down my blog and forgot to save it): https://web.archive.org/web/20221130045749/https://brokencode.io/how-to-easily-image-search-with-python/
57+
58+
Exact function definitions can be found here: https://github.com/drov0/python-imagesearch/blob/master/python_imagesearch/imagesearch.py

0 commit comments

Comments
 (0)