mirror of
https://github.com/go-vgo/robotgo.git
synced 2025-05-31 06:13:55 +00:00
Update examples
This commit is contained in:
parent
29c6d82cd7
commit
5afcb0af9c
@ -30,15 +30,15 @@ func main() {
|
||||
bitmap := robotgo.CaptureScreen(100, 200, 30, 40)
|
||||
fmt.Println("CaptureScreen...", bitmap)
|
||||
|
||||
// searches for needle in bitmap
|
||||
fx, fy := robotgo.FindBit(bitmap)
|
||||
fmt.Println("FindBitmap------", fx, fy)
|
||||
|
||||
color := robotgo.GetColor(bitmap, 1, 2)
|
||||
fmt.Println("color...", color)
|
||||
cx, cy := robotgo.FindColor(bitmap, color, 1.0)
|
||||
fmt.Println("pos...", cx, cy)
|
||||
|
||||
// searches for needle in bitmap
|
||||
fx, fy := robotgo.FindBit(bitmap)
|
||||
fmt.Println("FindBitmap------", fx, fy)
|
||||
|
||||
bit := robotgo.CaptureScreen(1, 2, 40, 40)
|
||||
fmt.Println("CaptureScreen...", bit)
|
||||
fx, fy = robotgo.FindBitmap(bit)
|
||||
|
@ -140,15 +140,15 @@ func bitmap() {
|
||||
bitmap := robotgo.CaptureScreen(100, 200, 30, 40)
|
||||
fmt.Println("CaptureScreen...", bitmap)
|
||||
|
||||
// searches for needle in bitmap
|
||||
fx, fy := robotgo.FindBit(bitmap)
|
||||
fmt.Println("FindBitmap------", fx, fy)
|
||||
|
||||
color := robotgo.GetColor(bitmap, 1, 2)
|
||||
fmt.Println("color...", color)
|
||||
cx, cy := robotgo.FindColor(bitmap, color, 1.0)
|
||||
fmt.Println("pos...", cx, cy)
|
||||
|
||||
// searches for needle in bitmap
|
||||
fx, fy := robotgo.FindBit(bitmap)
|
||||
fmt.Println("FindBitmap------", fx, fy)
|
||||
|
||||
bit := robotgo.CaptureScreen(1, 2, 40, 40)
|
||||
fmt.Println("CaptureScreen...", bit)
|
||||
fx, fy = robotgo.FindBitmap(bit)
|
||||
|
@ -55,7 +55,7 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
version string = "v0.46.0.385, Pyrenees Mountains!"
|
||||
version string = "v0.46.0.400, Pyrenees Mountains!"
|
||||
)
|
||||
|
||||
// GetVersion get version
|
||||
|
Loading…
Reference in New Issue
Block a user