C# Bitmap 缩放拉伸

来源:互联网 发布:淘宝领奖是真是假 编辑:程序博客网 时间:2024/05/16 15:23

对Bitmap对象的一些缩放拉伸的方法

1.Bitmap map = new (image, width, height);2.using(Griphics gra = Griphics.FromImage(map)){    gra.DrawImage(BitmapScreen,                    new Rectangle(_drawingRect.X, _drawingRect.Y, _drawingRect.Width, _drawingRect.Height),                    new Rectangle(0, 0, BitmapScreen.Width, BitmapScreen.Height),                    GraphicsUnit.Pixel);}