您的位置:首页 > 其它

一个简单方法实现bmp背景透明

2007-11-27 17:32 573 查看
看看是不是很简单?

void MakeBackgroundTransparent(Bitmap img)
{
Color pixel = img.GetPixel(0, img.Height - 1);
img.MakeTransparent();
Color color = Color.FromArgb(0, pixel);
img.SetPixel(0, img.Height - 1, color);
}

如果你有更好的方法,请不吝赐教!
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: