【发布时间】:2010-02-24 19:48:44
【问题描述】:
Bitmap bmp(100,100, PixelFormat32bppARGB);
bmp.SetPixel(2,2,Gdiplus::Color::AliceBlue);
int x = bmp.GetHeight();
int y = bmp.GetWidth();
Gdiplus::Color* ccc = new Gdiplus::Color;
Gdiplus::Color* ccc2 = new Gdiplus::Color;
bmp.GetPixel(2,2,ccc);
bmp.GetPixel(0,0,ccc2);
在过去的示例代码中,位图属性总是显示为空。高度和宽度始终为零,任何像素的颜色始终相同。修改位图属性的正确方法是什么?
【问题讨论】: