CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3

Hybrid View

  1. #1
    Join Date
    Aug 2010
    Posts
    1

    Detect Pixel color change

    --------------------------------------------------------------------------------

    I'm trying to figure out some simple code to detect when a single pixel changes color at a location I choose -anywhere- on the screen (ex. 100,100). Maybe with just a msgbox popup when it changes.

    The visual basic program will just be hidden and running in the background.

    I should be able program the rest of the program around it, I just need the detection part. That is where I am stumped.

    Any help would be greatly appreciated!!!

    I'm using Visual Basic 2008

    Thanks in advance!!!!!!!

  2. #2
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: Detect Pixel color change

    Depends on what's on the screen. DirectX draws directly from memory, so it's harder to do.

    Most of the time, it's not for nice purposes, and is against the AUP.

    Why hide the program?
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  3. #3
    Join Date
    Jul 2001
    Location
    Sunny South Africa
    Posts
    11,283

    Re: Detect Pixel color change

    I don't think this violates the AUP at all...

    BashMan, welcome to the forums

    Have you tried using the GetPixel API. You could perhaps use it in a timer to check the colour of the pixel, and once it changes - the colours don't compare - then pop up a messagebox or something? Does that sound like a plan?

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured