Thank you very much for this
I had a question as far as manipulating pixel data. I have everything working perfectly, until I get to the spot where I need to change the value that the "$bits" pointer points to.
#include <FreeImage.au3>
OnAutoItExitRegister("Cleanup")
func Main()
_FreeImage_LoadDLL(@ScriptDir&"\FreeImage.dll")
_FreeImage_Initialise()
;=============================================================================
Global $image = _FreeImage_Load($FIF_TIFF, "test.tif")
$bitdepth = _FreeImage_GetBPP($image)
$bitsperpixel = _FreeImage_GetLine($image) / _FreeImage_GetWidth($image)
Msgbox(0, "", $bitsperpixel)
Local $bits
;$temp = _FreeImage_GetChannel($image, $FICC_RED)
$y = 0
$x = 0
for $y = 0 to _FreeImage_GetHeight($image) step 1
$bits = _FreeImage_GetScanLine($image, $y)
;Tooltip($bits)
for $x = 0 to _FreeImage_GetWidth($image) step 1
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;Manipulate Pixel here;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
$bits = $bits + $bitsperpixel
next
next
Msgbox(0, "", "Done")
_FreeImage_Save($FIF_TIFF, $image, "test.tif")
endfunc
Main()
Exit
func Cleanup()
_FreeImage_Unload($image)
_FreeImage_DeInitialise()
endfunc
I've been looking everywhere for how to manipulate data from a pointer (Like in C++, the simple *ptr), and all I'm getting is Cheat Engine stuff