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
May 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
4 participants
542 discussions
Start a n
N
ew thread
Paul Gofman : d3dx9: Add 'exp' preshader opcode.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 2925d6e6ec23e4fa9a2830b6318fdab8360540ee URL:
http://source.winehq.org/git/wine.git/?a=commit;h=2925d6e6ec23e4fa9a2830b63…
Author: Paul Gofman <gofmanp(a)gmail.com> Date: Mon May 2 18:38:27 2016 +0300 d3dx9: Add 'exp' preshader opcode. Signed-off-by: Paul Gofman <gofmanp(a)gmail.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dx9_36/preshader.c | 3 ++ dlls/d3dx9_36/tests/effect.c | 96 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 99 insertions(+) diff --git a/dlls/d3dx9_36/preshader.c b/dlls/d3dx9_36/preshader.c index 2287f15..a16c065 100644 --- a/dlls/d3dx9_36/preshader.c +++ b/dlls/d3dx9_36/preshader.c @@ -43,6 +43,7 @@ enum pres_ops PRESHADER_OP_SIN, PRESHADER_OP_COS, PRESHADER_OP_RSQ, + PRESHADER_OP_EXP, }; typedef double (*pres_op_func)(double *args, int n); @@ -80,6 +81,7 @@ static double pres_rsq(double *args, int n) else return 1.0 / sqrt(v); } +static double pres_exp(double *args, int n) {return pow(2.0, args[0]);} #define PRES_OPCODE_MASK 0x7ff00000 #define PRES_OPCODE_SHIFT 20 @@ -119,6 +121,7 @@ static const struct op_info pres_op_info[] = {0x108, "sin", 1, 0, pres_sin}, /* PRESHADER_OP_SIN */ {0x109, "cos", 1, 0, pres_cos}, /* PRESHADER_OP_COS */ {0x107, "rsq", 1, 0, pres_rsq}, /* PRESHADER_OP_RSQ */ + {0x105, "exp", 1, 0, pres_exp}, /* PRESHADER_OP_EXP */ }; enum pres_value_type diff --git a/dlls/d3dx9_36/tests/effect.c b/dlls/d3dx9_36/tests/effect.c index 9d58a80..aea3ded 100644 --- a/dlls/d3dx9_36/tests/effect.c +++ b/dlls/d3dx9_36/tests/effect.c @@ -3886,6 +3886,101 @@ static void test_effect_preshader(IDirect3DDevice9 *device) effect->lpVtbl->Release(effect); } +struct test_preshader_op_def +{ + const char *mnem; + unsigned int opcode; + unsigned int args_count; + unsigned int expected_result[4]; + D3DXVECTOR4 fvect1, fvect2; + unsigned int ulps; + BOOL todo[4]; +}; + +static void test_preshader_op(IDirect3DDevice9 *device, const DWORD *sample_effect_blob, + unsigned int sample_effect_blob_size, const struct test_preshader_op_def *test) +{ + static const struct + { + unsigned int pos; + unsigned int result_index; + } + blob_position[] = + { + {0, 0}, + {2468, 0}, + {2319, 2} + }; + DWORD *test_effect_blob; + HRESULT hr; + ID3DXEffect *effect; + D3DLIGHT9 light; + unsigned int i, passes_count; + float *v; + unsigned int op_pos, op_step; + D3DXHANDLE param; + + op_step = 2 + (test->args_count + 1) * 3; + op_pos = blob_position[test->args_count].pos; + + test_effect_blob = HeapAlloc(GetProcessHeap(), 0, sample_effect_blob_size); + memcpy(test_effect_blob, sample_effect_blob, sample_effect_blob_size); + for (i = 0; i < 4; ++i) + test_effect_blob[op_pos + i * op_step] = test->opcode; + + hr = D3DXCreateEffect(device, test_effect_blob, sample_effect_blob_size, + NULL, NULL, 0, NULL, &effect, NULL); + ok(hr == D3D_OK, "Got result %#x.\n", hr); + hr = effect->lpVtbl->Begin(effect, &passes_count, 0); + ok(hr == D3D_OK, "Got result %#x.\n", hr); + + param = effect->lpVtbl->GetParameterByName(effect, NULL, "opvect1"); + ok(!!param, "GetParameterByName failed.\n"); + hr = effect->lpVtbl->SetVector(effect, param, &test->fvect1); + ok(hr == D3D_OK, "SetVector failed, hr %#x.\n", hr); + + if (test->args_count > 1) + { + param = effect->lpVtbl->GetParameterByName(effect, NULL, "opvect2"); + ok(!!param, "GetParameterByName failed.\n"); + hr = effect->lpVtbl->SetVector(effect, param, &test->fvect2); + ok(hr == D3D_OK, "SetVector failed, hr %#x.\n", hr); + } + + hr = effect->lpVtbl->BeginPass(effect, 0); + ok(hr == D3D_OK, "Got result %#x.\n", hr); + + hr = IDirect3DDevice9_GetLight(device, blob_position[test->args_count].result_index, &light); + ok(hr == D3D_OK, "Got result %#x.\n", hr); + v = &light.Diffuse.r; + for (i = 0; i < 4; ++i) + todo_wine_if(test->todo[i]) + ok(compare_float(v[i], ((float *)test->expected_result)[i], test->ulps), + "Operation %s, component %u, expected %#x (%g), got %#x (%g).\n", test->mnem, i, + test->expected_result[i], ((float *)test->expected_result)[i], ((unsigned int *)v)[i], v[i]); + + hr = effect->lpVtbl->EndPass(effect); + ok(hr == D3D_OK, "Got result %#x.\n", hr); + hr = effect->lpVtbl->End(effect); + ok(hr == D3D_OK, "Got result %#x.\n", hr); + effect->lpVtbl->Release(effect); + HeapFree(GetProcessHeap(), 0, test_effect_blob); +} + +static void test_effect_preshader_ops(IDirect3DDevice9 *device) +{ + static const struct test_preshader_op_def op_tests[] = + { + {"exp", 0x10500001, 1, {0x3f800000, 0x3f800000, 0x3e5edc66, 0x7f800000}, + {0.0f, -0.0f, -2.2f, 3.402823466e+38f}, {1.0f, 2.0f, -3.0f, 4.0f}}, + }; + unsigned int i; + + for (i = 0; i < ARRAY_SIZE(op_tests); ++i) + test_preshader_op(device, test_effect_preshader_effect_blob, sizeof(test_effect_preshader_effect_blob), + &op_tests[i]); +} + START_TEST(effect) { HWND wnd; @@ -3927,6 +4022,7 @@ START_TEST(effect) test_effect_compilation_errors(device); test_effect_states(device); test_effect_preshader(device); + test_effect_preshader_ops(device); count = IDirect3DDevice9_Release(device); ok(count == 0, "The device was not properly freed: refcount %u\n", count);
1
0
0
0
Alistair Leslie-Hughes : d3dcompiler: Add D3DLoadModule stub.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 5fb90db781cf5a0534716d57e186fe03fbb58169 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5fb90db781cf5a0534716d57e…
Author: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Date: Mon May 2 09:32:17 2016 +0000 d3dcompiler: Add D3DLoadModule stub. Signed-off-by: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dcompiler_43/compiler.c | 6 ++++++ dlls/d3dcompiler_47/d3dcompiler_47.spec | 2 +- include/d3dcompiler.h | 2 ++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/dlls/d3dcompiler_43/compiler.c b/dlls/d3dcompiler_43/compiler.c index 17e58fe..36e793e 100644 --- a/dlls/d3dcompiler_43/compiler.c +++ b/dlls/d3dcompiler_43/compiler.c @@ -792,3 +792,9 @@ HRESULT WINAPI D3DCompileFromFile(const WCHAR *filename, const D3D_SHADER_MACRO return E_NOTIMPL; } + +HRESULT WINAPI D3DLoadModule(const void *data, SIZE_T size, ID3D11Module **module) +{ + FIXME("data %p, size %lu, module %p stub!\n", data, size, module); + return E_NOTIMPL; +} diff --git a/dlls/d3dcompiler_47/d3dcompiler_47.spec b/dlls/d3dcompiler_47/d3dcompiler_47.spec index 9b2cb7d..05bc793 100644 --- a/dlls/d3dcompiler_47/d3dcompiler_47.spec +++ b/dlls/d3dcompiler_47/d3dcompiler_47.spec @@ -17,7 +17,7 @@ @ stdcall D3DGetInputSignatureBlob(ptr long ptr) @ stdcall D3DGetOutputSignatureBlob(ptr long ptr) @ stub D3DGetTraceInstructionOffsets -@ stub D3DLoadModule +@ stdcall D3DLoadModule(ptr long ptr) @ stdcall D3DPreprocess(ptr long str ptr ptr ptr ptr) @ stdcall D3DReadFileToBlob(wstr ptr) @ stdcall D3DReflect(ptr long ptr ptr) diff --git a/include/d3dcompiler.h b/include/d3dcompiler.h index 3f1fdb3..5d60792 100644 --- a/include/d3dcompiler.h +++ b/include/d3dcompiler.h @@ -120,6 +120,8 @@ typedef HRESULT (WINAPI *pD3DPreprocess)(const void *data, SIZE_T size, const ch const D3D_SHADER_MACRO *defines, ID3DInclude *include, ID3DBlob **shader, ID3DBlob **error_messages); +HRESULT WINAPI D3DLoadModule(const void *data, SIZE_T size, ID3D11Module **module); + #ifdef __cplusplus } #endif
1
0
0
0
Alistair Leslie-Hughes : d3d11shader.h: Add ID3D11Module, ID3D11ModuleInstance interfaces.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 8bc6d0153c8746af5b89e58b76b81c12f0ea9465 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=8bc6d0153c8746af5b89e58b7…
Author: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Date: Mon May 2 09:32:05 2016 +0000 d3d11shader.h: Add ID3D11Module, ID3D11ModuleInstance interfaces. Signed-off-by: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- include/d3d11shader.h | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/include/d3d11shader.h b/include/d3d11shader.h index 9ee78a8..f9c3b95 100644 --- a/include/d3d11shader.h +++ b/include/d3d11shader.h @@ -205,4 +205,45 @@ DECLARE_INTERFACE_(ID3D11ShaderReflection, IUnknown) }; #undef INTERFACE +DEFINE_GUID(IID_ID3D11ModuleInstance, 0x469e07f7, 0x45a, 0x48d5, 0xaa, 0x12, 0x68, 0xa4, 0x78, 0xcd, 0xf7, 0x5d); + +#define INTERFACE ID3D11ModuleInstance +DECLARE_INTERFACE_(ID3D11ModuleInstance, IUnknown) +{ + STDMETHOD(QueryInterface)(THIS_ REFIID iid, void **out) PURE; + STDMETHOD_(ULONG, AddRef)(THIS) PURE; + STDMETHOD_(ULONG, Release)(THIS) PURE; + + /* ID3D11ModuleInstance methods */ + STDMETHOD(BindConstantBuffer)(THIS_ UINT srcslot, UINT dstslot, UINT dstoffset) PURE; + STDMETHOD(BindConstantBufferByName)(THIS_ const char *name, UINT dstslot, UINT dstoffset) PURE; + + STDMETHOD(BindResource)(THIS_ UINT srcslot, UINT dstslot, UINT count) PURE; + STDMETHOD(BindResourceByName)(THIS_ const char *name, UINT dstslot, UINT count) PURE; + + STDMETHOD(BindSampler)(THIS_ UINT srcslot, UINT dstslot, UINT count) PURE; + STDMETHOD(BindSamplerByName)(THIS_ const char *name, UINT dstslot, UINT count) PURE; + + STDMETHOD(BindUnorderedAccessView)(THIS_ UINT srcslot, UINT dstslot, UINT count) PURE; + STDMETHOD(BindUnorderedAccessViewByName)(THIS_ const char *name, UINT dstslot, UINT count) PURE; + + STDMETHOD(BindResourceAsUnorderedAccessView)(THIS_ UINT srcslot, UINT dstslot, UINT count) PURE; + STDMETHOD(BindResourceAsUnorderedAccessViewByName)(THIS_ const char *name, UINT dstslot, UINT count) PURE; +}; +#undef INTERFACE + +DEFINE_GUID(IID_ID3D11Module, 0xcac701ee, 0x80fc, 0x4122, 0x82, 0x42, 0x10, 0xb3, 0x9c, 0x8c, 0xec, 0x34); + +#define INTERFACE ID3D11Module +DECLARE_INTERFACE_(ID3D11Module, IUnknown) +{ + STDMETHOD(QueryInterface)(THIS_ REFIID iid, void **out) PURE; + STDMETHOD_(ULONG, AddRef)(THIS) PURE; + STDMETHOD_(ULONG, Release)(THIS) PURE; + + /* ID3D11Module methods */ + STDMETHOD(CreateInstance)(THIS_ const char *instnamespace, ID3D11ModuleInstance **moduleinstance) PURE; +}; +#undef INTERFACE + #endif
1
0
0
0
Hugh McMaster : reg: Output line break before displaying query output.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 7b9a1a355fe64b540a35a03dfbd8a38f20b019ff URL:
http://source.winehq.org/git/wine.git/?a=commit;h=7b9a1a355fe64b540a35a03df…
Author: Hugh McMaster <hugh.mcmaster(a)outlook.com> Date: Mon May 2 12:06:33 2016 +0000 reg: Output line break before displaying query output. This matches Windows' behaviour. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/reg/reg.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/programs/reg/reg.c b/programs/reg/reg.c index df3b453..7852e74 100644 --- a/programs/reg/reg.c +++ b/programs/reg/reg.c @@ -833,6 +833,7 @@ static int reg_query(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, BOOL { WCHAR *p; HKEY root, key; + WCHAR newlineW[] = {'\n',0}; int ret; if (!sane_path(key_name)) @@ -860,6 +861,8 @@ static int reg_query(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, BOOL return 1; } + output_string(newlineW); + if (value_name || value_empty) { ret = query_value(key, value_name, key_name, recurse);
1
0
0
0
Hugh McMaster : reg: Output the number of matches when querying the registry recursively.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 43875a7fae6fa7b1621257969b9057fab5a52cfb URL:
http://source.winehq.org/git/wine.git/?a=commit;h=43875a7fae6fa7b1621257969…
Author: Hugh McMaster <hugh.mcmaster(a)outlook.com> Date: Mon May 2 12:06:23 2016 +0000 reg: Output the number of matches when querying the registry recursively. Signed-off-by: Hugh McMaster <hugh.mcmaster(a)outlook.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- po/ar.po | 4 ++++ po/bg.po | 4 ++++ po/ca.po | 4 ++++ po/cs.po | 4 ++++ po/da.po | 4 ++++ po/de.po | 4 ++++ po/el.po | 4 ++++ po/en.po | 4 ++++ po/en_US.po | 4 ++++ po/eo.po | 4 ++++ po/es.po | 4 ++++ po/fa.po | 4 ++++ po/fi.po | 4 ++++ po/fr.po | 4 ++++ po/he.po | 4 ++++ po/hi.po | 4 ++++ po/hr.po | 4 ++++ po/hu.po | 4 ++++ po/it.po | 4 ++++ po/ja.po | 4 ++++ po/ko.po | 4 ++++ po/lt.po | 4 ++++ po/ml.po | 4 ++++ po/nb_NO.po | 4 ++++ po/nl.po | 4 ++++ po/or.po | 4 ++++ po/pa.po | 4 ++++ po/pl.po | 4 ++++ po/pt_BR.po | 4 ++++ po/pt_PT.po | 4 ++++ po/rm.po | 4 ++++ po/ro.po | 4 ++++ po/ru.po | 4 ++++ po/sk.po | 4 ++++ po/sl.po | 4 ++++ po/sr_RS(a)cyrillic.po | 4 ++++ po/sr_RS(a)latin.po | 4 ++++ po/sv.po | 4 ++++ po/te.po | 4 ++++ po/th.po | 4 ++++ po/tr.po | 4 ++++ po/uk.po | 4 ++++ po/wa.po | 4 ++++ po/wine.pot | 4 ++++ po/zh_CN.po | 4 ++++ po/zh_TW.po | 4 ++++ programs/reg/reg.c | 7 +++++++ programs/reg/reg.h | 1 + programs/reg/reg.rc | 1 + 49 files changed, 193 insertions(+) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=43875a7fae6fa7b162125…
1
0
0
0
Ken Thomases : winemac: Implement the WGL_WINE_query_renderer extension.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 1df961bd3d1a5d4d4badfe364ca51e9f6cc88fd3 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1df961bd3d1a5d4d4badfe364…
Author: Ken Thomases <ken(a)codeweavers.com> Date: Fri Apr 29 01:59:30 2016 -0500 winemac: Implement the WGL_WINE_query_renderer extension. Signed-off-by: Ken Thomases <ken(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winemac.drv/opengl.c | 717 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 717 insertions(+) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=1df961bd3d1a5d4d4badf…
1
0
0
0
Nikolay Sivov : dwrite: Make IDWriteGdiInterop1 a part of a factory.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: dcfd21cfb2c3b30d2ce5592aaf58c31ef285b1d1 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=dcfd21cfb2c3b30d2ce5592aa…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue May 3 12:56:57 2016 +0300 dwrite: Make IDWriteGdiInterop1 a part of a factory. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/dwrite_private.h | 9 +++++++-- dlls/dwrite/gdiinterop.c | 31 ++++++------------------------- dlls/dwrite/main.c | 17 +++-------------- 3 files changed, 16 insertions(+), 41 deletions(-) diff --git a/dlls/dwrite/dwrite_private.h b/dlls/dwrite/dwrite_private.h index b852d3c..3dc29a1 100644 --- a/dlls/dwrite/dwrite_private.h +++ b/dlls/dwrite/dwrite_private.h @@ -111,6 +111,12 @@ static inline FLOAT get_scaled_advance_width(INT32 advance, FLOAT emSize, const return (FLOAT)advance * emSize / (FLOAT)metrics->designUnitsPerEm; } +struct gdiinterop +{ + IDWriteGdiInterop1 IDWriteGdiInterop1_iface; + IDWriteFactory3 *factory; +}; + struct textlayout_desc { IDWriteFactory3 *factory; @@ -146,8 +152,7 @@ extern HRESULT create_textformat(const WCHAR*,IDWriteFontCollection*,DWRITE_FONT extern HRESULT create_textlayout(const struct textlayout_desc*,IDWriteTextLayout**) DECLSPEC_HIDDEN; extern HRESULT create_trimmingsign(IDWriteFactory3*,IDWriteTextFormat*,IDWriteInlineObject**) DECLSPEC_HIDDEN; extern HRESULT create_typography(IDWriteTypography**) DECLSPEC_HIDDEN; -extern HRESULT create_gdiinterop(IDWriteFactory3*,IDWriteGdiInterop1**) DECLSPEC_HIDDEN; -extern void release_gdiinterop(IDWriteGdiInterop1*) DECLSPEC_HIDDEN; +extern void gdiinterop_init(struct gdiinterop*,IDWriteFactory3*) DECLSPEC_HIDDEN; extern HRESULT create_localizedstrings(IDWriteLocalizedStrings**) DECLSPEC_HIDDEN; extern HRESULT add_localizedstring(IDWriteLocalizedStrings*,const WCHAR*,const WCHAR*) DECLSPEC_HIDDEN; extern HRESULT clone_localizedstring(IDWriteLocalizedStrings *iface, IDWriteLocalizedStrings **strings) DECLSPEC_HIDDEN; diff --git a/dlls/dwrite/gdiinterop.c b/dlls/dwrite/gdiinterop.c index ede1a12..e14dfa8 100644 --- a/dlls/dwrite/gdiinterop.c +++ b/dlls/dwrite/gdiinterop.c @@ -2,7 +2,7 @@ * GDI Interop * * Copyright 2011 Huw Davies - * Copyright 2012, 2014 Nikolay Sivov for CodeWeavers + * Copyright 2012, 2014-2016 Nikolay Sivov for CodeWeavers * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -32,11 +32,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(dwrite); -struct gdiinterop { - IDWriteGdiInterop1 IDWriteGdiInterop1_iface; - IDWriteFactory3 *factory; -}; - struct dib_data { DWORD *ptr; int stride; @@ -929,24 +924,10 @@ static const struct IDWriteGdiInterop1Vtbl gdiinteropvtbl = { gdiinterop1_GetMatchingFontsByLOGFONT }; -HRESULT create_gdiinterop(IDWriteFactory3 *factory, IDWriteGdiInterop1 **ret) -{ - struct gdiinterop *This; - - *ret = NULL; - - This = heap_alloc(sizeof(struct gdiinterop)); - if (!This) return E_OUTOFMEMORY; - - This->IDWriteGdiInterop1_iface.lpVtbl = &gdiinteropvtbl; - This->factory = factory; - - *ret= &This->IDWriteGdiInterop1_iface; - return S_OK; -} - -void release_gdiinterop(IDWriteGdiInterop1 *iface) +void gdiinterop_init(struct gdiinterop *interop, IDWriteFactory3 *factory) { - struct gdiinterop *interop = impl_from_IDWriteGdiInterop1(iface); - heap_free(interop); + interop->IDWriteGdiInterop1_iface.lpVtbl = &gdiinteropvtbl; + /* Interop is a part of a factory, sharing its refcount. + GetGdiInterop() will AddRef() on every call. */ + interop->factory = factory; } diff --git a/dlls/dwrite/main.c b/dlls/dwrite/main.c index 12d8c72..0ecda11 100644 --- a/dlls/dwrite/main.c +++ b/dlls/dwrite/main.c @@ -525,7 +525,7 @@ struct dwritefactory { IDWriteFontCollection *system_collection; IDWriteFontCollection *eudc_collection; - IDWriteGdiInterop1 *gdiinterop; + struct gdiinterop interop; IDWriteFontFallback *fallback; IDWriteLocalFontFileLoader* localfontfileloader; @@ -586,8 +586,6 @@ static void release_dwritefactory(struct dwritefactory *factory) IDWriteFontCollection_Release(factory->system_collection); if (factory->eudc_collection) IDWriteFontCollection_Release(factory->eudc_collection); - if (factory->gdiinterop) - release_gdiinterop(factory->gdiinterop); if (factory->fallback) release_system_fontfallback(factory->fallback); heap_free(factory); @@ -1057,17 +1055,8 @@ static HRESULT WINAPI dwritefactory_GetGdiInterop(IDWriteFactory3 *iface, IDWrit TRACE("(%p)->(%p)\n", This, gdi_interop); - *gdi_interop = NULL; - - if (!This->gdiinterop) { - HRESULT hr = create_gdiinterop(iface, &This->gdiinterop); - if (FAILED(hr)) - return hr; - } - - *gdi_interop = (IDWriteGdiInterop*)This->gdiinterop; + *gdi_interop = (IDWriteGdiInterop*)&This->interop.IDWriteGdiInterop1_iface; IDWriteGdiInterop_AddRef(*gdi_interop); - return S_OK; } @@ -1489,7 +1478,7 @@ static void init_dwritefactory(struct dwritefactory *factory, DWRITE_FACTORY_TYP factory->localfontfileloader = NULL; factory->system_collection = NULL; factory->eudc_collection = NULL; - factory->gdiinterop = NULL; + gdiinterop_init(&factory->interop, &factory->IDWriteFactory3_iface); factory->fallback = NULL; list_init(&factory->collection_loaders);
1
0
0
0
Michael Stefaniuc : dwrite: Use SetRect() instead of open coding it.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 41729840e4085ac35b0ca47a512caf02b46afd0c URL:
http://source.winehq.org/git/wine.git/?a=commit;h=41729840e4085ac35b0ca47a5…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Tue May 3 11:32:33 2016 +0200 dwrite: Use SetRect() instead of open coding it. Signed-off-by: Michael Stefaniuc <mstefani(a)redhat.de> Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/freetype.c | 5 +---- dlls/dwrite/gdiinterop.c | 4 +--- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/dlls/dwrite/freetype.c b/dlls/dwrite/freetype.c index ec85579..d8afa69 100644 --- a/dlls/dwrite/freetype.c +++ b/dlls/dwrite/freetype.c @@ -603,10 +603,7 @@ void freetype_get_glyph_bbox(struct dwrite_glyphbitmap *bitmap) LeaveCriticalSection(&freetype_cs); /* flip Y axis */ - bitmap->bbox.left = bbox.xMin; - bitmap->bbox.right = bbox.xMax; - bitmap->bbox.top = -bbox.yMax; - bitmap->bbox.bottom = -bbox.yMin; + SetRect(&bitmap->bbox, bbox.xMin, -bbox.yMax, bbox.xMax, -bbox.yMin); } static BOOL freetype_get_aliased_glyph_bitmap(struct dwrite_glyphbitmap *bitmap, FT_Glyph glyph) diff --git a/dlls/dwrite/gdiinterop.c b/dlls/dwrite/gdiinterop.c index 84b463a..ede1a12 100644 --- a/dlls/dwrite/gdiinterop.c +++ b/dlls/dwrite/gdiinterop.c @@ -339,9 +339,7 @@ static HRESULT WINAPI rendertarget_DrawGlyphRun(IDWriteBitmapRenderTarget1 *ifac if (FAILED(hr)) return hr; - target.left = target.top = 0; - target.right = This->size.cx; - target.bottom = This->size.cy; + SetRect(&target, 0, 0, This->size.cx, This->size.cy); if (rendermode == DWRITE_RENDERING_MODE_OUTLINE) { static const XFORM identity = { 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f };
1
0
0
0
Michael Stefaniuc : dwrite/tests: Use SetRect() instead of open coding it.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: a5e2bd5902cdcead51614ddd1e9ff325be44af24 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=a5e2bd5902cdcead51614ddd1…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Tue May 3 11:09:53 2016 +0200 dwrite/tests: Use SetRect() instead of open coding it. Signed-off-by: Michael Stefaniuc <mstefani(a)redhat.de> Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/tests/font.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/dlls/dwrite/tests/font.c b/dlls/dwrite/tests/font.c index 5fb4121..299607c 100644 --- a/dlls/dwrite/tests/font.c +++ b/dlls/dwrite/tests/font.c @@ -4233,15 +4233,13 @@ static void test_CreateGlyphRunAnalysis(void) ok(hr == S_OK, "got 0x%08x\n", hr); ok(!IsRectEmpty(&rect), "got empty rect\n"); - rect.left = rect.top = 0; - rect.bottom = rect.right = 1; + SetRect(&rect, 0, 0, 1, 1); hr = IDWriteGlyphRunAnalysis_GetAlphaTextureBounds(analysis, DWRITE_TEXTURE_CLEARTYPE_3x1, &rect); ok(hr == S_OK, "got 0x%08x\n", hr); ok(IsRectEmpty(&rect), "unexpected empty rect\n"); } else { - rect.left = rect.top = 0; - rect.bottom = rect.right = 1; + SetRect(&rect, 0, 0, 1, 1); hr = IDWriteGlyphRunAnalysis_GetAlphaTextureBounds(analysis, DWRITE_TEXTURE_ALIASED_1x1, &rect); ok(hr == S_OK, "got 0x%08x\n", hr); ok(IsRectEmpty(&rect), "got empty rect\n");
1
0
0
0
Michael Stefaniuc : wmp/tests: Use SetRect() instead of open coding it.
by Alexandre Julliard
03 May '16
03 May '16
Module: wine Branch: master Commit: 365e2e9dbc7e8d4b164ef23291dd149493b7fcc6 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=365e2e9dbc7e8d4b164ef2329…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Tue May 3 11:08:55 2016 +0200 wmp/tests: Use SetRect() instead of open coding it. Signed-off-by: Michael Stefaniuc <mstefani(a)redhat.de> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wmp/tests/oleobj.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/dlls/wmp/tests/oleobj.c b/dlls/wmp/tests/oleobj.c index cc2f4fe..971a2fe 100644 --- a/dlls/wmp/tests/oleobj.c +++ b/dlls/wmp/tests/oleobj.c @@ -963,10 +963,7 @@ static void test_wmp(void) test_window(hwnd); - pos.left = 1; - pos.top = 2; - pos.right = 301; - pos.bottom = 312; + SetRect(&pos, 1, 2, 301, 312); hres = IOleInPlaceObject_SetObjectRects(ipobj, &pos, &pos); ok(hres == S_OK, "SetObjectRects failed: %08x\n", hres); GetClientRect(hwnd, &pos);
1
0
0
0
← Newer
1
...
46
47
48
49
50
51
52
...
55
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
Results per page:
10
25
50
100
200