How Simple is That?

So how simple can you get?

Let's take a Photoshop file. Resize it so it fits within a 200 pixel square, put a frame round it and then save it out as a CMYK progressive JPEG.

using (Image image = Bitmap.FromFile(@"c:\photoshop.psd")) {
	double scale = 200.0 / image.Width;
	Size size = (image.Size * scale) + new Size(2, 2);
	using (Bitmap bm = new Bitmap(size)) {
		using (Graphics graphics = Graphics.FromImage(bm)) {
			graphics.FillRectangle(Brushes.Black, bm.Bounds);
			graphics.DrawImage(image, 1, 1, bm.Width - 2, bm.Height - 2);
		}
		bm.PixelFormat = PixelFormat.ImageGlueCmyk8;
		EncoderParameters pars = new EncoderParameters() { Quality = 75, Progressive = true,  };
		bm.Save(@"c:\cmyk.jpg", ImageFormat.Jpeg, pars);
	}
}

This looks remarkably similar to System.Drawing but it's working with Photoshop files and CMYK progressive JPEGs. We take a coding style you are familiar with and extend it to add new features and capabilities.

For the purposes of this example we used a Photoshop file. However we could have used a PDF, an EPS, a Flash Movie or indeed any of the numerous file formats supported by ImageGlue.

There are many more examples of how to use ImageGlue included with the software. Download Software...