I have an Image object, img, and i need to save it into a memory stream.
Save method has this signature:
Image.Save (Stream, ImageCodecInfo, EncoderParameters)
but i don’t know what i shoud provide in parameters 2 and 3.
I workaround problem using BinaryFormmater serialization, but i would like use the most appropriate method.
Thank you for any help!
There is a simpler overload:
Image.Save(Stream, ImageFormat). The second parameter lets you pick the format you want to save the image on, like BMP, PNG, or JPEG.