在 Bitmap bmpUnion = new Bitmap(iWidth, iHeight, PixelFormat.Format24bppRgb)时报“参数错误”,当然想想也是图片的宽高超过了限制了。
请问:Bitmap的最大尺寸是多少?
有一个有意思的:
Bitmap bmpUnion0 = new Bitmap(w0, h0, PixelFormat.Format24bppRgb);
Bitmap bmpUnion1 = new Bitmap(w1, h1, PixelFormat.Format24bppRgb);
Bitmap bmpUnion2 = new Bitmap(w2, h3, PixelFormat.Format24bppRgb);
此处的 w2=w-w0,h2=h-h0,恰好此处的,w0=w2;h0=h2,但是第一句没问题,第二句报“参数错误”
牛人请帮俺解释解释这呗。这Bitmap到底是啥?到底才不会有错发表有用回复,都有分。
请问:Bitmap的最大尺寸是多少?
有一个有意思的:
Bitmap bmpUnion0 = new Bitmap(w0, h0, PixelFormat.Format24bppRgb);
Bitmap bmpUnion1 = new Bitmap(w1, h1, PixelFormat.Format24bppRgb);
Bitmap bmpUnion2 = new Bitmap(w2, h3, PixelFormat.Format24bppRgb);
此处的 w2=w-w0,h2=h-h0,恰好此处的,w0=w2;h0=h2,但是第一句没问题,第二句报“参数错误”
牛人请帮俺解释解释这呗。这Bitmap到底是啥?到底才不会有错发表有用回复,都有分。
解决方案 »
- 求助XML排版遇到的问题
- CuteEditor不可用,怎么办?在Page_Load里response.write后就可以用了,不知为什么?
- 如何调用外部exe
- WPF 实时视频 控件句柄等相关问题
- C#在windows2000下非常诡异的saveFileDialog 问题,高手乱入
- 奇怪!! debug版本没有任何问题, release版本却出错: 未将对象引用设置到对象的实例
- [讨论]图形绘制和格式
- 请问高手线程中如何打开一个Form?
- dataGridView 右侧滚动条无法滚动?请大家帮忙 就这些分了!
- 当前线程不在单线程单元中,因此无法实例化 ActiveX 控件
- 控件大小不够用,如何解决
- 存储过程
是否是h3要改成h2
Bitmap bmpUnion2 = new Bitmap(w2, h2, PixelFormat.Format24bppRgb);
w,h是一个随便给定的宽和高。恩,内存问题我注意到了,我再具体探索一下。
呵呵,赋值的我没给出来。错误好像是随机的。
不过,感谢,“Bitmap的最大尺寸由色深和内存限制共同决定”,很有用