Posted 02 June 2012 - 08:48 AM
In linux bash and cmd there are operators to redirect input/output (<,>,|) and I am interested how does solve Windows API this problem. I would like to write some command in ahk to dllcommand. My need is to pass input data (image) into program. So is here anybody who can help me or to refer me on some good page?
Posted 02 June 2012 - 10:51 AM
I watched the MSDN manual, but cannot to find the answer for redirecting input/output to application (how to call application and to pass the data to it).
I use Autohotkey L, what is the difference from Autohotkey H?
I checked the thread for Autohotkey R but I still miss some basic tutorial for start to work with it or with dllCall.
What I would like to do is to change one line in ScreenCapture.ahk to pass image to ImageMagick (convert.exe) to process it before save. See <!-- l --><a class="postlink-local" href="http://www.autohotkey.com/community/viewtopic.php?f=1&t=87063#p540435">viewtopic.php?f=1&t=87063#p540435</a><!-- l -->
BTW: You have broken link there in this post:
<!-- l --><a class="postlink-local" href="http://www.autohotkey.com/community/viewtopic.php?t=55442#p540390">viewtopic.php?t=55442#p540390</a><!-- l -->
Posted 02 June 2012 - 12:53 PM
What would be needed to do it?
I would try to use a clipboard as channel, but I am not sure it this will not affect performance.
Yes, that is the link that doesn't work
Is that the link I fixed?
Posted 02 June 2012 - 05:47 PM
Posted 02 June 2012 - 06:13 PM
The fastest method would be to use conversion functions from a Dll. Those can be accessed through DllCall by AHK. You can pass a HBITMAP to a function that accepts and processes it.
Do you mean GDI+ dll or dll from ImageMagick?
I think it could be very complicated, because ImageMagick is really not simple. It is simple to write some command, but I think it would not be simple to call the inner functions separately. Also I am not expert on IM source, so cannot imaging to manage to do that.
Posted 02 June 2012 - 09:44 PM
Posted 03 June 2012 - 08:24 AM
Posted 03 June 2012 - 02:20 PM
Posted 04 June 2012 - 07:07 PM
Posted 09 June 2012 - 11:07 AM
Input condition for detection should be color of the pixels and amount of pixels in a group.
For example, if you can look on the blue bar Quick Reply. If it would be color #A67A11, the function should look for this color, and to find all pixels, that are adjacent/neighbouring. The minimum number of pixels in a group would be 8000. So the function would filter all pixels, which are not in the bar. And now would be a decision if the result should keep the original color, even with the text "Quick Reply" or to change whole bar to white, and rest of image would be black. Are there some functions or tutorials how to do something similar?
I know it is possible to save the image from screen and to change it later by ImageMagick, but IM has not this function, that is could detect amount of pixels in a group of pixels. So if there would be some solution in GDI+ or elsewhere, I would use it.