색 변환을 수행 할 비트 맵이 있습니다. 나는 픽셀의 새로운 배열을 가지고 있지만 나는 그 이미지비트 맵 픽셀 배열을 새 비트 맵으로 저장
public static void TestProcessBitmap(string inputFile, string outputFile)
{
Bitmap bitmap = new Bitmap(inputFile);
Bitmap formatted = bitmap.Clone(new Rectangle(0, 0, bitmap.Width, bitmap.Height), System.Drawing.Imaging.PixelFormat.Format8bppIndexed);
byte[] pixels = BitmapToPixelArray(formatted);
pixels = Process8Bits(pixels, System.Windows.Media.Colors.Red);
Bitmap output = new Bitmap(pixels); //something like this
}
으로 디스크에 다시 저장하는 방법을 잘 모르겠어요 어떻게 다음 디스크에 비트 맵으로 새 픽셀을 저장할 수 있습니까?
비트 맵을 적절히 처리해야합니다. http://stackoverflow.com/questions/5838608/net-and-bitmap-not-automatically-disposed-by-gc-when-there-is-no-memory-left – geedubb