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 2016
----- 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
2 participants
755 discussions
Start a n
N
ew thread
Aurimas Fišeras : po: Update Lithuanian translation.
by Alexandre Julliard
10 Feb '16
10 Feb '16
Module: wine Branch: master Commit: daaf421ab5796752f28b111972aff1f1b9a9c70a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=daaf421ab5796752f28b11197…
Author: Aurimas Fišeras <aurimas(a)members.fsf.org> Date: Tue Feb 9 21:10:09 2016 +0200 po: Update Lithuanian translation. Signed-off-by: Aurimas Fišeras <aurimas(a)members.fsf.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- po/lt.po | 75 ++++++++++++++++------------------------------------------------ 1 file changed, 18 insertions(+), 57 deletions(-) diff --git a/po/lt.po b/po/lt.po index d7b61f3..b7053e1 100644 --- a/po/lt.po +++ b/po/lt.po @@ -1,11 +1,11 @@ # Lithuanian translations for Wine -# Aurimas Fišeras <aurimas(a)members.fsf.org>, 2011, 2012, 2013, 2014, 2015. +# Aurimas Fišeras <aurimas(a)members.fsf.org>, 2011, 2012, 2013, 2014, 2015, 2016. msgid "" msgstr "" "Project-Id-Version: Wine\n" "Report-Msgid-Bugs-To:
http://bugs.winehq.org\n
" "POT-Creation-Date: N/A\n" -"PO-Revision-Date: 2015-12-23 17:35+0300\n" +"PO-Revision-Date: 2016-02-09 21:07+0300\n" "Last-Translator: Aurimas Fišeras <aurimas(a)members.fsf.org>\n" "Language-Team: Lithuanian <komp_lt(a)konf.lt>\n" "Language: lt\n" @@ -11578,68 +11578,45 @@ msgid "The operation completed successfully\n" msgstr "Operacija sėkmingai įvykdyta\n" #: reg.rc:35 -#, fuzzy -#| msgid "Error: Invalid key name\n" msgid "reg: Invalid key name\n" -msgstr "Klaida: Netinkamas rakto vardas\n" +msgstr "reg: Netinkamas rakto vardas\n" #: reg.rc:36 -#, fuzzy -#| msgid "Error: Invalid command line parameters\n" msgid "reg: Invalid command line parameters\n" -msgstr "Klaida: Netinkami komandos eilutės parametrai\n" +msgstr "reg: Netinkami komandos eilutės parametrai\n" #: reg.rc:37 -#, fuzzy -#| msgid "Error: Unable to access remote machine\n" msgid "reg: Unable to access remote machine\n" -msgstr "Klaida: Nepavyko prieiti prie nuotolinio kompiuterio\n" +msgstr "reg: Nepavyko prieiti prie nuotolinio kompiuterio\n" #: reg.rc:38 -#, fuzzy -#| msgid "" -#| "Error: The system was unable to find the specified registry key or value\n" msgid "" "reg: The system was unable to find the specified registry key or value\n" -msgstr "Klaida: Sistemai nepavyko rasti nurodyto registro rakto ar reikšmės\n" +msgstr "reg: Sistemai nepavyko rasti nurodyto registro rakto ar reikšmės\n" #: reg.rc:39 -#, fuzzy -#| msgid "Error: Unsupported type\n" msgid "reg: Unsupported registry data type [%1]\n" -msgstr "Klaida: Nepalaikomas tipas\n" +msgstr "reg: Nepalaikomas registro duomenų tipas [%1]\n" #: reg.rc:40 -#, fuzzy -#| msgid "" -#| "uninstaller: The option '--remove' must be followed by an application " -#| "GUID\n" msgid "reg: The option [/d] must be followed by a valid integer\n" -msgstr "" -"šalinimo programa: Už parametro „--remove“ privalo būti programos GUID\n" +msgstr "reg: Už parametro [/d] privalo būti tinkamas sveikasis skaičius\n" #: reg.rc:41 -#, fuzzy -#| msgid "" -#| "uninstaller: The option '--remove' must be followed by an application " -#| "GUID\n" msgid "reg: The option [/d] must be followed by a valid hexadecimal value\n" -msgstr "" -"šalinimo programa: Už parametro „--remove“ privalo būti programos GUID\n" +msgstr "reg: Už parametro [/d] privalo būti tinkama šešioliktainė reikšmė\n" #: reg.rc:42 msgid "reg: Unhandled registry data type [/t 0x%1!x!, /d %2]\n" -msgstr "" +msgstr "reg: Neapdorojamas registro duomenų tipas [/t 0x%1!x!, /d %2]\n" #: reg.rc:43 -#, fuzzy -#| msgid "The specified file already exists. Do you want to replace it?" msgid "The registry value '%1' already exists. Do you want to overwrite it?" -msgstr "Nurodytas failas jau egzistuoja. Ar norite jį perrašyti?" +msgstr "Registro reikšmė „%1“ jau egzistuoja. Ar norite ją perrašyti?" #: reg.rc:47 msgid "The registry operation was cancelled\n" -msgstr "" +msgstr "Registro operacija buvo nutraukta\n" #: regedit.rc:34 msgid "&Registry" @@ -13093,8 +13070,6 @@ msgstr "" "atskirai." #: winecfg.rc:159 -#, fuzzy -#| msgid "&Add application..." msgid "Add appli&cation..." msgstr "&Pridėti programą..." @@ -13157,7 +13132,7 @@ msgstr "&Naujas nustelbimas bibliotekai:" #: winecfg.rc:196 msgid "A&dd" -msgstr "" +msgstr "&Pridėti" #: winecfg.rc:197 msgid "Existing &overrides:" @@ -13184,8 +13159,6 @@ msgid "&Native (Windows)" msgstr "&Sava („Windows“)" #: winecfg.rc:211 -#, fuzzy -#| msgid "Bui<in then Native" msgid "Buil&tin then Native" msgstr "Į&taisyta, po to sava" @@ -13210,26 +13183,20 @@ msgstr "" "redaguojama." #: winecfg.rc:236 -#, fuzzy -#| msgid "&Add..." msgid "A&dd..." -msgstr "&Pridėti..." +msgstr "Pri&dėti..." #: winecfg.rc:238 -#, fuzzy -#| msgid "Autodetect" msgid "Aut&odetect" -msgstr "Automatiškai aptikti" +msgstr "&Automatiškai aptikti" #: winecfg.rc:241 msgid "&Path:" msgstr "&Kelias:" #: winecfg.rc:248 winecfg.rc:38 -#, fuzzy -#| msgid "Show &Advanced" msgid "Show Advan&ced" -msgstr "Rodyti papil&domas" +msgstr "Rodyti papild&omas" #: winecfg.rc:249 msgid "De&vice:" @@ -13248,8 +13215,6 @@ msgid "S&erial:" msgstr "N&umeris:" #: winecfg.rc:258 -#, fuzzy -#| msgid "Show &dot files" msgid "&Show dot files" msgstr "Rodyti &failus su tašku" @@ -13330,10 +13295,8 @@ msgid "Select the Unix target directory, please." msgstr "Išrinkite Unix paskirties aplanką." #: winecfg.rc:37 -#, fuzzy -#| msgid "Hide &Advanced" msgid "Hide Advan&ced" -msgstr "Slėpti papil&domas" +msgstr "Slėpti papild&omas" #: winecfg.rc:39 msgid "(No Theme)" @@ -13794,12 +13757,10 @@ msgid "Configuration error" msgstr "Konfigūracijos klaida" #: wineconsole.rc:42 -#, fuzzy -#| msgid "Screen buffer size must be greater or equal to the window's one" msgid "" "The size of the screen buffer must be greater than or equal to the size of " "the window." -msgstr "Ekrano buferio dydis turi būti didesnis arba lygus lango buferiui" +msgstr "Ekrano buferio dydis turi būti didesnis arba lygus lango dydžiui." #: wineconsole.rc:37 msgid "Each character is %1!u! pixels wide and %2!u! pixels high"
1
0
0
0
Nikolay Sivov : gdi32/tests: Turn some asserts in font tests into regular tests.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: 11be16ca799ac642fb636633392f4ec80e765da7 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=11be16ca799ac642fb6366333…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue Feb 9 17:24:28 2016 +0300 gdi32/tests: Turn some asserts in font tests into regular tests. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/gdi32/tests/font.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dlls/gdi32/tests/font.c b/dlls/gdi32/tests/font.c index ce8da24..c56eb81 100644 --- a/dlls/gdi32/tests/font.c +++ b/dlls/gdi32/tests/font.c @@ -926,7 +926,7 @@ static void test_bitmap_font_metrics(void) trace("ACP %d -> charset %d\n", GetACP(), expected_cs); hdc = CreateCompatibleDC(0); - assert(hdc); + ok(hdc != NULL, "failed to create hdc\n"); trace("logpixelsX %d, logpixelsY %d\n", GetDeviceCaps(hdc, LOGPIXELSX), GetDeviceCaps(hdc, LOGPIXELSY)); @@ -1746,7 +1746,7 @@ static void test_GetKerningPairs(void) strcpy(lf.lfFaceName, kd[i].face_name); lf.lfHeight = kd[i].height; hfont = CreateFontIndirectA(&lf); - assert(hfont != 0); + ok(hfont != NULL, "failed to create a font, name %s\n", kd[i].face_name); hfont_old = SelectObject(hdc, hfont); @@ -1872,7 +1872,7 @@ static void test_height( HDC hdc, const struct font_data *fd ) strcpy(lf.lfFaceName, fd[i].face_name); hfont = CreateFontIndirectA(&lf); - assert(hfont); + ok(hfont != NULL, "failed to create a font, name %s\n", fd[i].face_name); old_hfont = SelectObject(hdc, hfont); ret = GetTextMetricsA(hdc, &tm); @@ -2098,7 +2098,7 @@ static void test_height_selection(void) {"", 0, 0, 0, 0, 0, 0, 0, 0, 0 } }; HDC hdc = CreateCompatibleDC(0); - assert(hdc); + ok(hdc != NULL, "failed to create hdc\n"); test_height( hdc, tahoma ); test_height_selection_vdmx( hdc );
1
0
0
0
Nikolay Sivov : gdi32: Fix otmfsSelection to have italic style set in case of oblique simulation.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: 6389f41135f73d829bc302f2f08443b1f006fb18 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=6389f41135f73d829bc302f2f…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue Feb 9 17:24:27 2016 +0300 gdi32: Fix otmfsSelection to have italic style set in case of oblique simulation. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/tests/font.c | 3 +-- dlls/gdi32/freetype.c | 2 ++ dlls/gdi32/tests/font.c | 49 +++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 51 insertions(+), 3 deletions(-) diff --git a/dlls/dwrite/tests/font.c b/dlls/dwrite/tests/font.c index 2d31541..cd63ce7 100644 --- a/dlls/dwrite/tests/font.c +++ b/dlls/dwrite/tests/font.c @@ -707,8 +707,7 @@ if (0) style = IDWriteFont_GetStyle(font); ok(style == DWRITE_FONT_STYLE_OBLIQUE, "got %d\n", style); -todo_wine - ok(otm.otmfsSelection == 1, "got 0x%08x\n", otm.otmfsSelection); + ok(otm.otmfsSelection & 1, "got 0x%08x\n", otm.otmfsSelection); ret = IDWriteFont_IsSymbolFont(font); ok(!ret, "got %d\n", ret); diff --git a/dlls/gdi32/freetype.c b/dlls/gdi32/freetype.c index ea81ee1..1a488df 100644 --- a/dlls/gdi32/freetype.c +++ b/dlls/gdi32/freetype.c @@ -7848,6 +7848,8 @@ static BOOL get_outline_text_metrics(GdiFont *font) font->potm->otmFiller = 0; memcpy(&font->potm->otmPanoseNumber, pOS2->panose, PANOSE_COUNT); font->potm->otmfsSelection = pOS2->fsSelection; + if (font->fake_italic) + font->potm->otmfsSelection |= 1; font->potm->otmfsType = pOS2->fsType; font->potm->otmsCharSlopeRise = pHori->caret_Slope_Rise; font->potm->otmsCharSlopeRun = pHori->caret_Slope_Run; diff --git a/dlls/gdi32/tests/font.c b/dlls/gdi32/tests/font.c index b5ce93e..ce8da24 100644 --- a/dlls/gdi32/tests/font.c +++ b/dlls/gdi32/tests/font.c @@ -2106,6 +2106,34 @@ static void test_height_selection(void) DeleteDC(hdc); } +static UINT get_font_fsselection(LOGFONTA *lf) +{ + OUTLINETEXTMETRICA *otm; + HFONT hfont, hfont_old; + DWORD ret, otm_size; + UINT fsSelection; + HDC hdc; + + hdc = GetDC(0); + hfont = CreateFontIndirectA(lf); + ok(hfont != NULL, "failed to create a font\n"); + + hfont_old = SelectObject(hdc, hfont); + + otm_size = GetOutlineTextMetricsA(hdc, 0, NULL); + otm = HeapAlloc(GetProcessHeap(), 0, otm_size); + otm->otmSize = sizeof(*otm); + ret = GetOutlineTextMetricsA(hdc, otm->otmSize, otm); + ok(ret == otm->otmSize, "expected %u, got %u, error %d\n", otm->otmSize, ret, GetLastError()); + fsSelection = otm->otmfsSelection; + HeapFree(GetProcessHeap(), 0, otm); + SelectObject(hdc, hfont_old); + DeleteObject(hfont); + ReleaseDC(0, hdc); + + return fsSelection; +} + static void test_GetOutlineTextMetrics(void) { OUTLINETEXTMETRICA *otm; @@ -2114,6 +2142,25 @@ static void test_GetOutlineTextMetrics(void) HDC hdc; DWORD ret, otm_size; LPSTR unset_ptr; + UINT fsSelection; + + /* check fsSelection field with oblique simulation */ + memset(&lf, 0, sizeof(lf)); + + strcpy(lf.lfFaceName, "Tahoma"); + lf.lfHeight = -13; + lf.lfWeight = FW_NORMAL; + lf.lfPitchAndFamily = DEFAULT_PITCH; + lf.lfQuality = PROOF_QUALITY; + + /* regular face */ + fsSelection = get_font_fsselection(&lf); + ok((fsSelection & 1) == 0, "got 0x%x\n", fsSelection); + + lf.lfItalic = 1; + /* face with oblique simulation */ + fsSelection = get_font_fsselection(&lf); + ok((fsSelection & 1) == 1, "got 0x%x\n", fsSelection); if (!is_font_installed("Arial")) { @@ -2130,7 +2177,7 @@ static void test_GetOutlineTextMetrics(void) lf.lfPitchAndFamily = DEFAULT_PITCH; lf.lfQuality = PROOF_QUALITY; hfont = CreateFontIndirectA(&lf); - assert(hfont != 0); + ok(hfont != NULL, "failed to create a font\n"); hfont_old = SelectObject(hdc, hfont); otm_size = GetOutlineTextMetricsA(hdc, 0, NULL);
1
0
0
0
Nikolay Sivov : dwrite: Fetch all glyphs at once instead of locking/ unlocking for every glyph.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: f26b4a357560d7edeb7596091bf76ad03f8d7d2c URL:
http://source.winehq.org/git/wine.git/?a=commit;h=f26b4a357560d7edeb7596091…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue Feb 9 17:11:20 2016 +0300 dwrite: Fetch all glyphs at once instead of locking/unlocking for every glyph. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/dwrite_private.h | 2 +- dlls/dwrite/font.c | 5 +---- dlls/dwrite/freetype.c | 31 +++++++++++++++++-------------- 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/dlls/dwrite/dwrite_private.h b/dlls/dwrite/dwrite_private.h index fd6d3c7..874f0bb 100644 --- a/dlls/dwrite/dwrite_private.h +++ b/dlls/dwrite/dwrite_private.h @@ -212,7 +212,7 @@ extern BOOL freetype_is_monospaced(IDWriteFontFace2*) DECLSPEC_HIDDEN; extern HRESULT freetype_get_glyphrun_outline(IDWriteFontFace2*,FLOAT,UINT16 const*,FLOAT const*, DWRITE_GLYPH_OFFSET const*, UINT32,BOOL,IDWriteGeometrySink*) DECLSPEC_HIDDEN; extern UINT16 freetype_get_glyphcount(IDWriteFontFace2*) DECLSPEC_HIDDEN; -extern UINT16 freetype_get_glyphindex(IDWriteFontFace2*,UINT32,INT) DECLSPEC_HIDDEN; +extern void freetype_get_glyphs(IDWriteFontFace2*,INT,UINT32 const*,UINT32,UINT16*) DECLSPEC_HIDDEN; extern BOOL freetype_has_kerning_pairs(IDWriteFontFace2*) DECLSPEC_HIDDEN; extern INT32 freetype_get_kerning_pair_adjustment(IDWriteFontFace2*,UINT16,UINT16) DECLSPEC_HIDDEN; extern void freetype_get_glyph_bbox(struct dwrite_glyphbitmap*) DECLSPEC_HIDDEN; diff --git a/dlls/dwrite/font.c b/dlls/dwrite/font.c index f350936..fd64d8b 100644 --- a/dlls/dwrite/font.c +++ b/dlls/dwrite/font.c @@ -576,7 +576,6 @@ static HRESULT WINAPI dwritefontface_GetGlyphIndices(IDWriteFontFace2 *iface, UI UINT32 count, UINT16 *glyph_indices) { struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); - UINT32 i; TRACE("(%p)->(%p %u %p)\n", This, codepoints, count, glyph_indices); @@ -588,9 +587,7 @@ static HRESULT WINAPI dwritefontface_GetGlyphIndices(IDWriteFontFace2 *iface, UI return E_INVALIDARG; } - for (i = 0; i < count; i++) - glyph_indices[i] = freetype_get_glyphindex(iface, codepoints[i], This->charmap); - + freetype_get_glyphs(iface, This->charmap, codepoints, count, glyph_indices); return S_OK; } diff --git a/dlls/dwrite/freetype.c b/dlls/dwrite/freetype.c index 18b720a..753493d 100644 --- a/dlls/dwrite/freetype.c +++ b/dlls/dwrite/freetype.c @@ -493,23 +493,25 @@ UINT16 freetype_get_glyphcount(IDWriteFontFace2 *fontface) return count; } -UINT16 freetype_get_glyphindex(IDWriteFontFace2 *fontface, UINT32 codepoint, INT charmap) +void freetype_get_glyphs(IDWriteFontFace2 *fontface, INT charmap, UINT32 const *codepoints, UINT32 count, + UINT16 *glyphs) { - UINT16 glyph; + UINT32 i; EnterCriticalSection(&freetype_cs); - if (charmap == -1) - glyph = pFTC_CMapCache_Lookup(cmap_cache, fontface, charmap, codepoint); - else { - /* special handling for symbol fonts */ - if (codepoint < 0x100) codepoint += 0xf000; - glyph = pFTC_CMapCache_Lookup(cmap_cache, fontface, charmap, codepoint); - if (!glyph) - glyph = pFTC_CMapCache_Lookup(cmap_cache, fontface, charmap, codepoint - 0xf000); + for (i = 0; i < count; i++) { + if (charmap == -1) + glyphs[i] = pFTC_CMapCache_Lookup(cmap_cache, fontface, charmap, codepoints[i]); + else { + UINT32 codepoint = codepoints[i]; + /* special handling for symbol fonts */ + if (codepoint < 0x100) codepoint += 0xf000; + glyphs[i] = pFTC_CMapCache_Lookup(cmap_cache, fontface, charmap, codepoint); + if (!glyphs[i]) + glyphs[i] = pFTC_CMapCache_Lookup(cmap_cache, fontface, charmap, codepoint - 0xf000); + } } LeaveCriticalSection(&freetype_cs); - - return glyph; } BOOL freetype_has_kerning_pairs(IDWriteFontFace2 *fontface) @@ -836,9 +838,10 @@ UINT16 freetype_get_glyphcount(IDWriteFontFace2 *fontface) return 0; } -UINT16 freetype_get_glyphindex(IDWriteFontFace2 *fontface, UINT32 codepoint, INT charmap) +void freetype_get_glyphs(IDWriteFontFace2 *fontface, INT charmap, UINT32 const *codepoints, UINT32 count, + UINT16 *glyphs) { - return 0; + memset(glyphs, 0, count * sizeof(*glyphs)); } BOOL freetype_has_kerning_pairs(IDWriteFontFace2 *fontface)
1
0
0
0
Nikolay Sivov : dwrite: Support optional glyph offsets for color runs.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: ce526d15ec1e5aef3d27627f615f91abe553d531 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ce526d15ec1e5aef3d27627f6…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue Feb 9 17:11:19 2016 +0300 dwrite: Support optional glyph offsets for color runs. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/font.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/dlls/dwrite/font.c b/dlls/dwrite/font.c index 6cea760..f350936 100644 --- a/dlls/dwrite/font.c +++ b/dlls/dwrite/font.c @@ -191,6 +191,8 @@ struct dwrite_colorglyphenum { UINT32 palette; /* palette index to get layer color from */ FLOAT *advances; /* original or measured advances for base glyphs */ FLOAT *color_advances; /* returned color run points to this */ + DWRITE_GLYPH_OFFSET *offsets; /* original offsets, or NULL */ + DWRITE_GLYPH_OFFSET *color_offsets; /* returned color run offsets, or NULL */ UINT16 *glyphindices; /* returned color run points to this */ struct dwrite_colorglyph *glyphs; /* current glyph color info */ BOOL has_regular_glyphs; /* TRUE if there's any glyph without a color */ @@ -4629,6 +4631,8 @@ static ULONG WINAPI colorglyphenum_Release(IDWriteColorGlyphRunEnumerator *iface if (!ref) { heap_free(This->advances); heap_free(This->color_advances); + heap_free(This->offsets); + heap_free(This->color_offsets); heap_free(This->glyphindices); heap_free(This->glyphs); if (This->colr.context) @@ -4672,6 +4676,8 @@ static BOOL colorglyphenum_build_color_run(struct dwrite_colorglyphenum *glyphen else glyphenum->glyphindices[g] = 1; glyphenum->color_advances[g] = glyphenum->advances[g]; + if (glyphenum->color_offsets) + glyphenum->color_offsets[g] = glyphenum->offsets[g]; } colorrun->baselineOriginX = glyphenum->origin_x + get_glyph_origin(glyphenum, first_glyph); @@ -4716,6 +4722,9 @@ static BOOL colorglyphenum_build_color_run(struct dwrite_colorglyphenum *glyphen } glyphenum->glyphindices[index] = glyphenum->glyphs[g].glyph; + /* offsets are relative to glyph origin, nothing to fix up */ + if (glyphenum->color_offsets) + glyphenum->color_offsets[index] = glyphenum->offsets[g]; opentype_colr_next_glyph(glyphenum->colr.data, glyphenum->glyphs + g); if (index) glyphenum->color_advances[index-1] += advance_adj; @@ -4846,10 +4855,15 @@ HRESULT create_colorglyphenum(FLOAT originX, FLOAT originY, const DWRITE_GLYPH_R colorglyphenum->advances = heap_alloc(run->glyphCount * sizeof(FLOAT)); colorglyphenum->color_advances = heap_alloc(run->glyphCount * sizeof(FLOAT)); colorglyphenum->glyphindices = heap_alloc(run->glyphCount * sizeof(UINT16)); + if (run->glyphOffsets) { + colorglyphenum->offsets = heap_alloc(run->glyphCount * sizeof(*colorglyphenum->offsets)); + colorglyphenum->color_offsets = heap_alloc(run->glyphCount * sizeof(*colorglyphenum->color_offsets)); + memcpy(colorglyphenum->offsets, run->glyphOffsets, run->glyphCount * sizeof(*run->glyphOffsets)); + } colorglyphenum->colorrun.glyphRun.glyphIndices = colorglyphenum->glyphindices; colorglyphenum->colorrun.glyphRun.glyphAdvances = colorglyphenum->color_advances; - colorglyphenum->colorrun.glyphRun.glyphOffsets = NULL; /* FIXME */ + colorglyphenum->colorrun.glyphRun.glyphOffsets = colorglyphenum->color_offsets; colorglyphenum->colorrun.glyphRunDescription = NULL; /* FIXME */ if (run->glyphAdvances)
1
0
0
0
Nikolay Sivov : dwrite/tests: Added a drawing test for run reordering case.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: 79fa94c3c288cca7698a858b63d8470bda197595 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=79fa94c3c288cca7698a858b6…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue Feb 9 17:11:18 2016 +0300 dwrite/tests: Added a drawing test for run reordering case. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/tests/layout.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/dlls/dwrite/tests/layout.c b/dlls/dwrite/tests/layout.c index 04e3ee0..89a6305 100644 --- a/dlls/dwrite/tests/layout.c +++ b/dlls/dwrite/tests/layout.c @@ -1439,8 +1439,18 @@ static const struct drawcall_entry draw_single_run_seq[] = { { DRAW_LAST_KIND } }; +static const struct drawcall_entry draw_reordered_run_seq[] = { + { DRAW_GLYPHRUN, {'1','2','3','-','5','2',0} }, + { DRAW_GLYPHRUN, {0x64a,0x64f,0x633,0x627,0x648,0x650,0x64a,0} }, + { DRAW_GLYPHRUN, {'7','1',0} }, + { DRAW_GLYPHRUN, {'.',0} }, + { DRAW_LAST_KIND } +}; + static void test_Draw(void) { + static const WCHAR str3W[] = {'1','2','3','-','5','2',0x64a,0x64f,0x633,0x627,0x648,0x650, + 0x64a,'7','1','.',0}; static const WCHAR strW[] = {'s','t','r','i','n','g',0}; static const WCHAR str2W[] = {0x202a,0x202c,'a','b',0}; static const WCHAR ruW[] = {'r','u',0}; @@ -1623,6 +1633,22 @@ static void test_Draw(void) IDWriteTextLayout_Release(layout); IDWriteInlineObject_Release(inlineobj); + + /* text that triggers bidi run reordering */ + hr = IDWriteFactory_CreateTextLayout(factory, str3W, lstrlenW(str3W), format, 1000.0f, 100.0f, &layout); + ok(hr == S_OK, "got 0x%08x\n", hr); + + ctxt.gdicompat = FALSE; + ctxt.use_gdi_natural = FALSE; + ctxt.snapping_disabled = TRUE; + + flush_sequence(sequences, RENDERER_ID); + hr = IDWriteTextLayout_Draw(layout, &ctxt, &testrenderer, 0.0f, 0.0f); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok_sequence(sequences, RENDERER_ID, draw_reordered_run_seq, "draw test 11", FALSE); + + IDWriteTextLayout_Release(layout); + IDWriteTextFormat_Release(format); IDWriteFactory_Release(factory); }
1
0
0
0
Rafał Harabień : msvcr120: Implement atoll, _atoll_l, _wtoll, _wtoll_l.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: ad9ab7c40b219836cbf36d9c7355557e3c54395e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ad9ab7c40b219836cbf36d9c7…
Author: Rafał Harabień <rafalh1992(a)o2.pl> Date: Tue Feb 9 14:29:07 2016 +0100 msvcr120: Implement atoll, _atoll_l, _wtoll, _wtoll_l. Signed-off-by: Rafał Harabień <rafalh1992(a)o2.pl> Signed-off-by: Piotr Caban <piotr(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- .../api-ms-win-crt-convert-l1-1-0.spec | 8 ++++---- dlls/msvcr120/msvcr120.spec | 8 ++++---- dlls/msvcr120_app/msvcr120_app.spec | 8 ++++---- dlls/msvcrt/string.c | 16 ++++++++++++++++ dlls/msvcrt/wcs.c | 16 ++++++++++++++++ dlls/ucrtbase/ucrtbase.spec | 8 ++++---- 6 files changed, 48 insertions(+), 16 deletions(-) diff --git a/dlls/api-ms-win-crt-convert-l1-1-0/api-ms-win-crt-convert-l1-1-0.spec b/dlls/api-ms-win-crt-convert-l1-1-0/api-ms-win-crt-convert-l1-1-0.spec index 319bff5..6ac93d3 100644 --- a/dlls/api-ms-win-crt-convert-l1-1-0/api-ms-win-crt-convert-l1-1-0.spec +++ b/dlls/api-ms-win-crt-convert-l1-1-0/api-ms-win-crt-convert-l1-1-0.spec @@ -10,7 +10,7 @@ @ stub _atol_l @ cdecl _atoldbl(ptr str) ucrtbase._atoldbl @ stub _atoldbl_l -@ stub _atoll_l +@ cdecl -ret64 _atoll_l(str ptr) ucrtbase._atoll_l @ cdecl _ecvt(double long ptr ptr) ucrtbase._ecvt @ cdecl _ecvt_s(str long double long ptr ptr) ucrtbase._ecvt_s @ cdecl _fcvt(double long ptr ptr) ucrtbase._fcvt @@ -75,12 +75,12 @@ @ cdecl _wtoi_l(wstr ptr) ucrtbase._wtoi_l @ cdecl _wtol(wstr) ucrtbase._wtol @ cdecl _wtol_l(wstr ptr) ucrtbase._wtol_l -@ stub _wtoll -@ stub _wtoll_l +@ cdecl -ret64 _wtoll(wstr) ucrtbase._wtoll +@ cdecl -ret64 _wtoll_l(wstr ptr) ucrtbase._wtoll_l @ cdecl atof(str) ucrtbase.atof @ cdecl atoi(str) ucrtbase.atoi @ cdecl atol(str) ucrtbase.atol -@ stub atoll +@ cdecl -ret64 atoll(str) ucrtbase.atoll @ cdecl btowc(long) ucrtbase.btowc @ stub c16rtomb @ stub c32rtomb diff --git a/dlls/msvcr120/msvcr120.spec b/dlls/msvcr120/msvcr120.spec index 9931820..5f6533c 100644 --- a/dlls/msvcr120/msvcr120.spec +++ b/dlls/msvcr120/msvcr120.spec @@ -1040,7 +1040,7 @@ @ stub _atol_l @ cdecl _atoldbl(ptr str) MSVCRT__atoldbl @ stub _atoldbl_l -@ stub _atoll_l +@ cdecl -ret64 _atoll_l(str ptr) MSVCRT__atoll_l @ cdecl _beep(long long) MSVCRT__beep @ cdecl _beginthread(ptr long ptr) @ cdecl _beginthreadex(ptr long ptr ptr long ptr) @@ -1999,8 +1999,8 @@ @ cdecl _wtoi_l(wstr ptr) MSVCRT__wtoi_l @ cdecl _wtol(wstr) MSVCRT__wtol @ cdecl _wtol_l(wstr ptr) MSVCRT__wtol_l -@ stub _wtoll -@ stub _wtoll_l +@ cdecl -ret64 _wtoll(wstr) MSVCRT__wtoll +@ cdecl -ret64 _wtoll_l(wstr ptr) MSVCRT__wtoll_l @ cdecl _wunlink(wstr) MSVCRT__wunlink @ cdecl _wutime32(wstr ptr) @ cdecl _wutime64(wstr ptr) @@ -2032,7 +2032,7 @@ @ cdecl atof(str) MSVCRT_atof @ cdecl atoi(str) MSVCRT_atoi @ cdecl atol(str) ntdll.atol -@ stub atoll +@ cdecl -ret64 atoll(str) MSVCRT_atoll @ cdecl bsearch(ptr ptr long long ptr) MSVCRT_bsearch @ cdecl bsearch_s(ptr ptr long long ptr ptr) MSVCRT_bsearch_s @ cdecl btowc(long) MSVCRT_btowc diff --git a/dlls/msvcr120_app/msvcr120_app.spec b/dlls/msvcr120_app/msvcr120_app.spec index 50066ed..f938eff 100644 --- a/dlls/msvcr120_app/msvcr120_app.spec +++ b/dlls/msvcr120_app/msvcr120_app.spec @@ -1011,7 +1011,7 @@ @ stub _atol_l @ cdecl _atoldbl(ptr str) msvcr120._atoldbl @ stub _atoldbl_l -@ stub _atoll_l +@ cdecl -ret64 _atoll_l(str ptr) msvcr120._atoll_l @ cdecl _byteswap_uint64(int64) msvcr120._byteswap_uint64 @ cdecl _byteswap_ulong(long) msvcr120._byteswap_ulong @ cdecl _byteswap_ushort(long) msvcr120._byteswap_ushort @@ -1665,8 +1665,8 @@ @ cdecl _wtoi_l(wstr ptr) msvcr120._wtoi_l @ cdecl _wtol(wstr) msvcr120._wtol @ cdecl _wtol_l(wstr ptr) msvcr120._wtol_l -@ stub _wtoll -@ stub _wtoll_l +@ cdecl -ret64 _wtoll(wstr) msvcr120._wtoll +@ cdecl -ret64 _wtoll_l(wstr ptr) msvcr120._wtoll_l @ cdecl _wunlink(wstr) msvcr120._wunlink @ cdecl _wutime32(wstr ptr) msvcr120._wutime32 @ cdecl _wutime64(wstr ptr) msvcr120._wutime64 @@ -1698,7 +1698,7 @@ @ cdecl atof(str) msvcr120.atof @ cdecl atoi(str) msvcr120.atoi @ cdecl atol(str) msvcr120.atol -@ stub atoll +@ cdecl -ret64 atoll(str) msvcr120.atoll @ cdecl bsearch(ptr ptr long long ptr) msvcr120.bsearch @ cdecl bsearch_s(ptr ptr long long ptr ptr) msvcr120.bsearch_s @ cdecl btowc(long) msvcr120.btowc diff --git a/dlls/msvcrt/string.c b/dlls/msvcrt/string.c index f44ac52..59da5bd 100644 --- a/dlls/msvcrt/string.c +++ b/dlls/msvcrt/string.c @@ -1018,6 +1018,22 @@ int CDECL MSVCRT_atoi(const char *str) #endif /****************************************************************** + * _atoll_l (MSVCR120.@) + */ +MSVCRT_longlong CDECL MSVCRT__atoll_l(const char* str, MSVCRT__locale_t locale) +{ + return MSVCRT_strtoi64_l(str, NULL, 10, locale); +} + +/****************************************************************** + * atoll (MSVCR120.@) + */ +MSVCRT_longlong CDECL MSVCRT_atoll(const char* str) +{ + return MSVCRT__atoll_l(str, NULL); +} + +/****************************************************************** * _strtol_l (MSVCRT.@) */ MSVCRT_long CDECL MSVCRT__strtol_l(const char* nptr, diff --git a/dlls/msvcrt/wcs.c b/dlls/msvcrt/wcs.c index 56625e9..b6946a3 100644 --- a/dlls/msvcrt/wcs.c +++ b/dlls/msvcrt/wcs.c @@ -2083,6 +2083,22 @@ MSVCRT_long __cdecl MSVCRT__wtol(const MSVCRT_wchar_t *str) } /********************************************************************* + * _wtoll_l (MSVCR120.@) + */ +MSVCRT_longlong __cdecl MSVCRT__wtoll_l(const MSVCRT_wchar_t *str, MSVCRT__locale_t locale) +{ + return MSVCRT__wcstoi64_l(str, NULL, 10, locale); +} + +/********************************************************************* + * _wtoll (MSVCR120.@) + */ +MSVCRT_longlong __cdecl MSVCRT__wtoll(const MSVCRT_wchar_t *str) +{ + return MSVCRT__wtoll_l(str, NULL); +} + +/********************************************************************* * _wcstoui64_l (MSVCRT.@) * * FIXME: locale parameter is ignored diff --git a/dlls/ucrtbase/ucrtbase.spec b/dlls/ucrtbase/ucrtbase.spec index e809596..801cb99 100644 --- a/dlls/ucrtbase/ucrtbase.spec +++ b/dlls/ucrtbase/ucrtbase.spec @@ -201,7 +201,7 @@ @ stub _atol_l @ cdecl _atoldbl(ptr str) MSVCRT__atoldbl @ stub _atoldbl_l -@ stub _atoll_l +@ cdecl -ret64 _atoll_l(str ptr) MSVCRT__atoll_l @ cdecl _beep(long long) MSVCRT__beep @ cdecl _beginthread(ptr long ptr) @ cdecl _beginthreadex(ptr long ptr ptr long ptr) @@ -2141,8 +2141,8 @@ @ cdecl _wtoi_l(wstr ptr) MSVCRT__wtoi_l @ cdecl _wtol(wstr) MSVCRT__wtol @ cdecl _wtol_l(wstr ptr) MSVCRT__wtol_l -@ stub _wtoll -@ stub _wtoll_l +@ cdecl -ret64 _wtoll(wstr) MSVCRT__wtoll +@ cdecl -ret64 _wtoll_l(wstr ptr) MSVCRT__wtoll_l @ cdecl _wunlink(wstr) MSVCRT__wunlink @ cdecl _wutime32(wstr ptr) @ cdecl _wutime64(wstr ptr) @@ -2173,7 +2173,7 @@ @ cdecl atof(str) MSVCRT_atof @ cdecl atoi(str) MSVCRT_atoi @ cdecl atol(str) ntdll.atol -@ stub atoll +@ cdecl -ret64 atoll(str) MSVCRT_atoll @ cdecl bsearch(ptr ptr long long ptr) MSVCRT_bsearch @ cdecl bsearch_s(ptr ptr long long ptr ptr) MSVCRT_bsearch_s @ cdecl btowc(long) MSVCRT_btowc
1
0
0
0
Aric Stewart : ntoskrnl.exe: Implement IoGetDeviceProperty for DevicePropertyPhysicalDeviceObjectName.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: 5dc8dc829af667ab266c6150b9d43b18f991498e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5dc8dc829af667ab266c6150b…
Author: Aric Stewart <aric(a)codeweavers.com> Date: Fri Jan 29 09:44:36 2016 -0600 ntoskrnl.exe: Implement IoGetDeviceProperty for DevicePropertyPhysicalDeviceObjectName. Signed-off-by: Aric Stewart <aric(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntoskrnl.exe/ntoskrnl.c | 39 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 37 insertions(+), 2 deletions(-) diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c index 04f0198..7e043be 100644 --- a/dlls/ntoskrnl.exe/ntoskrnl.c +++ b/dlls/ntoskrnl.exe/ntoskrnl.c @@ -1040,9 +1040,44 @@ PDEVICE_OBJECT WINAPI IoGetAttachedDevice( PDEVICE_OBJECT device ) NTSTATUS WINAPI IoGetDeviceProperty( DEVICE_OBJECT *device, DEVICE_REGISTRY_PROPERTY device_property, ULONG buffer_length, PVOID property_buffer, PULONG result_length ) { - FIXME( "%p %d %u %p %p: stub\n", device, device_property, buffer_length, + NTSTATUS status = STATUS_NOT_IMPLEMENTED; + TRACE( "%p %d %u %p %p\n", device, device_property, buffer_length, property_buffer, result_length ); - return STATUS_NOT_IMPLEMENTED; + switch (device_property) + { + case DevicePropertyPhysicalDeviceObjectName: + { + ULONG used_len, len = buffer_length + sizeof(OBJECT_NAME_INFORMATION); + OBJECT_NAME_INFORMATION *name = HeapAlloc(GetProcessHeap(), 0, len); + + status = NtQueryObject(device->Reserved, ObjectNameInformation, name, len, &used_len); + if (status == STATUS_SUCCESS) + { + /* Ensure room for NULL termination */ + if (buffer_length >= name->Name.MaximumLength) + memcpy(property_buffer, name->Name.Buffer, name->Name.MaximumLength); + else + status = STATUS_BUFFER_TOO_SMALL; + *result_length = name->Name.MaximumLength; + } + else + { + if (status == STATUS_INFO_LENGTH_MISMATCH || + status == STATUS_BUFFER_OVERFLOW) + { + status = STATUS_BUFFER_TOO_SMALL; + *result_length = used_len - sizeof(OBJECT_NAME_INFORMATION); + } + else + *result_length = 0; + } + HeapFree(GetProcessHeap(), 0, name); + break; + } + default: + FIXME("unhandled property %d\n", device_property); + } + return status; }
1
0
0
0
Józef Kucia : wined3d: Extend support for typeless formats.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: b8387e69096b81db8ba9e33f6bb7bfb02dabfcf2 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=b8387e69096b81db8ba9e33f6…
Author: Józef Kucia <jkucia(a)codeweavers.com> Date: Tue Feb 9 11:24:44 2016 +0100 wined3d: Extend support for typeless formats. Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/utils.c | 97 ++++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 90 insertions(+), 7 deletions(-) diff --git a/dlls/wined3d/utils.c b/dlls/wined3d/utils.c index f49b40e..340cd87 100644 --- a/dlls/wined3d/utils.c +++ b/dlls/wined3d/utils.c @@ -153,16 +153,59 @@ static const struct wined3d_format_channels formats[] = {WINED3DFMT_R16, 16, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0}, {WINED3DFMT_AL16, 0, 0, 0, 16, 0, 0, 0, 16, 4, 0, 0}, /* Typeless */ - {WINED3DFMT_R8_TYPELESS, 8, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, - {WINED3DFMT_R8G8_TYPELESS, 8, 8, 0, 0, 0, 8, 0, 0, 2, 0, 0}, + {WINED3DFMT_R32G32B32A32_TYPELESS, 32, 32, 32, 32, 0, 32, 64, 96, 16, 0, 0}, + {WINED3DFMT_R32G32B32_TYPELESS, 32, 32, 32, 0, 0, 32, 64, 0, 12, 0, 0}, + {WINED3DFMT_R16G16B16A16_TYPELESS, 16, 16, 16, 16, 0, 16, 32, 48, 8, 0, 0}, + {WINED3DFMT_R32G32_TYPELESS, 32, 32, 0, 0, 0, 32, 0, 0, 8, 0, 0}, + {WINED3DFMT_R32G8X24_TYPELESS, 0, 0, 0, 0, 0, 0, 0, 0, 8, 32, 8}, + {WINED3DFMT_R10G10B10A2_TYPELESS, 10, 10, 10, 2, 0, 10, 20, 30, 4, 0, 0}, {WINED3DFMT_R8G8B8A8_TYPELESS, 8, 8, 8, 8, 0, 8, 16, 24, 4, 0, 0}, - {WINED3DFMT_R16_TYPELESS, 16, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0}, {WINED3DFMT_R16G16_TYPELESS, 16, 16, 0, 0, 0, 16, 0, 0, 4, 0, 0}, - {WINED3DFMT_R16G16B16A16_TYPELESS, 16, 16, 16, 16, 0, 16, 32, 48, 8, 0, 0}, {WINED3DFMT_R32_TYPELESS, 32, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0}, - {WINED3DFMT_R32G32_TYPELESS, 32, 32, 0, 0, 0, 32, 0, 0, 8, 0, 0}, - {WINED3DFMT_R32G32B32_TYPELESS, 32, 32, 32, 0, 0, 32, 64, 0, 12, 0, 0}, - {WINED3DFMT_R32G32B32A32_TYPELESS, 32, 32, 32, 32, 0, 32, 64, 96, 16, 0, 0}, + {WINED3DFMT_R24G8_TYPELESS, 0, 0, 0, 0, 0, 0, 0, 0, 4, 24, 8}, + {WINED3DFMT_R8G8_TYPELESS, 8, 8, 0, 0, 0, 8, 0, 0, 2, 0, 0}, + {WINED3DFMT_R16_TYPELESS, 16, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0}, + {WINED3DFMT_R8_TYPELESS, 8, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, + {WINED3DFMT_BC1_TYPELESS, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, + {WINED3DFMT_BC2_TYPELESS, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, + {WINED3DFMT_BC3_TYPELESS, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, + {WINED3DFMT_BC5_TYPELESS, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, +}; + +struct wined3d_format_class_info +{ + enum wined3d_format_id id; + enum wined3d_format_id typeless_id; +}; + +/** + * The last entry for a given typeless format defines its internal format. + */ +static const struct wined3d_format_class_info format_class_info[] = +{ + {WINED3DFMT_R32G32B32A32_UINT, WINED3DFMT_R32G32B32A32_TYPELESS}, + {WINED3DFMT_R32G32B32A32_SINT, WINED3DFMT_R32G32B32A32_TYPELESS}, + {WINED3DFMT_R32G32B32A32_FLOAT, WINED3DFMT_R32G32B32A32_TYPELESS}, + {WINED3DFMT_R32G32B32_FLOAT, WINED3DFMT_R32G32B32_TYPELESS}, + {WINED3DFMT_R16G16B16A16_UNORM, WINED3DFMT_R16G16B16A16_TYPELESS}, + {WINED3DFMT_R16G16B16A16_FLOAT, WINED3DFMT_R16G16B16A16_TYPELESS}, + {WINED3DFMT_R32G32_FLOAT, WINED3DFMT_R32G32_TYPELESS}, + {WINED3DFMT_R10G10B10A2_UNORM, WINED3DFMT_R10G10B10A2_TYPELESS}, + {WINED3DFMT_R8G8B8A8_UNORM_SRGB, WINED3DFMT_R8G8B8A8_TYPELESS}, + {WINED3DFMT_R8G8B8A8_UNORM, WINED3DFMT_R8G8B8A8_TYPELESS}, + {WINED3DFMT_R16G16_UNORM, WINED3DFMT_R16G16_TYPELESS}, + {WINED3DFMT_R16G16_FLOAT, WINED3DFMT_R16G16_TYPELESS}, + {WINED3DFMT_R32_FLOAT, WINED3DFMT_R32_TYPELESS}, + {WINED3DFMT_D24_UNORM_S8_UINT, WINED3DFMT_R24G8_TYPELESS}, + {WINED3DFMT_R8G8_UNORM, WINED3DFMT_R8G8_TYPELESS}, + {WINED3DFMT_R16_FLOAT, WINED3DFMT_R16_TYPELESS}, + {WINED3DFMT_R8_UNORM, WINED3DFMT_R8_TYPELESS}, + {WINED3DFMT_BC1_UNORM_SRGB, WINED3DFMT_BC1_TYPELESS}, + {WINED3DFMT_BC1_UNORM, WINED3DFMT_BC1_TYPELESS}, + {WINED3DFMT_BC2_UNORM_SRGB, WINED3DFMT_BC2_TYPELESS}, + {WINED3DFMT_BC2_UNORM, WINED3DFMT_BC2_TYPELESS}, + {WINED3DFMT_BC3_UNORM_SRGB, WINED3DFMT_BC3_TYPELESS}, + {WINED3DFMT_BC3_UNORM, WINED3DFMT_BC3_TYPELESS}, }; struct wined3d_format_base_flags @@ -2853,6 +2896,45 @@ static BOOL init_format_vertex_info(struct wined3d_gl_info *gl_info) return TRUE; } +static BOOL init_typeless_formats(struct wined3d_gl_info *gl_info) +{ + unsigned int flags[WINED3D_GL_RES_TYPE_COUNT]; + unsigned int i, j; + + for (i = 0; i < ARRAY_SIZE(format_class_info); ++i) + { + struct wined3d_format *format, *typeless_format; + int fmt_idx = getFmtIdx(format_class_info[i].id); + int typeless_fmt_idx = getFmtIdx(format_class_info[i].typeless_id); + + if (fmt_idx == -1) + { + ERR("Format %s (%#x) not found.\n", + debug_d3dformat(format_class_info[i].id), + format_class_info[i].id); + return FALSE; + } + if (typeless_fmt_idx == -1) + { + ERR("Format %s (%#x) not found.\n", + debug_d3dformat(format_class_info[i].typeless_id), + format_class_info[i].typeless_id); + return FALSE; + } + + format = &gl_info->formats[fmt_idx]; + typeless_format = &gl_info->formats[typeless_fmt_idx]; + + memcpy(flags, typeless_format->flags, sizeof(flags)); + *typeless_format = *format; + typeless_format->id = format_class_info[i].typeless_id; + for (j = 0; j < ARRAY_SIZE(typeless_format->flags); ++j) + typeless_format->flags[j] |= flags[j]; + } + + return TRUE; +} + BOOL initPixelFormatsNoGL(struct wined3d_gl_info *gl_info) { if (!init_format_base_info(gl_info)) return FALSE; @@ -2881,6 +2963,7 @@ BOOL wined3d_adapter_init_format_info(struct wined3d_adapter *adapter, struct wi apply_format_fixups(adapter, gl_info); init_format_fbo_compat_info(ctx); init_format_filter_info(gl_info, adapter->driver_info.vendor); + if (!init_typeless_formats(gl_info)) goto fail; return TRUE;
1
0
0
0
Józef Kucia : wined3d: Add support for WINED3DFMT_R32G32B32A32_SINT format.
by Alexandre Julliard
09 Feb '16
09 Feb '16
Module: wine Branch: master Commit: 30da671cf0d97738eef6b824c4c89bfee4eafd0f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=30da671cf0d97738eef6b824c…
Author: Józef Kucia <jkucia(a)codeweavers.com> Date: Tue Feb 9 11:24:43 2016 +0100 wined3d: Add support for WINED3DFMT_R32G32B32A32_SINT format. Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/utils.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dlls/wined3d/utils.c b/dlls/wined3d/utils.c index d835bbe..f49b40e 100644 --- a/dlls/wined3d/utils.c +++ b/dlls/wined3d/utils.c @@ -137,6 +137,7 @@ static const struct wined3d_format_channels formats[] = {WINED3DFMT_R32G32_UINT, 32, 32, 0, 0, 0, 32, 0, 0, 8, 0, 0}, {WINED3DFMT_R32G32B32_UINT, 32, 32, 32, 0, 0, 32, 64, 0, 12, 0, 0}, {WINED3DFMT_R32G32B32A32_UINT, 32, 32, 32, 32, 0, 32, 64, 96, 16, 0, 0}, + {WINED3DFMT_R32G32B32A32_SINT, 32, 32, 32, 32, 0, 32, 64, 96, 16, 0, 0}, {WINED3DFMT_R16G16B16A16_SNORM, 16, 16, 16, 16, 0, 16, 32, 48, 8, 0, 0}, /* Vendor-specific formats */ {WINED3DFMT_ATI1N, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, @@ -201,6 +202,7 @@ static const struct wined3d_format_base_flags format_base_flags[] = {WINED3DFMT_R8G8B8A8_SINT, WINED3DFMT_FLAG_INTEGER}, {WINED3DFMT_R16_UINT, WINED3DFMT_FLAG_INTEGER}, {WINED3DFMT_R32G32B32A32_UINT, WINED3DFMT_FLAG_INTEGER}, + {WINED3DFMT_R32G32B32A32_SINT, WINED3DFMT_FLAG_INTEGER}, }; struct wined3d_format_block_info @@ -1320,6 +1322,10 @@ static const struct wined3d_format_texture_info format_texture_info[] = GL_RGBA_INTEGER, GL_UNSIGNED_INT, 0, WINED3DFMT_FLAG_TEXTURE, EXT_TEXTURE_INTEGER, NULL}, + {WINED3DFMT_R32G32B32A32_SINT, GL_RGBA32I, GL_RGBA32I, 0, + GL_RGBA_INTEGER, GL_INT, 0, + WINED3DFMT_FLAG_TEXTURE, + EXT_TEXTURE_INTEGER, NULL}, /* Vendor-specific formats */ {WINED3DFMT_ATI1N, GL_COMPRESSED_RED_RGTC1, GL_COMPRESSED_RED_RGTC1, 0, GL_RED, GL_UNSIGNED_BYTE, 0,
1
0
0
0
← Newer
1
...
49
50
51
52
53
54
55
...
76
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
69
70
71
72
73
74
75
76
Results per page:
10
25
50
100
200