cropping image in c#

code snippet :


           Image img = Image.FromFile("c:\\hello.jpg");
           Bitmap bmpImage = new Bitmap(img);
           Bitmap bmpCrop = bmpImage.Clone(new Rectangle(100, 100, 300, 300), bmpImage.
           PixelFormat);

             bmpCrop.Save("c:\\hellocrop.jpg");
Ebook Download
View all
Learn
View all