how to crop image Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Tear
Posts: 23
Joined: 22 Jul 2018, 09:46

how to crop image

22 Jul 2018, 09:53

hello guys!

i want to know how to crop image.

i use gdip. and i want use these.

Target_Hwnd := WinExist("A")
pToken := Gdip_Startup()
pBitmap := Gdip_BitmapFromHWND(Target_Hwnd)
Gdip_SaveBitmapToFile(pBitmap, "capture.bmp", 100)
Gdip_DisposeImage(pBitmap)
Gdip_Shutdown(pToken)
return

if i use these , just captured hwnd. i want crop the image. how can i do that?
coordinate is 25,206,253,61
trust_me
Posts: 98
Joined: 29 Jul 2017, 10:46

Re: how to crop image  Topic is solved

22 Jul 2018, 11:42

Code: Select all

Target_Hwnd := WinExist("A")
pToken := Gdip_Startup()
pBitmap := Gdip_BitmapFromHWND(Target_Hwnd)
bm_cropped:=Gdip_CloneBitmapArea(pBitmap, 25,206,253,61 )

Gdip_SaveBitmapToFile(bm_cropped, "capture.bmp")
Gdip_DisposeImage(pBitmap)
Gdip_DisposeImage(bm_cropped)
Gdip_Shutdown(pToken)
return

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Anput, jameswrightesq and 279 guests