windowscodecs: Add support for 128bppRGBAFloat format to TIFF decoder.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru> Signed-off-by: Vincent Povirk <vincent@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
fa753b5cf2
commit
462c650ea4
|
@ -1236,6 +1236,7 @@ static GUID const * const tiff_decode_formats[] = {
|
|||
&GUID_WICPixelFormat48bppRGB,
|
||||
&GUID_WICPixelFormat64bppRGBA,
|
||||
&GUID_WICPixelFormat64bppPRGBA,
|
||||
&GUID_WICPixelFormat128bppRGBAFloat,
|
||||
NULL
|
||||
};
|
||||
|
||||
|
@ -1766,6 +1767,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 };
|
||||
|
@ -1783,6 +1789,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 };
|
||||
|
@ -2066,6 +2073,17 @@ static struct regsvr_pixelformat const pixelformat_list[] = {
|
|||
WICPixelFormatNumericRepresentationUnsignedInteger,
|
||||
0
|
||||
},
|
||||
{ &GUID_WICPixelFormat128bppRGBAFloat,
|
||||
"The Wine Project",
|
||||
"128bpp RGBAFloat",
|
||||
NULL, /* no version */
|
||||
&GUID_VendorMicrosoft,
|
||||
128, /* bitsperpixel */
|
||||
4, /* channel count */
|
||||
channel_masks_128bit,
|
||||
WICPixelFormatNumericRepresentationFloat,
|
||||
1
|
||||
},
|
||||
{ NULL } /* list terminator */
|
||||
};
|
||||
|
||||
|
|
|
@ -464,9 +464,17 @@ static HRESULT tiff_get_decode_info(TIFF *tiff, tiff_decode_info *decode_info)
|
|||
return E_FAIL;
|
||||
}
|
||||
break;
|
||||
case 32:
|
||||
if (samples != 4)
|
||||
{
|
||||
FIXME("unhandled 32bpp RGB sample count %u\n", samples);
|
||||
return WINCODEC_ERR_UNSUPPORTEDPIXELFORMAT;
|
||||
}
|
||||
decode_info->format = &GUID_WICPixelFormat128bppRGBAFloat;
|
||||
break;
|
||||
default:
|
||||
FIXME("unhandled RGB bit count %u\n", bps);
|
||||
return E_FAIL;
|
||||
WARN("unhandled RGB bit count %u\n", bps);
|
||||
return WINCODEC_ERR_UNSUPPORTEDPIXELFORMAT;
|
||||
}
|
||||
break;
|
||||
case 3: /* RGB Palette */
|
||||
|
|
Loading…
Reference in New Issue