diff --git a/patches/windowscodecs-TIFF_Support/0009-windowscodecs-Add-support-for-128bppRGBAFloat-format.patch b/patches/windowscodecs-TIFF_Support/0009-windowscodecs-Add-support-for-128bppRGBAFloat-format.patch index 0bd64579..c83c7561 100644 --- a/patches/windowscodecs-TIFF_Support/0009-windowscodecs-Add-support-for-128bppRGBAFloat-format.patch +++ b/patches/windowscodecs-TIFF_Support/0009-windowscodecs-Add-support-for-128bppRGBAFloat-format.patch @@ -1,17 +1,17 @@ -From badd83bc062034d92c62518210f7a578880c3f96 Mon Sep 17 00:00:00 2001 +From cfee4c0d28ee7eff5992423c826e999bbc07db43 Mon Sep 17 00:00:00 2001 From: Dmitry Timoshkov Date: Fri, 9 Dec 2016 12:46:00 +0800 Subject: windowscodecs: Add support for 128bppRGBAFloat format to TIFF decoder. --- - dlls/windowscodecs/regsvr.c | 12 ++++++++++++ + dlls/windowscodecs/regsvr.c | 18 ++++++++++++++++++ dlls/windowscodecs/tiffformat.c | 12 ++++++++++-- include/wincodec.idl | 2 ++ - 3 files changed, 24 insertions(+), 2 deletions(-) + 3 files changed, 30 insertions(+), 2 deletions(-) diff --git a/dlls/windowscodecs/regsvr.c b/dlls/windowscodecs/regsvr.c -index d1649fa..2d6a5d2 100644 +index d1649fa955..f695d3e40a 100644 --- a/dlls/windowscodecs/regsvr.c +++ b/dlls/windowscodecs/regsvr.c @@ -1224,6 +1224,7 @@ static GUID const * const tiff_decode_formats[] = { @@ -22,7 +22,27 @@ index d1649fa..2d6a5d2 100644 NULL }; -@@ -2019,6 +2020,17 @@ static struct regsvr_pixelformat const pixelformat_list[] = { +@@ -1752,6 +1753,11 @@ static BYTE const channel_mask_16bit4[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + + static BYTE const channel_mask_32bit[] = { 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00 }; + ++static BYTE const channel_mask_128bit1[] = { 0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }; ++static BYTE const channel_mask_128bit2[] = { 0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }; ++static BYTE const channel_mask_128bit3[] = { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00 }; ++static BYTE const channel_mask_128bit4[] = { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff }; ++ + static BYTE const channel_mask_5bit[] = { 0x1f, 0x00 }; + static BYTE const channel_mask_5bit2[] = { 0xe0, 0x03 }; + static BYTE const channel_mask_5bit3[] = { 0x00, 0x7c }; +@@ -1769,6 +1775,7 @@ 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_128bit[] = { channel_mask_128bit1, channel_mask_128bit2, channel_mask_128bit3, channel_mask_128bit4 }; + + static BYTE const * const channel_masks_BGRA5551[] = { channel_mask_5bit, + channel_mask_5bit2, channel_mask_5bit3, channel_mask_5bit4 }; +@@ -2019,6 +2026,17 @@ static struct regsvr_pixelformat const pixelformat_list[] = { WICPixelFormatNumericRepresentationUnsignedInteger, 0 }, @@ -33,15 +53,15 @@ index d1649fa..2d6a5d2 100644 + &GUID_VendorMicrosoft, + 128, /* bitsperpixel */ + 4, /* channel count */ -+ channel_masks_32bit, -+ WICPixelFormatNumericRepresentationUnsignedInteger, ++ channel_masks_128bit, ++ WICPixelFormatNumericRepresentationFloat, + 1 + }, { NULL } /* list terminator */ }; diff --git a/dlls/windowscodecs/tiffformat.c b/dlls/windowscodecs/tiffformat.c -index f17e508..48e46d6 100644 +index f17e508b53..48e46d69db 100644 --- a/dlls/windowscodecs/tiffformat.c +++ b/dlls/windowscodecs/tiffformat.c @@ -466,9 +466,17 @@ static HRESULT tiff_get_decode_info(TIFF *tiff, tiff_decode_info *decode_info) @@ -65,10 +85,10 @@ index f17e508..48e46d6 100644 break; case 3: /* RGB Palette */ diff --git a/include/wincodec.idl b/include/wincodec.idl -index c0afe52..e8c7023 100644 +index 406fe6b411..dfcb9bce2e 100644 --- a/include/wincodec.idl +++ b/include/wincodec.idl -@@ -219,6 +219,8 @@ cpp_quote("DEFINE_GUID(GUID_WICPixelFormat48bppRGB, 0x6fddc324,0x4e03,0x4bfe,0xb +@@ -213,6 +213,8 @@ cpp_quote("DEFINE_GUID(GUID_WICPixelFormat48bppRGB, 0x6fddc324,0x4e03,0x4bfe,0xb cpp_quote("DEFINE_GUID(GUID_WICPixelFormat64bppRGBA, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x16);") cpp_quote("DEFINE_GUID(GUID_WICPixelFormat64bppPRGBA, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x17);") @@ -78,5 +98,5 @@ index c0afe52..e8c7023 100644 typedef struct WICRect { -- -2.9.0 +2.12.2 diff --git a/patches/windowscodecs-TIFF_Support/0011-windowscodecs-Add-support-for-32bppCMYK-and-64bppCMY.patch b/patches/windowscodecs-TIFF_Support/0011-windowscodecs-Add-support-for-32bppCMYK-and-64bppCMY.patch index c0f1e93c..09628816 100644 --- a/patches/windowscodecs-TIFF_Support/0011-windowscodecs-Add-support-for-32bppCMYK-and-64bppCMY.patch +++ b/patches/windowscodecs-TIFF_Support/0011-windowscodecs-Add-support-for-32bppCMYK-and-64bppCMY.patch @@ -34,7 +34,7 @@ index 2d6a5d2..b5bbff3 100644 + &GUID_VendorMicrosoft, + 64, /* bitsperpixel */ + 4, /* channel count */ -+ channel_masks_8bit, ++ channel_masks_16bit, + WICPixelFormatNumericRepresentationUnsignedInteger, + 0 + },