Jump to content

What would cause identical images to have different color values among computers?


Recommended Posts

I have been working on a script and its simply designed to read a set of coordinates and search the area, then create a value based on where the pixels are and what color they are. The program would be started after running the program it was designed to watch. It worked properly on one computer returning the same values everytime when watching different images in the program. But once tried on another computer a huge flaw was discovered, that script watching the exact same program on a different computer was returning different values for exact same images placed in the exact same pixel coordinates. Upon closer inspection it was realized that the program I was watching was displaying just slightly different colors between computers and thus the script was returning values that were too far fetched to be reliable.

Ultimately the aim of the program is to recognize an image, this part is only the first step. If both computers had of displayed the same colors within the watched program for the same images, I could then log the values and script in the recognition.

Question: Why do the same programs display different colors on different computers? Is it hardware related? Is it DPI related? Can both computers be set to display exact same colors?

And yes both computers are set to 32bit color quality.

Link to comment
Share on other sites

Ok, I have not explained properly, when I say "images" i don't mean files. The program is just displaying its own graphics its not calling specific image files like jpgs. It's a game, and the script only searches 143 pixels in the exact same spot...... BUT its searched at the time when the game is displaying the EXACT same screen, but really the issue isnt the script its why are our computers displaying different values for EXACT same images... like if I take a screenshot of the watched program on both computers and I look at the exact same spots when its displaying the same screens the colors are slightly different...

Link to comment
Share on other sites

  • Moderators

PixelCoordMode

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

PixelCoordMode

The issue is not the script!!!!! pixelcoordmode is set to client area.... im telling you we both run this program the same screen shows up..... we both take a screenshot, we then zoom in and examine what are supposed to be IDENTICAL screenshoots of the program, yet one computer is slightly different, enough that using pixel by pixel recognition wont work.

Again, its not the scripts fault that it things its a different color... the computers are simply out putting a slightly different color for the same screen, and its obvious to the human eye (upon zooming :)). But in order for my script to work on multiple computers I need to know why the computers are generating different colors on the same screen.

I have been trying to figure it out why this happens and one thing I noticed is that if you go into display properties > settings > Advanced > Color Management... it talks about a color profile that defines what colors the monitor displays... and this seems like it could be the problem, maybe if perhaps we both had the same profiles it would be compatible. HELP!

Edited by dennism
Link to comment
Share on other sites

  • Moderators

The issue is not the script!!!!!

I didn't get past this point.

1. Do we take your word for it? ... Um no.

2. Do we have a recreation script that reproduces the error? ... Um no.

3. Should we even attempt to waste any brain power on something you care so little about to not provide a re-production script and the applications name too so we can test for ourselves... Um HELL NO!!!

Peace out... and good luck!

Edit:

1 final thing.. did you ever think to check the PC's dpi settings?

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

LOL that was so vicious and snotty. I will explain myself! Heres the deal, me and my friend both open our pokerchamps client, and when the cards come up say for instance two ACE OF HEARTS .... we take a screenshot and then we zoom in on the card his, then mine and visually our computers put out a different shade of red (4 color suit).... so this has NOTHING to do with the script, but since you've been so rude and ignored me I attached the script..

To run it the way we are, you must download, install and sign for pokerchamps. You then have to spectate any poker table. When the flop appears, you press "R" the script will generate a number (like a checksum), based on pixel location and color. Aftering pressing R, numbers will appear on the GUI, you then manually type in what card belongs to each number and press the "All" button. It then writes that to a log, then we sit there and we collect perhaps 20 cards. We then take the script to a new computer, and when we run the same script which searchs the EXACT same pixels everytime, returns a different value. BUT once again as I said, its obvious why the script doesnt work and its because each damn computer is displaying slightly different colors which makes the checksum totally useless (both autoit's and this custom checksum my friend scripted)...

Also, if you really are gonna go through all the trouble of testing the script to tell me how im an idiot I will include our logs. But like I said. I KNOW why the script doesn't work but theoretically it should, like if I never had to switch computers I wouldn't even be complaining right now cause it would be working fine but since it needs to be compatible across multiple computers its useless the way it is. But the bottom line is that our computers are displaying slightly different colors!

I didn't get past this point.

1. Do we take your word for it? ... Um no.

2. Do we have a recreation script that reproduces the error? ... Um no.

3. Should we even attempt to waste any brain power on something you care so little about to not provide a re-production script and the applications name too so we can test for ourselves... Um HELL NO!!!

Peace out... and good luck!

Edit:

1 final thing.. did you ever think to check the PC's dpi settings?

poker.rar

Link to comment
Share on other sites

Edit:

1 final thing.. did you ever think to check the PC's dpi settings?

I am about to thats a good point, haha...

Edit: Friend isnt home to check, but I dont see any reason why he would have changed his dpi to 120, mines at normal so I doubt thats the issue.. But this is driving me nuts.

Edited by dennism
Link to comment
Share on other sites

  • Moderators

LOL that was so vicious and snotty.

No it's informed, and knowledgeable ...

I will explain myself! Heres the deal, me and my friend both open our pokerchamps client, and when the cards come up say for instance two ACE OF HEARTS .... we take a screenshot and then we zoom in on the card his, then mine and visually our computers put out a different shade of red (4 color suit).... so this has NOTHING to do with the script, but since you've been so rude and ignored me I attached the script..

As I stated before, it's not the colors are different, it's the settings you've set you computers at... jesus, a week and you still haven't figured that out?.... if he's that much more of a programmer than you... there's no telling where this world may come too.

To run it the way we are, you must download, install and sign for pokerchamps. You then have to spectate any poker table. When the flop appears, you press "R" the script will generate a number (like a checksum), based on pixel location and color. Aftering pressing R, numbers will appear on the GUI, you then manually type in what card belongs to each number and press the "All" button. It then writes that to a log, then we sit there and we collect perhaps 20 cards. We then take the script to a new computer, and when we run the same script which searchs the EXACT same pixels everytime, returns a different value. BUT once again as I said, its obvious why the script doesnt work and its because each damn computer is displaying slightly different colors which makes the checksum totally useless (both autoit's and this custom checksum my friend scripted)...

Also, if you really are gonna go through all the trouble of testing the script to tell me how im an idiot I will include our logs. But like I said. I KNOW why the script doesn't work but theoretically it should, like if I never had to switch computers I wouldn't even be complaining right now cause it would be working fine but since it needs to be compatible across multiple computers its useless the way it is. But the bottom line is that our computers are displaying slightly different colors!

The only 2 ways I could even fathom it being different from one pc to the other is:

1. The site is smarter than you.. and has decided to make multiple graphics to elude bot playing.

2. Your DPI settings as I previously mentioned. (Also, font smoothing etc.. may be something to look at)

You want it to be so black and white, and not blame your code.... I've now looked at it... although I'm not impressed, I'd say it's more your lack of knowledge/research on how Windows/PC's may act different from one PC to the next....

So next time when you want to call someone "rude"... be sure you're f**king with someone that knows far less than you, and can offer you nothing with their words of advice.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

No it's informed, and knowledgeable ...

As I stated before, it's not the colors are different, it's the settings you've set you computers at... jesus, a week and you still haven't figured that out?.... if he's that much more of a programmer than you... there's no telling where this world may come too.

The only 2 ways I could even fathom it being different from one pc to the other is:

1. The site is smarter than you.. and has decided to make multiple graphics to elude bot playing.

2. Your DPI settings as I previously mentioned. (Also, font smoothing etc.. may be something to look at)

You want it to be so black and white, and not blame your code.... I've now looked at it... although I'm not impressed, I'd say it's more your lack of knowledge/research on how Windows/PC's may act different from one PC to the next....

So next time when you want to call someone "rude"... be sure you're f**king with someone that knows far less than you, and can offer you nothing with their words of advice.

Hey man, I never said anything about you knowing nothing you just attacked me when I was asking a question. And as I said from the start it was never about my script, infact I should have never even mentioned a script I just wanted some possible reasons why 2 computers would output different color values thats all man. You've got 10000 posts I've got like 6, you > me whats your point? I had a simple question, was expecting simple answers not to get yelled at.

Link to comment
Share on other sites

  • Moderators

@DesktopDepth

Edit:

Let me iterate the above...

If he's on 16 bit and you're on 32 bit depth... guess what...

Now that I think about it, this would be the most common occurence... gamers like the 16 bit for speed... but others like the 32 bit for clarity.

As far as "attacking" you... no... I wasn't... but you were damn sure it wasn't your script, and in fact it is... you didn't make exceptions.... (the black and white thing)

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

but you were damn sure it wasn't your script, and in fact it is... you didn't make exceptions.... (the black and white thing)

Not pickin up what your putting down, and yes were both on 32 bit I think I mentioned that earlier.

Edit: And I was just re-reading one of your posts and you say its not that the colors are different ... well I know that, of course the program itself is displaying the same thing but the settings between computers are causing it to display differently... so to sum up everything I have said in this thread, what settings could cause this? We are both on 32bit, im pretty sure he had same dpi, I dunno what else would cause the color fluctuation thats why I was hoping members of the forum may have some idea, thanks for taking the time to respond with possible fixes I greatly appreciate it,

Edited by dennism
Link to comment
Share on other sites

My program runs on all of my computers, with vastly different graphics capabilities, and different operating systems.

I do not know what your problem is. Your code fragment is more structured than mine (which is not surprising to me). I briefly tried, and then discarded a method similar to the one you use, in favor of a straightforward Pixelchecksum. No problems at all.

Detecting the dealt cards is just step one of many.

If having your program work on multiple computers simultaneously is that important to you, it sounds like a collusion assistant. If it is, telling people what site you play at, and having your friends name at the top of the code you posted was not a good move.

"I've seen your work in the past, and it's novice at best..." SmOke_N
Link to comment
Share on other sites

My program runs on all of my computers, with vastly different graphics capabilities, and different operating systems.

I do not know what your problem is. Your code fragment is more structured than mine (which is not surprising to me). I briefly tried, and then discarded a method similar to the one you use, in favor of a straightforward Pixelchecksum. No problems at all.

Detecting the dealt cards is just step one of many.

If having your program work on multiple computers simultaneously is that important to you, it sounds like a collusion assistant. If it is, telling people what site you play at, and having your friends name at the top of the code you posted was not a good move.

lol, collusion is a waste of time, simply an odds calculator to be honest. The reason I need it to work on multiple computers is that I play both on my home computer, my lap top and on my girlfriends computer. Two other friends will also be using it on their computer/laptops, just cause it works for one person is pointless. And of course detecting the cards is just one step, to be blunt its the first step, without it nothing is possible.

It just pisses me off that even my first script I wrote, which works absolutely perfectly on my computer (well a couple minor issues)... wont even recognize 1 card on the other computer and we have the same settings.

Automan: The script below uses just checksums too, its much less complicated no functions just hella script, but it works perfectly on my computer. Also, someone mentioned that the game might purposely change the colors to avoid bots but I don't believe that to be the case cause no matter what on one computer it works every time no matter what. Same working script on the other computer doesn't work...

If any one wants to take a minute to download pokerchamps and try it on your computer then that would be great I have created a test account so anyone can just download and try it quickly if they are really cool :),

heres the first script I wrote, simply login Secure Code: HenryHank Password: 12345

After downloading and installing:

- Ensure you have 32bit display colors

- Open pokerchamps

- Sit down at any "Fun Money" table, to the immediate left of the chat window you will see a thing called "Control Panel" open it

- Turn on 4 colored deck

- Run script, the rest will be self explanatory, while waiting for a flop it will display ? if it appears and it does not know the cards it will say "Unknown" if it knows it, it will tell you.

Please note, if you do take the time to run it then please ignore the rest of the information thats displayed its just some debugging script that I am too lazy to comment.

test.au3

Edited by dennism
Link to comment
Share on other sites

well, lazy... write a short script that shows the problem... until then I suspect your scripting skills.

Lar.

Larry. Please please please please.... forgot I ever mentioned ANYTHING about a script. Lets pretend there was never a script, now why do different computers display colors differently, thats all I need to know.

Both computers are set to 32bit graphics.

Edited by dennism
Link to comment
Share on other sites

  • 4 weeks later...

I've worked on a bot for a 3d online game too. I had the same problem, having different colors for different PC.

I created an ini file with the configuration of the specific color of that PC. Each pc will have it own ini file with it own color.

Another solution is to create an array with all colors variation of that color.

Link to comment
Share on other sites

  • 2 weeks later...

I know I'm a little late to this, but I would say the most likely candidate is software that causes gamma correction. Many monitors come with gamma correction software and installs itself automatically. Additionally many graphics cards have their own setting for displaying video. Just a thought.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...