You've already forked wine-staging
mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-09-12 18:50:20 -07:00
Rebase against ae5e029d2227b3a8024f597591f76fe0f37d52e3.
This commit is contained in:
@@ -1,53 +0,0 @@
|
||||
From 6d21d949439cb6e519029aee6bc55693f4cafc6c Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Thu, 20 Oct 2016 19:02:39 +0800
|
||||
Subject: windowscodecs: Add registration for GUID_WICPixelFormat32bppGrayFloat
|
||||
pixel format.
|
||||
|
||||
---
|
||||
dlls/windowscodecs/regsvr.c | 15 +++++++++++++++
|
||||
1 file changed, 15 insertions(+)
|
||||
|
||||
diff --git a/dlls/windowscodecs/regsvr.c b/dlls/windowscodecs/regsvr.c
|
||||
index 74637f5..4516d3f 100644
|
||||
--- a/dlls/windowscodecs/regsvr.c
|
||||
+++ b/dlls/windowscodecs/regsvr.c
|
||||
@@ -1748,6 +1748,8 @@ static BYTE const channel_mask_16bit2[] = { 0x00, 0x00, 0xff, 0xff, 0x00, 0x00,
|
||||
static BYTE const channel_mask_16bit3[] = { 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00 };
|
||||
static BYTE const channel_mask_16bit4[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff };
|
||||
|
||||
+static BYTE const channel_mask_32bit[] = { 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00 };
|
||||
+
|
||||
static BYTE const channel_mask_5bit[] = { 0x1f, 0x00 };
|
||||
static BYTE const channel_mask_5bit2[] = { 0xe0, 0x03 };
|
||||
static BYTE const channel_mask_5bit3[] = { 0x00, 0x7c };
|
||||
@@ -1764,6 +1766,8 @@ static BYTE const * const channel_masks_8bit[] = { channel_mask_8bit,
|
||||
static BYTE const * const channel_masks_16bit[] = { channel_mask_16bit,
|
||||
channel_mask_16bit2, channel_mask_16bit3, channel_mask_16bit4};
|
||||
|
||||
+static BYTE const * const channel_masks_32bit[] = { channel_mask_32bit };
|
||||
+
|
||||
static BYTE const * const channel_masks_BGRA5551[] = { channel_mask_5bit,
|
||||
channel_mask_5bit2, channel_mask_5bit3, channel_mask_5bit4 };
|
||||
|
||||
@@ -1958,6 +1962,17 @@ static struct regsvr_pixelformat const pixelformat_list[] = {
|
||||
WICPixelFormatNumericRepresentationUnsignedInteger,
|
||||
1
|
||||
},
|
||||
+ { &GUID_WICPixelFormat32bppGrayFloat,
|
||||
+ "The Wine Project",
|
||||
+ "32bpp GrayFloat",
|
||||
+ NULL, /* no version */
|
||||
+ &GUID_VendorMicrosoft,
|
||||
+ 32, /* bitsperpixel */
|
||||
+ 1, /* channel count */
|
||||
+ channel_masks_32bit,
|
||||
+ WICPixelFormatNumericRepresentationFloat,
|
||||
+ 1
|
||||
+ },
|
||||
{ &GUID_WICPixelFormat48bppRGB,
|
||||
"The Wine Project",
|
||||
"48bpp RGB",
|
||||
--
|
||||
2.9.0
|
||||
|
@@ -1,32 +0,0 @@
|
||||
From 2297b261c195840bcff9a3db40b25fcaaa747a7b Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Thu, 20 Oct 2016 16:49:08 +0800
|
||||
Subject: windowscodecs: Implement IWICBitmapDecoder::GetMetadataQueryReader in
|
||||
the TIFF decoder.
|
||||
|
||||
---
|
||||
dlls/windowscodecs/tiffformat.c | 8 ++++++--
|
||||
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dlls/windowscodecs/tiffformat.c b/dlls/windowscodecs/tiffformat.c
|
||||
index 037277b..19aa5d5 100644
|
||||
--- a/dlls/windowscodecs/tiffformat.c
|
||||
+++ b/dlls/windowscodecs/tiffformat.c
|
||||
@@ -699,8 +699,12 @@ static HRESULT WINAPI TiffDecoder_CopyPalette(IWICBitmapDecoder *iface,
|
||||
static HRESULT WINAPI TiffDecoder_GetMetadataQueryReader(IWICBitmapDecoder *iface,
|
||||
IWICMetadataQueryReader **ppIMetadataQueryReader)
|
||||
{
|
||||
- FIXME("(%p,%p): stub\n", iface, ppIMetadataQueryReader);
|
||||
- return E_NOTIMPL;
|
||||
+ TRACE("(%p,%p)\n", iface, ppIMetadataQueryReader);
|
||||
+
|
||||
+ if (!ppIMetadataQueryReader) return E_INVALIDARG;
|
||||
+
|
||||
+ *ppIMetadataQueryReader = NULL;
|
||||
+ return WINCODEC_ERR_UNSUPPORTEDOPERATION;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI TiffDecoder_GetPreview(IWICBitmapDecoder *iface,
|
||||
--
|
||||
2.9.0
|
||||
|
@@ -1,35 +0,0 @@
|
||||
From 3204ee4de19693fd9e451a62216b68fe51ea2ca5 Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Fri, 21 Oct 2016 14:38:43 +0800
|
||||
Subject: windowscodecs: Improve stub for
|
||||
IWICBitmapDecoder::GetMetadataQueryReader in the PNG decoder.
|
||||
|
||||
---
|
||||
dlls/windowscodecs/pngformat.c | 10 +++++++---
|
||||
1 file changed, 7 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/dlls/windowscodecs/pngformat.c b/dlls/windowscodecs/pngformat.c
|
||||
index 94253d3..41d9099 100644
|
||||
--- a/dlls/windowscodecs/pngformat.c
|
||||
+++ b/dlls/windowscodecs/pngformat.c
|
||||
@@ -853,10 +853,14 @@ static HRESULT WINAPI PngDecoder_CopyPalette(IWICBitmapDecoder *iface,
|
||||
}
|
||||
|
||||
static HRESULT WINAPI PngDecoder_GetMetadataQueryReader(IWICBitmapDecoder *iface,
|
||||
- IWICMetadataQueryReader **ppIMetadataQueryReader)
|
||||
+ IWICMetadataQueryReader **reader)
|
||||
{
|
||||
- FIXME("(%p,%p): stub\n", iface, ppIMetadataQueryReader);
|
||||
- return E_NOTIMPL;
|
||||
+ FIXME("(%p,%p): stub\n", iface, reader);
|
||||
+
|
||||
+ if (!reader) return E_INVALIDARG;
|
||||
+
|
||||
+ *reader = NULL;
|
||||
+ return WINCODEC_ERR_UNSUPPORTEDOPERATION;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI PngDecoder_GetPreview(IWICBitmapDecoder *iface,
|
||||
--
|
||||
2.9.0
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -1,18 +1,18 @@
|
||||
From d9cd3ba23fa27fcffbe3d5dff9754c0520b3f92e Mon Sep 17 00:00:00 2001
|
||||
From 59176c773e3e710418c79641ca3c11d81ce98849 Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Thu, 27 Oct 2016 15:17:19 +0800
|
||||
Subject: [PATCH] windowscodecs/tests: Add the tests for GIF encoder and
|
||||
decoder.
|
||||
|
||||
---
|
||||
dlls/windowscodecs/tests/converter.c | 59 +++++++++++++++++++++++++++++++++---
|
||||
dlls/windowscodecs/tests/converter.c | 59 +++++++++++++++++++++++++---
|
||||
1 file changed, 54 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/dlls/windowscodecs/tests/converter.c b/dlls/windowscodecs/tests/converter.c
|
||||
index 089926b..5480584 100644
|
||||
index 7d956a69..09125603 100644
|
||||
--- a/dlls/windowscodecs/tests/converter.c
|
||||
+++ b/dlls/windowscodecs/tests/converter.c
|
||||
@@ -956,6 +956,40 @@ static void check_png_format(IStream *stream, const WICPixelFormatGUID *format)
|
||||
@@ -1071,6 +1071,40 @@ static void check_png_format(IStream *stream, const WICPixelFormatGUID *format)
|
||||
ok(0, "unknown PNG pixel format %s\n", wine_dbgstr_guid(format));
|
||||
}
|
||||
|
||||
@@ -53,7 +53,7 @@ index 089926b..5480584 100644
|
||||
static void check_bitmap_format(IStream *stream, const CLSID *encoder, const WICPixelFormatGUID *format)
|
||||
{
|
||||
HRESULT hr;
|
||||
@@ -971,6 +1005,8 @@ static void check_bitmap_format(IStream *stream, const CLSID *encoder, const WIC
|
||||
@@ -1086,6 +1120,8 @@ static void check_bitmap_format(IStream *stream, const CLSID *encoder, const WIC
|
||||
check_bmp_format(stream, format);
|
||||
else if (IsEqualGUID(encoder, &CLSID_WICTiffEncoder))
|
||||
check_tiff_format(stream, format);
|
||||
@@ -62,7 +62,7 @@ index 089926b..5480584 100644
|
||||
else
|
||||
ok(0, "unknown encoder %s\n", wine_dbgstr_guid(encoder));
|
||||
|
||||
@@ -1089,7 +1125,7 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
@@ -1204,7 +1240,7 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
|
||||
hr = CoCreateInstance(clsid_encoder, NULL, CLSCTX_INPROC_SERVER,
|
||||
&IID_IWICBitmapEncoder, (void**)&encoder);
|
||||
@@ -71,7 +71,7 @@ index 089926b..5480584 100644
|
||||
if (SUCCEEDED(hr))
|
||||
{
|
||||
hglobal = GlobalAlloc(GMEM_MOVEABLE, 0);
|
||||
@@ -1116,7 +1152,10 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
@@ -1231,7 +1267,10 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
if (palette)
|
||||
{
|
||||
hr = IWICBitmapEncoder_SetPalette(encoder, palette);
|
||||
@@ -83,7 +83,7 @@ index 089926b..5480584 100644
|
||||
hr = S_OK;
|
||||
}
|
||||
|
||||
@@ -1268,13 +1307,19 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
@@ -1384,13 +1423,19 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
ok(hr == S_OK, "CreatePalette error %#x\n", hr);
|
||||
|
||||
hr = IWICBitmapDecoder_CopyPalette(decoder, frame_palette);
|
||||
@@ -105,7 +105,7 @@ index 089926b..5480584 100644
|
||||
|
||||
hr = S_OK;
|
||||
i=0;
|
||||
@@ -1331,7 +1376,8 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
@@ -1449,7 +1494,8 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
}
|
||||
}
|
||||
else if (IsEqualGUID(clsid_decoder, &CLSID_WICBmpDecoder) ||
|
||||
@@ -113,9 +113,9 @@ index 089926b..5480584 100644
|
||||
+ IsEqualGUID(clsid_decoder, &CLSID_WICTiffDecoder) ||
|
||||
+ IsEqualGUID(clsid_decoder, &CLSID_WICGifDecoder))
|
||||
{
|
||||
if (IsEqualGUID(dsts[i]->format, &GUID_WICPixelFormatBlackWhite) ||
|
||||
IsEqualGUID(dsts[i]->format, &GUID_WICPixelFormat8bppIndexed))
|
||||
@@ -1661,6 +1707,9 @@ START_TEST(converter)
|
||||
if (IsEqualGUID(&pixelformat, &GUID_WICPixelFormatBlackWhite) ||
|
||||
IsEqualGUID(&pixelformat, &GUID_WICPixelFormat8bppIndexed))
|
||||
@@ -1789,6 +1835,9 @@ START_TEST(converter)
|
||||
test_default_converter();
|
||||
test_converter_8bppIndexed();
|
||||
|
||||
@@ -126,5 +126,5 @@ index 089926b..5480584 100644
|
||||
&testdata_BlackWhite, &CLSID_WICPngDecoder, "PNG encoder BlackWhite");
|
||||
test_encoder(&testdata_1bppIndexed, &CLSID_WICPngEncoder,
|
||||
--
|
||||
1.9.1
|
||||
2.19.1
|
||||
|
||||
|
@@ -0,0 +1,25 @@
|
||||
From 18eb6add9eac40d84a809d75d340600e44cc1dae Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Sun, 6 Nov 2016 16:25:12 +0800
|
||||
Subject: windowscodecs/tests: Add a missing check for
|
||||
IWICBitmapFrameDecode::GetPixelFormat return value.
|
||||
|
||||
---
|
||||
dlls/windowscodecs/tests/converter.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/dlls/windowscodecs/tests/converter.c b/dlls/windowscodecs/tests/converter.c
|
||||
index 430c0ed..6d782f3 100644
|
||||
--- a/dlls/windowscodecs/tests/converter.c
|
||||
+++ b/dlls/windowscodecs/tests/converter.c
|
||||
@@ -1311,6 +1311,7 @@ static void test_multi_encoder(const struct bitmap_data **srcs, const CLSID* cls
|
||||
if (SUCCEEDED(hr))
|
||||
{
|
||||
hr = IWICBitmapFrameDecode_GetPixelFormat(framedecode, &pixelformat);
|
||||
+ ok(hr == S_OK, "GetPixelFormat) failed, hr=%x (%s)\n", hr, name);
|
||||
if (IsEqualGUID(&pixelformat, dsts[i]->format))
|
||||
compare_bitmap_data(srcs[i], dsts[i], (IWICBitmapSource*)framedecode, name);
|
||||
|
||||
--
|
||||
2.9.0
|
||||
|
Reference in New Issue
Block a user