gdiplus: Fix palette flags for a not indexed 1-bpp image.
This commit is contained in:
parent
eca107412c
commit
ebf31c0ac6
@ -2983,6 +2983,7 @@ static GpStatus decode_image_wic(IStream* stream, REFCLSID clsid, UINT active_fr
|
|||||||
gdip_format = PixelFormat32bppARGB;
|
gdip_format = PixelFormat32bppARGB;
|
||||||
IWICBitmapSource_Release(bmp_source);
|
IWICBitmapSource_Release(bmp_source);
|
||||||
}
|
}
|
||||||
|
TRACE("%s => %#x\n", wine_dbgstr_guid(&wic_format), gdip_format);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (SUCCEEDED(hr)) /* got source */
|
if (SUCCEEDED(hr)) /* got source */
|
||||||
@ -3063,6 +3064,8 @@ end:
|
|||||||
bitmap->image.frame_count = frame_count;
|
bitmap->image.frame_count = frame_count;
|
||||||
bitmap->image.current_frame = active_frame;
|
bitmap->image.current_frame = active_frame;
|
||||||
bitmap->image.stream = stream;
|
bitmap->image.stream = stream;
|
||||||
|
if (IsEqualGUID(&wic_format, &GUID_WICPixelFormatBlackWhite))
|
||||||
|
bitmap->image.palette_flags = 0;
|
||||||
/* Pin the source stream */
|
/* Pin the source stream */
|
||||||
IStream_AddRef(stream);
|
IStream_AddRef(stream);
|
||||||
}
|
}
|
||||||
|
@ -3340,7 +3340,6 @@ static void test_tiff_palette(void)
|
|||||||
|
|
||||||
status = GdipGetImagePalette(image, &palette.pal, size);
|
status = GdipGetImagePalette(image, &palette.pal, size);
|
||||||
expect(Ok, status);
|
expect(Ok, status);
|
||||||
todo_wine
|
|
||||||
expect(0, palette.pal.Flags);
|
expect(0, palette.pal.Flags);
|
||||||
expect(2, palette.pal.Count);
|
expect(2, palette.pal.Count);
|
||||||
if (palette.pal.Count == 2)
|
if (palette.pal.Count == 2)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user