Reputation: 21108
I need to convert all the images in a folder to greyscale (I believe their gif files if that matters). Any suggestions? I have .NET 3.5 (sp1)
Upvotes: 2
Views: 218
Reputation: 137198
There are different approaches:
Average the red, green and blue values. Simple, but the result probably won't look right unless you weight the values first.
Convert the image to Hue, Lightness and Saturation values and take the lightness.
You can read images using the Image
class. There's a method to read the image from file.
Upvotes: 0