Forum Discussion

sherrington's avatar
sherrington
Occasional Contributor
10 years ago

Screen settings etc for reliable image comparison.


Hi,

I and a colleague are noobs to TC.





If we run the same Borland C++Builder-built app executable on our pcs, they display different sub-panel sizes.



Hence, if my colleague creates a test on his machine and I try to run it on my pc, the image/region comparison fails because my images are 25% bigger than his.



We have checked and are using the same items for:



Windows theme

resolution 1920 x 1200

transparent off.

DPI set to 9 point Segoe UI at 96 pixels per inch, and "Use Windows XP style DPI scaling" checked.





Our screen sizes are 24inch. However, my 2 screens are  DELL U2410(DP) which have an aspect ratio of 16:9, my colleague has 2 DELL 2405FPW, with an aspect ratio of 16:10.

 

Would this be causing the problom? How can I resolve it?



What other items should I look at?


5 Replies

  • I had the same problem and I use next code for set main window size:


              Call Aliases.MyApp.DevExFrameWindow.Restore


              Call Aliases.MyApp.DevExFrameWindow.Position(0, 0, 1600, 900)

     

  • sherrington's avatar
    sherrington
    Occasional Contributor
    Hi, Maxim, thanks for the reply.

    I did try setting the window to full size with a position call, but I had the same problem.

  • if you have differences in color (and shape is match) so you can add much more color tolerance. It can be depend on what video driver you use. I'm afraid there is no solution.



    I have VM with the same problem and I use images only from it.



    As a last resort you can create some pictures from each computer and compare screenshot with each etalon.
  • chrisb's avatar
    chrisb
    Regular Contributor
    Adjust the tolerances for the image matching. I don't know how to do this in TC but I am sure there would be settings there somewhere to do it. Make the image matching a bit fuzzy. You'll need to find the sweet spot where the tests can find a change in the image and handle differences in rendering between machines.
    Also suggest making sure your Windows Themes match, subtle differences in how the border of window is rendered between one theme and another could break your test.


  • sherrington's avatar
    sherrington
    Occasional Contributor
    Thanks for the ideas. Unfortunately the images are physically 25% different is size..