Hello.
Does anyone know if there could be a problem with capturing an image with the Image Recognition Wizard, and then running a compiled script searching for that image on another computer with a different desktop resolution, than the one it was captured with?
Thanks in advance!
Image recognition and different desktop resolutions
Moderators: JRL, Dorian (MJT support)
- Dorian (MJT support)
- Automation Wizard
- Posts: 1415
- Joined: Sun Nov 03, 2002 3:19 am
Re: Image recognition and different desktop resolutions
Yes, you usually have to resample the images when using Image Recognition on a different PC.
Re: Image recognition and different desktop resolutions
Oh well.. That might be a problem for me
I'm gonna have to be creative..
Thanks!

I'm gonna have to be creative..
Thanks!
Re: Image recognition and different desktop resolutions
Is there any solution?


Re: Image recognition and different desktop resolutions
You could use pixel values instead of using the entire screen as the search area..
At the beginning of the script store the screen resolution into variables and set it to a ratio of the screen resolution the script was originally written for. Modify the needle image xy resolution values by this ratio.. might have to use COEFF and drop quality to make it work..
At the beginning of the script store the screen resolution into variables and set it to a ratio of the screen resolution the script was originally written for. Modify the needle image xy resolution values by this ratio.. might have to use COEFF and drop quality to make it work..
Re: Image recognition and different desktop resolutions
All my compiled macros that are to be portable include code to "train" image on the target computer, meaning on first run the macro will record (screencapture) the needed needles. it is not much of a problem if the resolution is different but once the DPI changes as it does on laptops 110dpi to desktops 96dpi then thats when you have a problem, thats why i dont support laptop usage, 99% of desktops are 1920x? with a DPI of 96. If you have control of the target desktop you can set the color profile of that desktop to "none", then the colors and images will most likely be the same. keep in mind that my "training" code can be just as complex (1000s of lines of code) as the actual macro code because everything is unknown at the time. For example for one of my macros "training" takes 1-3 hours, but after this training it works just the same as it does on the development PC and worth it since the macros run 24/7. So if you have control of the target PC as in the case of a company, then first try to delete any monitor screen profiles first, in lieu of that youll need to write training code to make your code portable between unknown enviroments. just my input 
