|
-
April 11th, 2007, 02:12 AM
#1
Get pixel value (onclick)
Hello,
I'm kind of a newbie in Visual C++ and I'm doing a image processing project in which I need to get specific pixel values whenever I click on a bitmap image.
I'd appreciate if you gave me some hints and code on how to do this
Thanks
-
April 11th, 2007, 03:20 AM
#2
Re: Get pixel value (onclick)
Your question is not clear, explain clearly.
One's mistake cannot be your excuse!
-
April 11th, 2007, 03:31 AM
#3
Re: Get pixel value (onclick)
-
April 11th, 2007, 04:08 AM
#4
Re: Get pixel value (onclick)
I want to get the pixel's value(RGB) and coordinates when I click on a point (pixel) inside a BMP image.
Hope this explains it better.
Thanks
-
April 11th, 2007, 04:45 AM
#5
Re: Get pixel value (onclick)
You will need to Add message Handler for WM_LBUTTONDOWN or Handle WM_LBUTTONDOWN message. you could use GetCursorPos API to get the coordinates of the mouse cursor and use GetPixel as Skizmo suggested to get the RGB value at the specified point.
One's mistake cannot be your excuse!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|