110,538
社区成员
发帖
与我相关
我的任务
分享
pictureBox.AutoSize = true;
//图片载入后
float zoom = (float)this.pictureBox.Width / Image.Width;
//clipBounds为鼠标画的区域,等比例缩放
g.DrawImage(原图,
新图,
clipBounds.Left * zoom
clipBounds.Top * zoom
clipBounds.Width * zoom
clipBounds.Height * zoom
GraphicsUnit.Pixel);