• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 195
  • Last Modified:

Get color of pix 1,1 of an image?

Hello

How can I get the color of a specifig pixel of an image? Say the 0,0-pixel?

Thanks

Sven
0
Svenrutten
Asked:
Svenrutten
1 Solution
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
What is the format of the image?

If you can open it with the Image() class then create a Bitmap() from it and use GetPixel().

Something like:

    Dim img As Image = Image.FromFIle("c:\someImage.someExtension")
    Dim bmp As New Bitmap(img)
    Dim c As Color = bmp.GetPixel(0,0)
    Debug.WriteLine(c.ToString())
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now