java - Scan screen for color -


I would like to scan the screen for a particular color.

Any idea how to do this?

  robot robots = new robots (); Rectangle Captures = New Rectangle (Toolkit.Get DefaultToolKit (). GetScreenSize ()); Buffer image buffard image = robot.createcreenscapture (capture size); // ... int color = image.getRGB (x, y); Int red = (Color & amp; 0x00ff0000) & gt; & Gt; 16; Int green = (Color & amp; 0x0000ff00) & gt; & Gt; 8; Int Blue = Color & amp; 0x000000ff; // ...  

Comments

Post a Comment

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -