winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
February 2019
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
1 participants
672 discussions
Start a n
N
ew thread
Michael Stefaniuc : shell32: Remove superfluous continue (coccinellery).
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: fd853c5e78c9be51d8ab500bc450c24059f6f08d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=fd853c5e78c9be51d8ab500b…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Wed Feb 20 20:54:23 2019 +0100 shell32: Remove superfluous continue (coccinellery). Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shell32/xdg.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/dlls/shell32/xdg.c b/dlls/shell32/xdg.c index 781902a..0351699 100644 --- a/dlls/shell32/xdg.c +++ b/dlls/shell32/xdg.c @@ -939,14 +939,10 @@ HRESULT XDG_UserDirLookup(const char * const *xdg_dirs, const unsigned int num_d /* Parse the value */ hr = parse_config2(p, home_dir, &out[idx]); - if (FAILED(hr)) + if (hr == E_OUTOFMEMORY) { - if (hr == E_OUTOFMEMORY) - { - fclose(file); - goto xdg_user_dir_lookup_error; - } - continue; + fclose(file); + goto xdg_user_dir_lookup_error; } } fclose (file);
1
0
0
0
Matteo Bruni : d3dx9: Simplify get_parameter_by_name().
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: 4a9fe7a8a092095420532ae734ebce9978b1e608 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=4a9fe7a8a092095420532ae7…
Author: Matteo Bruni <mbruni(a)codeweavers.com> Date: Wed Feb 20 16:58:33 2019 +0100 d3dx9: Simplify get_parameter_by_name(). Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dx9_36/effect.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/dlls/d3dx9_36/effect.c b/dlls/d3dx9_36/effect.c index 1abc8dc..b0dc366 100644 --- a/dlls/d3dx9_36/effect.c +++ b/dlls/d3dx9_36/effect.c @@ -918,7 +918,6 @@ struct d3dx_parameter *get_parameter_by_name(struct d3dx9_base_effect *base, return NULL; } - /* Pass / technique annotations are not in the parameters tree. */ if (parameter->full_name) { name_len = strlen(name); @@ -948,9 +947,11 @@ struct d3dx_parameter *get_parameter_by_name(struct d3dx9_base_effect *base, return NULL; } + /* Pass / technique annotations are not stored in the parameters tree, + * do a linear search. */ count = parameter->member_count; - length = strcspn( name, "[.@" ); + length = strcspn( name, "[." ); part = name + length; for (i = 0; i < count; i++) @@ -969,9 +970,6 @@ struct d3dx_parameter *get_parameter_by_name(struct d3dx9_base_effect *base, case '.': return get_parameter_by_name(base, temp_parameter, part); - case '@': - return NULL; - case '[': return get_parameter_element_by_name(base, temp_parameter, part);
1
0
0
0
Michael Stefaniuc : d3dx9/tests: Avoid using the comma operator ( coccinellery).
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: eb0eaf7027797c6a99b4b5ecdb70c5ba336dccc2 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=eb0eaf7027797c6a99b4b5ec…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Tue Feb 19 20:27:34 2019 +0100 d3dx9/tests: Avoid using the comma operator (coccinellery). Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dx9_36/tests/math.c | 114 ++++++++++++++++++++++----------------------- dlls/d3dx9_36/tests/mesh.c | 2 +- 2 files changed, 58 insertions(+), 58 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=eb0eaf7027797c6a99b4…
1
0
0
0
Dmitry Timoshkov : windowscodecs: Avoid redundant checks when reading a TIFF tile.
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: 493fbabb855645e00c304cccaf1dfca764fa5305 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=493fbabb855645e00c304ccc…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Tue Feb 19 12:07:58 2019 +0800 windowscodecs: Avoid redundant checks when reading a TIFF tile. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Vincent Povirk <vincent(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/windowscodecs/tiffformat.c | 40 ++++++++++++++-------------------------- 1 file changed, 14 insertions(+), 26 deletions(-) diff --git a/dlls/windowscodecs/tiffformat.c b/dlls/windowscodecs/tiffformat.c index 3bc8d69..295330a 100644 --- a/dlls/windowscodecs/tiffformat.c +++ b/dlls/windowscodecs/tiffformat.c @@ -974,34 +974,25 @@ static HRESULT WINAPI TiffFrameDecode_CopyPalette(IWICBitmapFrameDecode *iface, static HRESULT TiffFrameDecode_ReadTile(TiffFrameDecode *This, UINT tile_x, UINT tile_y) { - HRESULT hr=S_OK; tsize_t ret; int swap_bytes; swap_bytes = pTIFFIsByteSwapped(This->parent->tiff); ret = pTIFFSetDirectory(This->parent->tiff, This->index); - if (ret == -1) - hr = E_FAIL; + return E_FAIL; - if (hr == S_OK) - { - if (This->decode_info.tiled) - { - ret = pTIFFReadEncodedTile(This->parent->tiff, tile_x + tile_y * This->decode_info.tiles_across, This->cached_tile, This->decode_info.tile_size); - } - else - { - ret = pTIFFReadEncodedStrip(This->parent->tiff, tile_y, This->cached_tile, This->decode_info.tile_size); - } + if (This->decode_info.tiled) + ret = pTIFFReadEncodedTile(This->parent->tiff, tile_x + tile_y * This->decode_info.tiles_across, This->cached_tile, This->decode_info.tile_size); + else + ret = pTIFFReadEncodedStrip(This->parent->tiff, tile_y, This->cached_tile, This->decode_info.tile_size); - if (ret == -1) - hr = E_FAIL; - } + if (ret == -1) + return E_FAIL; /* 8bpp grayscale with extra alpha */ - if (hr == S_OK && This->decode_info.source_bpp == 16 && This->decode_info.samples == 2 && This->decode_info.bpp == 32) + if (This->decode_info.source_bpp == 16 && This->decode_info.samples == 2 && This->decode_info.bpp == 32) { BYTE *src; DWORD *dst, count = This->decode_info.tile_width * This->decode_info.tile_height; @@ -1016,7 +1007,7 @@ static HRESULT TiffFrameDecode_ReadTile(TiffFrameDecode *This, UINT tile_x, UINT } } - if (hr == S_OK && This->decode_info.reverse_bgr) + if (This->decode_info.reverse_bgr) { if (This->decode_info.bps == 8) { @@ -1027,7 +1018,7 @@ static HRESULT TiffFrameDecode_ReadTile(TiffFrameDecode *This, UINT tile_x, UINT } } - if (hr == S_OK && swap_bytes && This->decode_info.bps > 8) + if (swap_bytes && This->decode_info.bps > 8) { UINT row, i, samples_per_row; BYTE *sample, temp; @@ -1055,7 +1046,7 @@ static HRESULT TiffFrameDecode_ReadTile(TiffFrameDecode *This, UINT tile_x, UINT } } - if (hr == S_OK && This->decode_info.invert_grayscale) + if (This->decode_info.invert_grayscale) { BYTE *byte, *end; @@ -1071,13 +1062,10 @@ static HRESULT TiffFrameDecode_ReadTile(TiffFrameDecode *This, UINT tile_x, UINT *byte = ~(*byte); } - if (hr == S_OK) - { - This->cached_tile_x = tile_x; - This->cached_tile_y = tile_y; - } + This->cached_tile_x = tile_x; + This->cached_tile_y = tile_y; - return hr; + return S_OK; } static HRESULT WINAPI TiffFrameDecode_CopyPixels(IWICBitmapFrameDecode *iface,
1
0
0
0
Dmitry Timoshkov : windowscodecs: Fail earlier in TIFF decoder' s Initialize method for unsupported pixel formats.
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: ea6118e9b740c8f0ede866b45b71b162c6f315e5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ea6118e9b740c8f0ede866b4…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Tue Feb 19 12:07:36 2019 +0800 windowscodecs: Fail earlier in TIFF decoder's Initialize method for unsupported pixel formats. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Vincent Povirk <vincent(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/windowscodecs/tiffformat.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/dlls/windowscodecs/tiffformat.c b/dlls/windowscodecs/tiffformat.c index 58cd04e..3bc8d69 100644 --- a/dlls/windowscodecs/tiffformat.c +++ b/dlls/windowscodecs/tiffformat.c @@ -638,6 +638,7 @@ static HRESULT WINAPI TiffDecoder_Initialize(IWICBitmapDecoder *iface, IStream * { TiffDecoder *This = impl_from_IWICBitmapDecoder(iface); TIFF *tiff; + tiff_decode_info decode_info; HRESULT hr=S_OK; TRACE("(%p,%p,%x)\n", iface, pIStream, cacheOptions); @@ -651,13 +652,20 @@ static HRESULT WINAPI TiffDecoder_Initialize(IWICBitmapDecoder *iface, IStream * } tiff = tiff_open_stream(pIStream, "r"); - if (!tiff) { hr = E_FAIL; goto exit; } + /* make sure that TIFF format is supported */ + hr = tiff_get_decode_info(tiff, &decode_info); + if (hr != S_OK) + { + pTIFFClose(tiff); + goto exit; + } + This->tiff = tiff; This->stream = pIStream; IStream_AddRef(pIStream);
1
0
0
0
Dmitry Timoshkov : windowscodecs: Fix the SupportsTransparency flag value for various pixel formats.
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: 4af1c0c246b95737ae14cbe1a72784cdf4428af0 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=4af1c0c246b95737ae14cbe1…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Tue Feb 19 12:07:10 2019 +0800 windowscodecs: Fix the SupportsTransparency flag value for various pixel formats. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Vincent Povirk <vincent(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/windowscodecs/regsvr.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dlls/windowscodecs/regsvr.c b/dlls/windowscodecs/regsvr.c index c8338f1..d215e30 100644 --- a/dlls/windowscodecs/regsvr.c +++ b/dlls/windowscodecs/regsvr.c @@ -1775,7 +1775,7 @@ static struct regsvr_pixelformat const pixelformat_list[] = { 1, /* channel count */ channel_masks_1bit, WICPixelFormatNumericRepresentationIndexed, - 1 + 0 }, { &GUID_WICPixelFormat2bppIndexed, "The Wine Project", @@ -1786,7 +1786,7 @@ static struct regsvr_pixelformat const pixelformat_list[] = { 1, /* channel count */ channel_masks_2bit, WICPixelFormatNumericRepresentationIndexed, - 1 + 0 }, { &GUID_WICPixelFormat4bppIndexed, "The Wine Project", @@ -1797,7 +1797,7 @@ static struct regsvr_pixelformat const pixelformat_list[] = { 1, /* channel count */ channel_masks_4bit, WICPixelFormatNumericRepresentationIndexed, - 1 + 0 }, { &GUID_WICPixelFormat8bppIndexed, "The Wine Project", @@ -1808,7 +1808,7 @@ static struct regsvr_pixelformat const pixelformat_list[] = { 1, /* channel count */ channel_masks_8bit, WICPixelFormatNumericRepresentationIndexed, - 1 + 0 }, { &GUID_WICPixelFormatBlackWhite, "The Wine Project", @@ -1995,7 +1995,7 @@ static struct regsvr_pixelformat const pixelformat_list[] = { 1, /* channel count */ channel_masks_32bit, WICPixelFormatNumericRepresentationFloat, - 1 + 0 }, { &GUID_WICPixelFormat48bppRGB, "The Wine Project",
1
0
0
0
Dmitry Timoshkov : windowscodecs/tests: Add a test for 8bpp indexed TIFF format.
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: 7e9c1784546d0ca0398050a4180e59f4de7cee32 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=7e9c1784546d0ca0398050a4…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Tue Feb 19 12:06:55 2019 +0800 windowscodecs/tests: Add a test for 8bpp indexed TIFF format. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Vincent Povirk <vincent(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/windowscodecs/tests/tiffformat.c | 187 +++++++++++++++++++++++++++++----- 1 file changed, 161 insertions(+), 26 deletions(-) diff --git a/dlls/windowscodecs/tests/tiffformat.c b/dlls/windowscodecs/tests/tiffformat.c index 7651ea1..2f9a0ca 100644 --- a/dlls/windowscodecs/tests/tiffformat.c +++ b/dlls/windowscodecs/tests/tiffformat.c @@ -1,5 +1,5 @@ /* - * Copyright 2012 Dmitry Timoshkov + * Copyright 2012,2016 Dmitry Timoshkov * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -145,6 +145,49 @@ static const struct tiff_8bpp_alpha { 0x11,0x22,0x33,0x44,0x55,0x66,0x77,0x88 } }; +static const struct tiff_8bpp_data +{ + USHORT byte_order; + USHORT version; + ULONG dir_offset; + USHORT number_of_entries; + struct IFD_entry entry[14]; + ULONG next_IFD; + struct IFD_rational res; + short palette_data[3][256]; + BYTE pixel_data[4]; +} tiff_8bpp_data = +{ +#ifdef WORDS_BIGENDIAN + 'M' | 'M' << 8, +#else + 'I' | 'I' << 8, +#endif + 42, + FIELD_OFFSET(struct tiff_8bpp_data, number_of_entries), + 14, + { + { 0xff, IFD_SHORT, 1, 0 }, /* SUBFILETYPE */ + { 0x100, IFD_LONG, 1, 4 }, /* IMAGEWIDTH */ + { 0x101, IFD_LONG, 1, 1 }, /* IMAGELENGTH */ + { 0x102, IFD_SHORT, 1, 8 }, /* BITSPERSAMPLE: XP doesn't accept IFD_LONG here */ + { 0x103, IFD_SHORT, 1, 1 }, /* COMPRESSION: XP doesn't accept IFD_LONG here */ + { 0x106, IFD_SHORT, 1, 3 }, /* PHOTOMETRIC */ + { 0x111, IFD_LONG, 1, FIELD_OFFSET(struct tiff_8bpp_data, pixel_data) }, /* STRIPOFFSETS */ + { 0x115, IFD_SHORT, 1, 1 }, /* SAMPLESPERPIXEL */ + { 0x116, IFD_LONG, 1, 1 }, /* ROWSPERSTRIP */ + { 0x117, IFD_LONG, 1, 1 }, /* STRIPBYTECOUNT */ + { 0x11a, IFD_RATIONAL, 1, FIELD_OFFSET(struct tiff_8bpp_data, res) }, + { 0x11b, IFD_RATIONAL, 1, FIELD_OFFSET(struct tiff_8bpp_data, res) }, + { 0x128, IFD_SHORT, 1, 2 }, /* RESOLUTIONUNIT */ + { 0x140, IFD_SHORT, 256*3, FIELD_OFFSET(struct tiff_8bpp_data, palette_data) } /* COLORMAP */ + }, + 0, + { 96, 1 }, + { { 0 } }, + { 0,1,2,3 } +}; + static const struct tiff_resolution_test_data { struct IFD_rational resx; @@ -284,29 +327,41 @@ static IStream *create_stream(const void *data, int data_size) return stream; } -static IWICBitmapDecoder *create_decoder(const void *image_data, UINT image_size) +static HRESULT create_decoder(const void *image_data, UINT image_size, IWICBitmapDecoder **decoder) { + HGLOBAL hmem; + BYTE *data; HRESULT hr; IStream *stream; - IWICBitmapDecoder *decoder = NULL; - GUID guid; + GUID format; + LONG refcount; - stream = create_stream(image_data, image_size); + *decoder = NULL; - hr = IWICImagingFactory_CreateDecoderFromStream(factory, stream, NULL, 0, &decoder); - ok(hr == S_OK, "CreateDecoderFromStream error %#x\n", hr); - if (FAILED(hr)) return NULL; + hmem = GlobalAlloc(0, image_size); + data = GlobalLock(hmem); + memcpy(data, image_data, image_size); + GlobalUnlock(hmem); - hr = IWICBitmapDecoder_GetContainerFormat(decoder, &guid); - ok(hr == S_OK, "GetContainerFormat error %#x\n", hr); - ok(IsEqualGUID(&guid, &GUID_ContainerFormatTiff), "container format is not TIFF\n"); + hr = CreateStreamOnHGlobal(hmem, TRUE, &stream); + ok(hr == S_OK, "CreateStreamOnHGlobal error %#x\n", hr); - IStream_Release(stream); + hr = IWICImagingFactory_CreateDecoderFromStream(factory, stream, NULL, 0, decoder); + if (hr == S_OK) + { + hr = IWICBitmapDecoder_GetContainerFormat(*decoder, &format); + ok(hr == S_OK, "GetContainerFormat error %#x\n", hr); + ok(IsEqualGUID(&format, &GUID_ContainerFormatTiff), + "wrong container format %s\n", wine_dbgstr_guid(&format)); - return decoder; + refcount = IStream_Release(stream); + ok(refcount > 0, "expected stream refcount > 0\n"); + } + + return hr; } -static void test_tiff_palette(void) +static void test_tiff_1bpp_palette(void) { HRESULT hr; IWICBitmapDecoder *decoder; @@ -314,9 +369,9 @@ static void test_tiff_palette(void) IWICPalette *palette; GUID format; - decoder = create_decoder(&tiff_1bpp_data, sizeof(tiff_1bpp_data)); - ok(decoder != 0, "Failed to load TIFF image data\n"); - if (!decoder) return; + hr = create_decoder(&tiff_1bpp_data, sizeof(tiff_1bpp_data), &decoder); + ok(hr == S_OK, "Failed to load TIFF image data %#x\n", hr); + if (hr != S_OK) return; hr = IWICBitmapDecoder_GetFrame(decoder, 0, &frame); ok(hr == S_OK, "GetFrame error %#x\n", hr); @@ -448,9 +503,9 @@ static void test_tiff_8bpp_alpha(void) static const BYTE expected_data[16] = { 0x11,0x11,0x11,0x22,0x33,0x33,0x33,0x44, 0x55,0x55,0x55,0x66,0x77,0x77,0x77,0x88 }; - decoder = create_decoder(&tiff_8bpp_alpha, sizeof(tiff_8bpp_alpha)); - ok(decoder != 0, "Failed to load TIFF image data\n"); - if (!decoder) return; + hr = create_decoder(&tiff_8bpp_alpha, sizeof(tiff_8bpp_alpha), &decoder); + ok(hr == S_OK, "Failed to load TIFF image data %#x\n", hr); + if (hr != S_OK) return; hr = IWICBitmapDecoder_GetFrameCount(decoder, &frame_count); ok(hr == S_OK, "GetFrameCount error %#x\n", hr); @@ -497,6 +552,84 @@ static void test_tiff_8bpp_alpha(void) IWICBitmapFrameDecode_Release(frame); } +static void generate_tiff_palette(void *buf, unsigned count) +{ + unsigned short *r, *g, *b; + unsigned i; + + r = buf; + g = r + count; + b = g + count; + + r[0] = 0x11 * 257; + g[0] = 0x22 * 257; + b[0] = 0x33 * 257; + r[1] = 0x44 * 257; + g[1] = 0x55 * 257; + b[1] = 0x66 * 257; + r[2] = 0x77 * 257; + g[2] = 0x88 * 257; + b[2] = 0x99 * 257; + r[3] = 0xa1 * 257; + g[3] = 0xb5 * 257; + b[3] = 0xff * 257; + + for (i = 4; i < count; i++) + { + r[i] = i * 257; + g[i] = (i | 0x40) * 257; + b[i] = (i | 0x80) * 257; + } +} + +static void test_tiff_8bpp_palette(void) +{ + char buf[sizeof(tiff_8bpp_data)]; + HRESULT hr; + IWICBitmapDecoder *decoder; + IWICBitmapFrameDecode *frame; + IWICPalette *palette; + GUID format; + UINT count, ret; + WICColor color[256]; + + memcpy(buf, &tiff_8bpp_data, sizeof(tiff_8bpp_data)); + generate_tiff_palette(buf + FIELD_OFFSET(struct tiff_8bpp_data, palette_data), 256); + + hr = create_decoder(buf, sizeof(buf), &decoder); + ok(hr == S_OK, "Failed to load TIFF image data %#x\n", hr); + if (hr != S_OK) return; + + hr = IWICBitmapDecoder_GetFrame(decoder, 0, &frame); + ok(hr == S_OK, "GetFrame error %#x\n", hr); + + hr = IWICBitmapFrameDecode_GetPixelFormat(frame, &format); + ok(hr == S_OK, "GetPixelFormat error %#x\n", hr); + ok(IsEqualGUID(&format, &GUID_WICPixelFormat8bppIndexed), + "expected GUID_WICPixelFormat8bppIndexed, got %s\n", wine_dbgstr_guid(&format)); + + hr = IWICImagingFactory_CreatePalette(factory, &palette); + ok(hr == S_OK, "CreatePalette error %#x\n", hr); + hr = IWICBitmapFrameDecode_CopyPalette(frame, palette); + ok(hr == S_OK, "CopyPalette error %#x\n", hr); + + hr = IWICPalette_GetColorCount(palette, &count); + ok(hr == S_OK, "GetColorCount error %#x\n", hr); + ok(count == 256, "expected 256, got %u\n", count); + + hr = IWICPalette_GetColors(palette, 256, color, &ret); + ok(hr == S_OK, "GetColors error %#x\n", hr); + ok(ret == count, "expected %u, got %u\n", count, ret); + ok(color[0] == 0xff112233, "got %#x\n", color[0]); + ok(color[1] == 0xff445566, "got %#x\n", color[1]); + ok(color[2] == 0xff778899, "got %#x\n", color[2]); + ok(color[3] == 0xffa1b5ff, "got %#x\n", color[3]); + + IWICPalette_Release(palette); + IWICBitmapFrameDecode_Release(frame); + IWICBitmapDecoder_Release(decoder); +} + static void test_tiff_resolution(void) { HRESULT hr; @@ -512,9 +645,9 @@ static void test_tiff_resolution(void) tiff_resolution_image_data.resy = test_data->resy; tiff_resolution_image_data.entry[12].value = test_data->resolution_unit; - decoder = create_decoder(&tiff_resolution_image_data, sizeof(tiff_resolution_image_data)); - ok(decoder != 0, "%d: Failed to load TIFF image data\n", i); - if (!decoder) continue; + hr = create_decoder(&tiff_resolution_image_data, sizeof(tiff_resolution_image_data), &decoder); + ok(hr == S_OK, "Failed to load TIFF image data %#x\n", hr); + if (hr != S_OK) return; hr = IWICBitmapDecoder_GetFrame(decoder, 0, &frame); ok(hr == S_OK, "%d: GetFrame error %#x\n", i, hr); @@ -561,8 +694,9 @@ static void test_tiff_24bpp(void) BYTE data[3]; static const BYTE expected_data[] = { 0x33,0x22,0x11 }; - decoder = create_decoder(&tiff_24bpp_data, sizeof(tiff_24bpp_data)); - ok(decoder != NULL, "Failed to load TIFF image data\n"); + hr = create_decoder(&tiff_24bpp_data, sizeof(tiff_24bpp_data), &decoder); + ok(hr == S_OK, "Failed to load TIFF image data %#x\n", hr); + if (hr != S_OK) return; hr = IWICBitmapDecoder_GetFrameCount(decoder, &count); ok(hr == S_OK, "GetFrameCount error %#x\n", hr); @@ -620,7 +754,8 @@ START_TEST(tiffformat) ok(hr == S_OK, "CoCreateInstance error %#x\n", hr); if (FAILED(hr)) return; - test_tiff_palette(); + test_tiff_1bpp_palette(); + test_tiff_8bpp_palette(); test_QueryCapability(); test_tiff_8bpp_alpha(); test_tiff_resolution();
1
0
0
0
Michael Stefaniuc : d3dx9: Remove redundant "not NULL" checks ( coccinellery).
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: be30aab1e21e5b6811470a351ec0d6100e6e7687 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=be30aab1e21e5b6811470a35…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Tue Feb 19 00:06:22 2019 +0100 d3dx9: Remove redundant "not NULL" checks (coccinellery). Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dx9_36/effect.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/dlls/d3dx9_36/effect.c b/dlls/d3dx9_36/effect.c index e8ae7b5..1abc8dc 100644 --- a/dlls/d3dx9_36/effect.c +++ b/dlls/d3dx9_36/effect.c @@ -948,15 +948,14 @@ struct d3dx_parameter *get_parameter_by_name(struct d3dx9_base_effect *base, return NULL; } - count = parameter ? parameter->member_count : base->parameter_count; + count = parameter->member_count; length = strcspn( name, "[.@" ); part = name + length; for (i = 0; i < count; i++) { - temp_parameter = !parameter ? &base->parameters[i].param - : ¶meter->members[i]; + temp_parameter = ¶meter->members[i]; if (!strcmp(temp_parameter->name, name)) { @@ -971,13 +970,8 @@ struct d3dx_parameter *get_parameter_by_name(struct d3dx9_base_effect *base, return get_parameter_by_name(base, temp_parameter, part); case '@': - { - struct d3dx_top_level_parameter *top_param - = top_level_parameter_from_parameter(temp_parameter); + return NULL; - return parameter ? NULL : get_annotation_by_name(base, top_param->annotation_count, - top_param->annotations, part); - } case '[': return get_parameter_element_by_name(base, temp_parameter, part);
1
0
0
0
Michael Stefaniuc : mshtml: Remove useless casts to self.
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: cfe8651c9187d0dd6ad54f129f0a53da2aaedd95 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=cfe8651c9187d0dd6ad54f12…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Mon Feb 18 21:14:00 2019 +0100 mshtml: Remove useless casts to self. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mshtml/editor.c | 8 ++++---- dlls/mshtml/htmlelem.c | 6 +++--- dlls/mshtml/tests/htmldoc.c | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/dlls/mshtml/editor.c b/dlls/mshtml/editor.c index 6838433..c901592 100644 --- a/dlls/mshtml/editor.c +++ b/dlls/mshtml/editor.c @@ -295,7 +295,7 @@ static void get_font_size(HTMLDocument *This, WCHAR *ret) TRACE("found font tag %p\n", elem); - get_elem_attr_value((nsIDOMElement*)elem, sizeW, &val_str, &val); + get_elem_attr_value(elem, sizeW, &val_str, &val); if(*val) { TRACE("found size %s\n", debugstr_w(val)); strcpyW(ret, val); @@ -366,7 +366,7 @@ static void set_font_size(HTMLDocument *This, LPCWSTR size) nsISelection_Collapse(nsselection, (nsIDOMNode*)elem, 0); }else { /* Remove all size attributes from the range */ - remove_child_attr((nsIDOMElement*)elem, fontW, &size_str); + remove_child_attr(elem, fontW, &size_str); nsISelection_SelectAllChildren(nsselection, (nsIDOMNode*)elem); } @@ -1174,10 +1174,10 @@ static HRESULT exec_hyperlink(HTMLDocument *This, DWORD cmdexecopt, VARIANT *in, if (insert_link_at_caret) { /* add them to the document at the caret position */ - nsres = nsIHTMLEditor_InsertElementAtSelection(html_editor, (nsIDOMElement*)anchor_elem, FALSE); + nsres = nsIHTMLEditor_InsertElementAtSelection(html_editor, anchor_elem, FALSE); nsISelection_SelectAllChildren(nsselection, (nsIDOMNode*)anchor_elem); }else /* add them around the selection using the magic provided to us by nsIHTMLEditor */ - nsres = nsIHTMLEditor_InsertLinkAroundSelection(html_editor, (nsIDOMElement*)anchor_elem); + nsres = nsIHTMLEditor_InsertLinkAroundSelection(html_editor, anchor_elem); nsIHTMLEditor_Release(html_editor); hres = NS_SUCCEEDED(nsres) ? S_OK : E_FAIL; diff --git a/dlls/mshtml/htmlelem.c b/dlls/mshtml/htmlelem.c index 4da0156..d490030 100644 --- a/dlls/mshtml/htmlelem.c +++ b/dlls/mshtml/htmlelem.c @@ -5597,14 +5597,14 @@ HRESULT HTMLElement_Create(HTMLDocumentNode *doc, nsIDOMNode *nsnode, BOOL use_g tag = get_tag_desc(tag_name); if(tag) { - hres = tag->constructor(doc, (nsIDOMElement*)nselem, &elem); + hres = tag->constructor(doc, nselem, &elem); }else if(use_generic) { - hres = HTMLGenericElement_Create(doc, (nsIDOMElement*)nselem, &elem); + hres = HTMLGenericElement_Create(doc, nselem, &elem); }else { elem = heap_alloc_zero(sizeof(HTMLElement)); if(elem) { elem->node.vtbl = &HTMLElementImplVtbl; - HTMLElement_Init(elem, doc, (nsIDOMElement*)nselem, &HTMLElement_dispex); + HTMLElement_Init(elem, doc, nselem, &HTMLElement_dispex); hres = S_OK; }else { hres = E_OUTOFMEMORY; diff --git a/dlls/mshtml/tests/htmldoc.c b/dlls/mshtml/tests/htmldoc.c index 25cdf80..52e6fe7 100644 --- a/dlls/mshtml/tests/htmldoc.c +++ b/dlls/mshtml/tests/htmldoc.c @@ -7543,7 +7543,7 @@ static void test_QueryInterface(IHTMLDocument2 *htmldoc) hres = IUnknown_QueryInterface(doc, &IID_IDispatch, (void**)&qi); ok(hres == S_OK, "Could not get IDispatch interface: %08x\n", hres); - ok(qi != (IUnknown*)doc, "disp == doc\n"); + ok(qi != doc, "disp == doc\n"); IUnknown_Release(qi); }
1
0
0
0
Andrey Gusev : ext-ms-win-ntuser-misc-l1-1-0: Add dll.
by Alexandre Julliard
20 Feb '19
20 Feb '19
Module: wine Branch: master Commit: a1a9ca8f4a6f21dcc03f341fd0b7fed1475b4396 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a1a9ca8f4a6f21dcc03f341f…
Author: Andrey Gusev <andrey.goosev(a)gmail.com> Date: Wed Feb 20 14:23:39 2019 +0200 ext-ms-win-ntuser-misc-l1-1-0: Add dll. Signed-off-by: Andrey Gusev <andrey.goosev(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- configure | 2 ++ configure.ac | 1 + dlls/ext-ms-win-ntuser-misc-l1-1-0/Makefile.in | 1 + .../ext-ms-win-ntuser-misc-l1-1-0.spec | 20 ++++++++++++++++++++ tools/make_specfiles | 1 + 5 files changed, 25 insertions(+) diff --git a/configure b/configure index 1c15b5a..166ddbf 100755 --- a/configure +++ b/configure @@ -1280,6 +1280,7 @@ enable_ext_ms_win_ntuser_gui_l1_3_0 enable_ext_ms_win_ntuser_keyboard_l1_3_0 enable_ext_ms_win_ntuser_message_l1_1_0 enable_ext_ms_win_ntuser_message_l1_1_1 +enable_ext_ms_win_ntuser_misc_l1_1_0 enable_ext_ms_win_ntuser_misc_l1_2_0 enable_ext_ms_win_ntuser_misc_l1_5_1 enable_ext_ms_win_ntuser_mouse_l1_1_0 @@ -19589,6 +19590,7 @@ wine_fn_config_makefile dlls/ext-ms-win-ntuser-gui-l1-3-0 enable_ext_ms_win_ntus wine_fn_config_makefile dlls/ext-ms-win-ntuser-keyboard-l1-3-0 enable_ext_ms_win_ntuser_keyboard_l1_3_0 wine_fn_config_makefile dlls/ext-ms-win-ntuser-message-l1-1-0 enable_ext_ms_win_ntuser_message_l1_1_0 wine_fn_config_makefile dlls/ext-ms-win-ntuser-message-l1-1-1 enable_ext_ms_win_ntuser_message_l1_1_1 +wine_fn_config_makefile dlls/ext-ms-win-ntuser-misc-l1-1-0 enable_ext_ms_win_ntuser_misc_l1_1_0 wine_fn_config_makefile dlls/ext-ms-win-ntuser-misc-l1-2-0 enable_ext_ms_win_ntuser_misc_l1_2_0 wine_fn_config_makefile dlls/ext-ms-win-ntuser-misc-l1-5-1 enable_ext_ms_win_ntuser_misc_l1_5_1 wine_fn_config_makefile dlls/ext-ms-win-ntuser-mouse-l1-1-0 enable_ext_ms_win_ntuser_mouse_l1_1_0 diff --git a/configure.ac b/configure.ac index 91cba94..f11a452 100644 --- a/configure.ac +++ b/configure.ac @@ -3318,6 +3318,7 @@ WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-gui-l1-3-0) WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-keyboard-l1-3-0) WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-message-l1-1-0) WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-message-l1-1-1) +WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-misc-l1-1-0) WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-misc-l1-2-0) WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-misc-l1-5-1) WINE_CONFIG_MAKEFILE(dlls/ext-ms-win-ntuser-mouse-l1-1-0) diff --git a/dlls/ext-ms-win-ntuser-misc-l1-1-0/Makefile.in b/dlls/ext-ms-win-ntuser-misc-l1-1-0/Makefile.in new file mode 100644 index 0000000..da5be2d --- /dev/null +++ b/dlls/ext-ms-win-ntuser-misc-l1-1-0/Makefile.in @@ -0,0 +1 @@ +MODULE = ext-ms-win-ntuser-misc-l1-1-0.dll diff --git a/dlls/ext-ms-win-ntuser-misc-l1-1-0/ext-ms-win-ntuser-misc-l1-1-0.spec b/dlls/ext-ms-win-ntuser-misc-l1-1-0/ext-ms-win-ntuser-misc-l1-1-0.spec new file mode 100644 index 0000000..4a19314 --- /dev/null +++ b/dlls/ext-ms-win-ntuser-misc-l1-1-0/ext-ms-win-ntuser-misc-l1-1-0.spec @@ -0,0 +1,20 @@ +@ stdcall DrawTextW(long wstr long ptr long) user32.DrawTextW +@ stdcall ExitWindowsEx(long long) user32.ExitWindowsEx +@ stdcall GetClipboardFormatNameW(long ptr long) user32.GetClipboardFormatNameW +@ stdcall GetGuiResources(long long) user32.GetGuiResources +@ stdcall GetUserObjectSecurity(long ptr ptr long ptr) user32.GetUserObjectSecurity +@ stdcall KillTimer(long long) user32.KillTimer +@ stdcall MessageBeep(long) user32.MessageBeep +@ stdcall MonitorFromPoint(int64 long) user32.MonitorFromPoint +@ stdcall MonitorFromRect(ptr long) user32.MonitorFromRect +@ stdcall RegisterClipboardFormatW(wstr) user32.RegisterClipboardFormatW +@ stdcall RegisterDeviceNotificationW(long ptr long) user32.RegisterDeviceNotificationW +@ stdcall SetCoalescableTimer(long long long ptr long) user32.SetCoalescableTimer +@ stdcall SetTimer(long long long ptr) user32.SetTimer +@ stdcall SetUserObjectSecurity(long ptr ptr) user32.SetUserObjectSecurity +@ stdcall ShutdownBlockReasonCreate(long wstr) user32.ShutdownBlockReasonCreate +@ stdcall ShutdownBlockReasonDestroy(long) user32.ShutdownBlockReasonDestroy +@ stdcall TabbedTextOutW(long long long wstr long long ptr long) user32.TabbedTextOutW +@ stdcall UnregisterDeviceNotification(long) user32.UnregisterDeviceNotification +@ stdcall WaitForInputIdle(long long) user32.WaitForInputIdle +@ stdcall WinHelpW(long wstr long long) user32.WinHelpW diff --git a/tools/make_specfiles b/tools/make_specfiles index ab5b3fd..3bd6123 100755 --- a/tools/make_specfiles +++ b/tools/make_specfiles @@ -383,6 +383,7 @@ my @dll_groups = "ext-ms-win-ntuser-keyboard-l1-3-0", "ext-ms-win-ntuser-message-l1-1-0", "ext-ms-win-ntuser-message-l1-1-1", + "ext-ms-win-ntuser-misc-l1-1-0", "ext-ms-win-ntuser-misc-l1-2-0", "ext-ms-win-ntuser-misc-l1-5-1", "ext-ms-win-ntuser-mouse-l1-1-0",
1
0
0
0
← Newer
1
...
20
21
22
23
24
25
26
...
68
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
Results per page:
10
25
50
100
200