How to get COLOR of a particular point? RRS feed

  • Question

  • User-725550490 posted
    Hi, I've a BMP image. As a Graphics object , programatically I plotted some points/circles on the image and save it. This is all ok. But I've a further requirement: before plotting my points/circles, I need to check what color is it on the BMP image for that point (X,Y) first. e.g. if it is blue which represents an ocean, I don't plot. I don't know how to get/know the COLOR of a particular point (I give the values of X and Y) of the BMP image. Experts! Could you please help me how to get this? Thanks! best regards, jackling
    Wednesday, January 5, 2005 9:11 PM

All replies

  • User-1372641848 posted
    Use System.Drawing.Bitmap.GetPixel(int x,int y) which returns System.Drawing.Color object
    Saturday, January 8, 2005 11:00 AM