fixed off by 1 bug in converting premultiplied DIB pixel values to non-premultiplied image ones

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@48581 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2007-09-05 23:01:02 +00:00
parent 0e4341c1ec
commit ececeb6536

View File

@@ -785,9 +785,9 @@ wxImage wxDIB::ConvertToImage() const
*alpha++ = a;
if ( a > 0 )
{
dst[0] = (dst[0] * 255 - 127) / a;
dst[1] = (dst[1] * 255 - 127) / a;
dst[2] = (dst[2] * 255 - 127) / a;
dst[0] = (dst[0] * 255) / a;
dst[1] = (dst[1] * 255) / a;
dst[2] = (dst[2] * 255) / a;
}
}