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
Added patch to ignore unsupported alpha channels in TIFF decoder.
This commit is contained in:
@@ -180,6 +180,7 @@ patch_enable_all ()
|
||||
enable_vcomp_Stub_Functions="$1"
|
||||
enable_version_VersionInfoEx="$1"
|
||||
enable_windowscodecs_TGA_Decoder="$1"
|
||||
enable_windowscodecs_TIFF_Decoder="$1"
|
||||
enable_wine_inf_Performance="$1"
|
||||
enable_wineboot_HKEY_DYN_DATA="$1"
|
||||
enable_winebuild_LinkerVersion="$1"
|
||||
@@ -569,6 +570,9 @@ patch_enable ()
|
||||
windowscodecs-TGA_Decoder)
|
||||
enable_windowscodecs_TGA_Decoder="$2"
|
||||
;;
|
||||
windowscodecs-TIFF_Decoder)
|
||||
enable_windowscodecs_TIFF_Decoder="$2"
|
||||
;;
|
||||
wine.inf-Performance)
|
||||
enable_wine_inf_Performance="$2"
|
||||
;;
|
||||
@@ -3126,6 +3130,21 @@ if test "$enable_windowscodecs_TGA_Decoder" -eq 1; then
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset windowscodecs-TIFF_Decoder
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
# | * [#38027] Ignore unsupported alpha channels in TIFF decoder
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * dlls/windowscodecs/tiffformat.c
|
||||
# |
|
||||
if test "$enable_windowscodecs_TIFF_Decoder" -eq 1; then
|
||||
patch_apply windowscodecs-TIFF_Decoder/0001-windowscodecs-Ignore-unsupported-alpha-channel-in-ti.patch
|
||||
(
|
||||
echo '+ { "Dmitry Timoshkov", "windowscodecs: Ignore unsupported alpha channel in tiff_get_decode_info.", 1 },';
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset wine.inf-Performance
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
|
@@ -0,0 +1,38 @@
|
||||
From 905f0a28d10fa0e67b8c2580d65f9001bc15f92a Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Sat, 21 Feb 2015 11:23:58 +0100
|
||||
Subject: windowscodecs: Ignore unsupported alpha channel in
|
||||
tiff_get_decode_info.
|
||||
|
||||
---
|
||||
dlls/windowscodecs/tiffformat.c | 14 +++++++++++++-
|
||||
1 file changed, 13 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dlls/windowscodecs/tiffformat.c b/dlls/windowscodecs/tiffformat.c
|
||||
index 74a73bc..6302c28 100644
|
||||
--- a/dlls/windowscodecs/tiffformat.c
|
||||
+++ b/dlls/windowscodecs/tiffformat.c
|
||||
@@ -326,7 +326,19 @@ static HRESULT tiff_get_decode_info(TIFF *tiff, tiff_decode_info *decode_info)
|
||||
decode_info->invert_grayscale = 1;
|
||||
/* fall through */
|
||||
case 1: /* BlackIsZero */
|
||||
- if (samples != 1)
|
||||
+ if (samples == 2)
|
||||
+ {
|
||||
+ ret = pTIFFGetField(tiff, TIFFTAG_EXTRASAMPLES, &extra_sample_count, &extra_samples);
|
||||
+ if (!ret)
|
||||
+ {
|
||||
+ extra_sample_count = 1;
|
||||
+ extra_sample = 0;
|
||||
+ extra_samples = &extra_sample;
|
||||
+ }
|
||||
+ else
|
||||
+ FIXME("ignoring extra alpha %u/%u bps %u\n", extra_sample_count, extra_samples[0], bps);
|
||||
+ }
|
||||
+ else if (samples != 1)
|
||||
{
|
||||
FIXME("unhandled grayscale sample count %u\n", samples);
|
||||
return E_FAIL;
|
||||
--
|
||||
2.3.0
|
||||
|
1
patches/windowscodecs-TIFF_Decoder/definition
Normal file
1
patches/windowscodecs-TIFF_Decoder/definition
Normal file
@@ -0,0 +1 @@
|
||||
Fixes: [38027] Ignore unsupported alpha channels in TIFF decoder
|
Reference in New Issue
Block a user