Quantize using an Octree
Inheritance: Quantizer
Exemplo n.º 1
0
        // Save a GIF, using OctTree pallettee.
        public static void SaveGif(Bitmap bitmap, string fileName)
        {
            OctreeQuantizer quantizer = new OctreeQuantizer(255, 8);

            using (Bitmap quantized = quantizer.Quantize(bitmap)) {
                quantized.Save(fileName, ImageFormat.Gif);
                quantized.Dispose();
            }
        }
Exemplo n.º 2
0
        // Save a GIF, using OctTree pallettee.
        public static void SaveGif(Bitmap bitmap, string fileName)
        {
            OctreeQuantizer quantizer = new OctreeQuantizer(255, 8);

            using (Bitmap quantized = quantizer.Quantize(bitmap)) {
                quantized.Save(fileName, ImageFormat.Gif);
                quantized.Dispose();
            }
        }