mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-31 12:19:49 +00:00
gdiplus: Round up when converting from 32-bit ARGB to PARGB.
This commit is contained in:
parent
ada3aea736
commit
d23bfd8dfc
2 changed files with 3 additions and 4 deletions
|
@ -442,9 +442,9 @@ void convert_32bppARGB_to_32bppPARGB(UINT width, UINT height,
|
|||
for (x=0; x<width; x++)
|
||||
{
|
||||
BYTE alpha=src[3];
|
||||
*dst++ = *src++ * alpha / 255;
|
||||
*dst++ = *src++ * alpha / 255;
|
||||
*dst++ = *src++ * alpha / 255;
|
||||
*dst++ = (*src++ * alpha + 127) / 255;
|
||||
*dst++ = (*src++ * alpha + 127) / 255;
|
||||
*dst++ = (*src++ * alpha + 127) / 255;
|
||||
*dst++ = *src++;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4129,7 +4129,6 @@ static void test_ARGB_conversion(void)
|
|||
ok(data.Stride == 8, "expected 8, got %d\n", data.Stride);
|
||||
ok(data.PixelFormat == PixelFormat32bppPARGB, "expected PixelFormat32bppPARGB, got %d\n", data.PixelFormat);
|
||||
match = !memcmp(data.Scan0, pargb, sizeof(pargb));
|
||||
todo_wine
|
||||
ok(match, "bits don't match\n");
|
||||
if (!match)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue