我从之前的程序得到一个Bitmap型的 bitmap现在要按比例缩小该图,例如比例为int intZoom = 50;所以bitmap的新width应该 等于 原来width * 50 / 100
bitmap的新height应该 等于 原来height * 50 / 100不知道怎样用程序实现高手帮忙啊~~~~~~~~~~
bitmap的新height应该 等于 原来height * 50 / 100不知道怎样用程序实现高手帮忙啊~~~~~~~~~~
解决方案 »
- C#不启动Excel进程的情况下操作Excel
- NND win7 vs2010 死活装不上。。。
- c#怎么调用资源文件中的txt文件,以载入到RichTextBox中
- datagridview记忆功能??
- 如何判断Numericupdown的输入框为空?
- 关于多线程的问题
- c#访问多维数据集
- 50台机器,分布在两个楼层的8个办公室里,怎么样建局域网最经济
- form2控制form1的控件?
- 【求助】webbrowser模拟多个按钮操作太快,无法等到网页响应以至于报错
- 怎么样在form的toolbar里面添加类似word里面的缩放的那个下拉框啊?
- 取得0001到1000中间所有字符串的问题,请高手提供快速度算法!
http://www.36588.com.cn/digital/article/article_22897_1.html
{
image img = img... //获得img ,
Graphics g= Graphics FromImage(
img
);/ Create a matrix and scale it.
Matrix myMatrix = new Matrix();
myMatrix.Scale( 0.5, 0.5, MatrixOrder.Append);
// Draw the rectangle to the screen again after applying the
// transform.
g.Transform = myMatrix;
}
http://www.codeproject.com/cs/media/Image_Processing_Lab.asp