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
July
June
May
April
March
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
July 2009
----- 2025 -----
July 2025
June 2025
May 2025
April 2025
March 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
1067 discussions
Start a n
N
ew thread
Henri Verbeet : d3d10: Merge parse_fx10_technique() and parse_fx10_technique_index().
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: c481e0a7d447cd0643f789054337e9080409a9df URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c481e0a7d447cd0643f789054…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Jul 14 11:17:40 2009 +0200 d3d10: Merge parse_fx10_technique() and parse_fx10_technique_index(). --- dlls/d3d10/d3d10_private.h | 1 - dlls/d3d10/effect.c | 82 ++++++++++++++++---------------------------- 2 files changed, 30 insertions(+), 53 deletions(-) diff --git a/dlls/d3d10/d3d10_private.h b/dlls/d3d10/d3d10_private.h index 400ea73..8bf9a8b 100644 --- a/dlls/d3d10/d3d10_private.h +++ b/dlls/d3d10/d3d10_private.h @@ -84,7 +84,6 @@ struct d3d10_effect_technique struct d3d10_effect *effect; char *name; - DWORD start; DWORD pass_count; struct d3d10_effect_pass *passes; }; diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c index 31ef070..1a7c7b9 100644 --- a/dlls/d3d10/effect.c +++ b/dlls/d3d10/effect.c @@ -161,40 +161,6 @@ static HRESULT parse_fx10_pass_index(struct d3d10_effect_pass *p, const char **p return S_OK; } -static HRESULT parse_fx10_technique_index(struct d3d10_effect_technique *t, const char **ptr) -{ - HRESULT hr = S_OK; - unsigned int i; - - read_dword(ptr, &t->start); - TRACE("Technique starts at offset %#x\n", t->start); - - read_dword(ptr, &t->pass_count); - TRACE("Technique has %u passes\n", t->pass_count); - - skip_dword_unknown(ptr, 1); - - t->passes = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, t->pass_count * sizeof(*t->passes)); - if (!t->passes) - { - ERR("Failed to allocate passes memory\n"); - return E_OUTOFMEMORY; - } - - for (i = 0; i < t->pass_count; ++i) - { - struct d3d10_effect_pass *p = &t->passes[i]; - - p->vtbl = &d3d10_effect_pass_vtbl; - p->technique = t; - - hr = parse_fx10_pass_index(p, ptr); - if (FAILED(hr)) break; - } - - return hr; -} - static char *copy_name(const char *ptr) { size_t name_len; @@ -398,35 +364,50 @@ static HRESULT parse_fx10_pass(struct d3d10_effect_pass *p, const char *data) return hr; } -static HRESULT parse_fx10_technique(struct d3d10_effect_technique *t, const char *data) +static HRESULT parse_fx10_technique(struct d3d10_effect_technique *t, const char **ptr, const char *data) { - HRESULT hr = S_OK; - const char *ptr; - size_t name_len; unsigned int i; + DWORD offset; - ptr = data + t->start; + read_dword(ptr, &offset); + TRACE("Technique name at offset %#x.\n", offset); - name_len = strlen(ptr) + 1; - t->name = HeapAlloc(GetProcessHeap(), 0, name_len); + t->name = copy_name(data + offset); if (!t->name) { - ERR("Failed to allocate name memory\n"); + ERR("Failed to copy name.\n"); return E_OUTOFMEMORY; } + TRACE("Technique name: %s.\n", t->name); - memcpy(t->name, ptr, name_len); - ptr += name_len; + read_dword(ptr, &t->pass_count); + TRACE("Technique has %u passes\n", t->pass_count); + + skip_dword_unknown(ptr, 1); - TRACE("technique name: %s\n", t->name); + t->passes = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, t->pass_count * sizeof(*t->passes)); + if (!t->passes) + { + ERR("Failed to allocate passes memory\n"); + return E_OUTOFMEMORY; + } for (i = 0; i < t->pass_count; ++i) { - hr = parse_fx10_pass(&t->passes[i], data); - if (FAILED(hr)) break; + struct d3d10_effect_pass *p = &t->passes[i]; + HRESULT hr; + + p->vtbl = &d3d10_effect_pass_vtbl; + p->technique = t; + + hr = parse_fx10_pass_index(p, ptr); + if (FAILED(hr)) return hr; + + hr = parse_fx10_pass(p, data); + if (FAILED(hr)) return hr; } - return hr; + return S_OK; } static HRESULT parse_fx10_local_buffer(struct d3d10_effect_local_buffer *l, const char **ptr, const char *data) @@ -498,10 +479,7 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d t->vtbl = &d3d10_effect_technique_vtbl; t->effect = e; - hr = parse_fx10_technique_index(t, &ptr); - if (FAILED(hr)) return hr; - - hr = parse_fx10_technique(t, data); + hr = parse_fx10_technique(t, &ptr, data); if (FAILED(hr)) return hr; }
1
0
0
0
Henri Verbeet : d3d10: Parse local buffer names.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: 34ab5431e810104aae13c847a29cfa6d617bcee0 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=34ab5431e810104aae13c847a…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Jul 14 11:17:39 2009 +0200 d3d10: Parse local buffer names. --- dlls/d3d10/d3d10_private.h | 1 + dlls/d3d10/effect.c | 51 ++++++++++++++++++++++++++++++++++++++++--- 2 files changed, 48 insertions(+), 4 deletions(-) diff --git a/dlls/d3d10/d3d10_private.h b/dlls/d3d10/d3d10_private.h index 40ad33e..400ea73 100644 --- a/dlls/d3d10/d3d10_private.h +++ b/dlls/d3d10/d3d10_private.h @@ -60,6 +60,7 @@ struct d3d10_effect_shader_variable struct d3d10_effect_local_buffer { + char *name; DWORD data_size; DWORD variable_count; }; diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c index 80fdcb0..31ef070 100644 --- a/dlls/d3d10/effect.c +++ b/dlls/d3d10/effect.c @@ -195,6 +195,24 @@ static HRESULT parse_fx10_technique_index(struct d3d10_effect_technique *t, cons return hr; } +static char *copy_name(const char *ptr) +{ + size_t name_len; + char *name; + + name_len = strlen(ptr) + 1; + name = HeapAlloc(GetProcessHeap(), 0, name_len); + if (!name) + { + ERR("Failed to allocate name memory.\n"); + return NULL; + } + + memcpy(name, ptr, name_len); + + return name; +} + static HRESULT shader_chunk_handler(const char *data, DWORD data_size, DWORD tag, void *ctx) { struct d3d10_effect_shader_variable *s = ctx; @@ -411,7 +429,7 @@ static HRESULT parse_fx10_technique(struct d3d10_effect_technique *t, const char return hr; } -static HRESULT parse_fx10_local_buffer(struct d3d10_effect_local_buffer *l, const char **ptr) +static HRESULT parse_fx10_local_buffer(struct d3d10_effect_local_buffer *l, const char **ptr, const char *data) { unsigned int i; DWORD offset; @@ -419,6 +437,14 @@ static HRESULT parse_fx10_local_buffer(struct d3d10_effect_local_buffer *l, cons read_dword(ptr, &offset); TRACE("Local buffer name at offset %#x.\n", offset); + l->name = copy_name(data + offset); + if (!l->name) + { + ERR("Failed to copy name.\n"); + return E_OUTOFMEMORY; + } + TRACE("Local buffer name: %s.\n", l->name); + read_dword(ptr, &l->data_size); TRACE("Local buffer data size: %#x.\n", l->data_size); @@ -461,7 +487,7 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d { struct d3d10_effect_local_buffer *l = &e->local_buffers[i]; - hr = parse_fx10_local_buffer(l, &ptr); + hr = parse_fx10_local_buffer(l, &ptr, data); if (FAILED(hr)) return hr; } @@ -651,6 +677,13 @@ static void d3d10_effect_technique_destroy(struct d3d10_effect_technique *t) } } +static void d3d10_effect_local_buffer_destroy(struct d3d10_effect_local_buffer *l) +{ + TRACE("local buffer %p.\n", l); + + HeapFree(GetProcessHeap(), 0, l->name); +} + /* IUnknown methods */ static HRESULT STDMETHODCALLTYPE d3d10_effect_QueryInterface(ID3D10Effect *iface, REFIID riid, void **object) @@ -690,16 +723,26 @@ static ULONG STDMETHODCALLTYPE d3d10_effect_Release(ID3D10Effect *iface) if (!refcount) { + unsigned int i; + if (This->techniques) { - unsigned int i; for (i = 0; i < This->technique_count; ++i) { d3d10_effect_technique_destroy(&This->techniques[i]); } HeapFree(GetProcessHeap(), 0, This->techniques); } - HeapFree(GetProcessHeap(), 0, This->local_buffers); + + if (This->local_buffers) + { + for (i = 0; i < This->local_buffer_count; ++i) + { + d3d10_effect_local_buffer_destroy(&This->local_buffers[i]); + } + HeapFree(GetProcessHeap(), 0, This->local_buffers); + } + ID3D10Device_Release(This->device); HeapFree(GetProcessHeap(), 0, This); }
1
0
0
0
Henri Verbeet : d3d10: Parse local buffers.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: 710b57a5aa1d23222462d9b63c267d0111f87637 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=710b57a5aa1d23222462d9b63…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Jul 14 11:17:38 2009 +0200 d3d10: Parse local buffers. --- dlls/d3d10/d3d10_private.h | 10 +++++++- dlls/d3d10/effect.c | 54 ++++++++++++++++++++++++++++++++++++++----- 2 files changed, 56 insertions(+), 8 deletions(-) diff --git a/dlls/d3d10/d3d10_private.h b/dlls/d3d10/d3d10_private.h index c5a74aa..40ad33e 100644 --- a/dlls/d3d10/d3d10_private.h +++ b/dlls/d3d10/d3d10_private.h @@ -58,6 +58,12 @@ struct d3d10_effect_shader_variable } shader; }; +struct d3d10_effect_local_buffer +{ + DWORD data_size; + DWORD variable_count; +}; + /* ID3D10EffectPass */ struct d3d10_effect_pass { @@ -91,7 +97,7 @@ struct d3d10_effect ID3D10Device *device; DWORD version; - DWORD localbuffers_count; + DWORD local_buffer_count; DWORD localobjects_count; DWORD sharedbuffers_count; DWORD sharedobjects_count; @@ -101,6 +107,8 @@ struct d3d10_effect DWORD blendstate_count; DWORD rasterizerstate_count; DWORD samplerstate_count; + + struct d3d10_effect_local_buffer *local_buffers; struct d3d10_effect_technique *techniques; }; diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c index 8316db8..80fdcb0 100644 --- a/dlls/d3d10/effect.c +++ b/dlls/d3d10/effect.c @@ -411,13 +411,44 @@ static HRESULT parse_fx10_technique(struct d3d10_effect_technique *t, const char return hr; } +static HRESULT parse_fx10_local_buffer(struct d3d10_effect_local_buffer *l, const char **ptr) +{ + unsigned int i; + DWORD offset; + + read_dword(ptr, &offset); + TRACE("Local buffer name at offset %#x.\n", offset); + + read_dword(ptr, &l->data_size); + TRACE("Local buffer data size: %#x.\n", l->data_size); + + skip_dword_unknown(ptr, 1); + + read_dword(ptr, &l->variable_count); + TRACE("Local buffer variable count: %#x.\n", l->variable_count); + + skip_dword_unknown(ptr, 2); + + for (i = 0; i < l->variable_count; ++i) + { + skip_dword_unknown(ptr, 7); + } + + return S_OK; +} + static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD data_size) { const char *ptr = data + e->index_offset; - HRESULT hr = S_OK; unsigned int i; + HRESULT hr; - skip_dword_unknown(&ptr, 6); + e->local_buffers = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, e->local_buffer_count * sizeof(*e->local_buffers)); + if (!e->local_buffers) + { + ERR("Failed to allocate local buffer memory.\n"); + return E_OUTOFMEMORY; + } e->techniques = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, e->technique_count * sizeof(*e->techniques)); if (!e->techniques) @@ -426,6 +457,14 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d return E_OUTOFMEMORY; } + for (i = 0; i < e->local_buffer_count; ++i) + { + struct d3d10_effect_local_buffer *l = &e->local_buffers[i]; + + hr = parse_fx10_local_buffer(l, &ptr); + if (FAILED(hr)) return hr; + } + for (i = 0; i < e->technique_count; ++i) { struct d3d10_effect_technique *t = &e->techniques[i]; @@ -434,13 +473,13 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d t->effect = e; hr = parse_fx10_technique_index(t, &ptr); - if (FAILED(hr)) break; + if (FAILED(hr)) return hr; hr = parse_fx10_technique(t, data); - if (FAILED(hr)) break; + if (FAILED(hr)) return hr; } - return hr; + return S_OK; } static HRESULT parse_fx10(struct d3d10_effect *e, const char *data, DWORD data_size) @@ -452,8 +491,8 @@ static HRESULT parse_fx10(struct d3d10_effect *e, const char *data, DWORD data_s read_dword(&ptr, &e->version); TRACE("Target: %#x\n", e->version); - read_dword(&ptr, &e->localbuffers_count); - TRACE("Localbuffers count: %u\n", e->localbuffers_count); + read_dword(&ptr, &e->local_buffer_count); + TRACE("Local buffer count: %u.\n", e->local_buffer_count); /* Number of variables in local buffers? */ read_dword(&ptr, &unknown); @@ -660,6 +699,7 @@ static ULONG STDMETHODCALLTYPE d3d10_effect_Release(ID3D10Effect *iface) } HeapFree(GetProcessHeap(), 0, This->techniques); } + HeapFree(GetProcessHeap(), 0, This->local_buffers); ID3D10Device_Release(This->device); HeapFree(GetProcessHeap(), 0, This); }
1
0
0
0
Henri Verbeet : d3d10: Add the ID3D10EffectMatrixVariable interface.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: 74ec910397c4d7905e54d49eabd87702cb4ccf3d URL:
http://source.winehq.org/git/wine.git/?a=commit;h=74ec910397c4d7905e54d49ea…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Jul 14 11:17:37 2009 +0200 d3d10: Add the ID3D10EffectMatrixVariable interface. --- include/d3d10effect.h | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 43 insertions(+), 0 deletions(-) diff --git a/include/d3d10effect.h b/include/d3d10effect.h index 37d4bd1..b9c5c08 100644 --- a/include/d3d10effect.h +++ b/include/d3d10effect.h @@ -203,6 +203,49 @@ DECLARE_INTERFACE_(ID3D10EffectConstantBuffer, ID3D10EffectVariable) }; #undef INTERFACE +DEFINE_GUID(IID_ID3D10EffectMatrixVariable, 0x50666c24, 0xb82f, 0x4eed, 0xa1, 0x72, 0x5b, 0x6e, 0x7e, 0x85, 0x22, 0xe0); + +#define INTERFACE ID3D10EffectMatrixVariable +DECLARE_INTERFACE_(ID3D10EffectMatrixVariable, ID3D10EffectVariable) +{ + /* ID3D10EffectVariable methods */ + STDMETHOD_(BOOL, IsValid)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectType *, GetType)(THIS) PURE; + STDMETHOD(GetDesc)(THIS_ D3D10_EFFECT_VARIABLE_DESC *desc) PURE; + STDMETHOD_(struct ID3D10EffectVariable *, GetAnnotationByIndex)(THIS_ UINT index) PURE; + STDMETHOD_(struct ID3D10EffectVariable *, GetAnnotationByName)(THIS_ LPCSTR name) PURE; + STDMETHOD_(struct ID3D10EffectVariable *, GetMemberByIndex)(THIS_ UINT index) PURE; + STDMETHOD_(struct ID3D10EffectVariable *, GetMemberByName)(THIS_ LPCSTR name) PURE; + STDMETHOD_(struct ID3D10EffectVariable *, GetMemberBySemantic)(THIS_ LPCSTR semantic) PURE; + STDMETHOD_(struct ID3D10EffectVariable *, GetElement)(THIS_ UINT index) PURE; + STDMETHOD_(struct ID3D10EffectConstantBuffer *, GetParentConstantBuffer)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectScalarVariable *, AsScalar)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectVectorVariable *, AsVector)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectMatrixVariable *, AsMatrix)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectStringVariable *, AsString)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectShaderResourceVariable *, AsShaderResource)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectRenderTargetViewVariable *, AsRenderTargetView)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectDepthStencilViewVariable *, AsDepthStencilView)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectConstantBuffer *, AsConstantBuffer)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectShaderVariable *, AsShader)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectBlendVariable *, AsBlend)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectDepthStencilVariable *, AsDepthStencil)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectRasterizerVariable *, AsRasterizer)(THIS) PURE; + STDMETHOD_(struct ID3D10EffectSamplerVariable *, AsSampler)(THIS) PURE; + STDMETHOD(SetRawValue)(THIS_ void *data, UINT offset, UINT count) PURE; + STDMETHOD(GetRawValue)(THIS_ void *data, UINT offset, UINT count) PURE; + /* ID3D10EffectMatrixVariable methods */ + STDMETHOD(SetMatrix)(THIS_ float *data) PURE; + STDMETHOD(GetMatrix)(THIS_ float *data) PURE; + STDMETHOD(SetMatrixArray)(THIS_ float *data, UINT offset, UINT count) PURE; + STDMETHOD(GetMatrixArray)(THIS_ float *data, UINT offset, UINT count) PURE; + STDMETHOD(SetMatrixTranspose)(THIS_ float *data) PURE; + STDMETHOD(GetMatrixTranspose)(THIS_ float *data) PURE; + STDMETHOD(SetMatrixTransposeArray)(THIS_ float *data, UINT offset, UINT count) PURE; + STDMETHOD(GetMatrixTransposeArray)(THIS_ float *data, UINT offset, UINT count) PURE; +}; +#undef INTERFACE + DEFINE_GUID(IID_ID3D10EffectTechnique, 0xdb122ce8, 0xd1c9, 0x4292, 0xb2, 0x37, 0x24, 0xed, 0x3d, 0xe8, 0xb1, 0x75); #define INTERFACE ID3D10EffectTechnique
1
0
0
0
Alexandre Julliard : msvcrt: Add an errno mapping for ERROR_SHARING_VIOLATION.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: b5d86403a4b87b3fb4c4ff84803e87cf859aa990 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=b5d86403a4b87b3fb4c4ff848…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Tue Jul 14 12:18:15 2009 +0200 msvcrt: Add an errno mapping for ERROR_SHARING_VIOLATION. --- dlls/msvcrt/errno.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/dlls/msvcrt/errno.c b/dlls/msvcrt/errno.c index 6ed6086..413ab39 100644 --- a/dlls/msvcrt/errno.c +++ b/dlls/msvcrt/errno.c @@ -140,6 +140,7 @@ void msvcrt_set_errno(int err) ERR_CASE(ERROR_DRIVE_LOCKED) ERR_CASE(ERROR_NOT_LOCKED) ERR_CASE(ERROR_INVALID_ACCESS) + ERR_CASE(ERROR_SHARING_VIOLATION) ERR_MAPS(ERROR_LOCK_VIOLATION, MSVCRT_EACCES); ERR_CASE(ERROR_FILE_NOT_FOUND) ERR_CASE(ERROR_NO_MORE_FILES)
1
0
0
0
Alexandre Julliard : ddraw/tests: Properly release surfaces even if we can' t get the texture object.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: 60d389670a3ee69ba3cf2a156da259edbae0d099 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=60d389670a3ee69ba3cf2a156…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Tue Jul 14 11:29:02 2009 +0200 ddraw/tests: Properly release surfaces even if we can't get the texture object. --- dlls/ddraw/tests/dsurface.c | 62 ++++++++++++++++++++++-------------------- 1 files changed, 32 insertions(+), 30 deletions(-) diff --git a/dlls/ddraw/tests/dsurface.c b/dlls/ddraw/tests/dsurface.c index a73c34c..28fc0f5 100644 --- a/dlls/ddraw/tests/dsurface.c +++ b/dlls/ddraw/tests/dsurface.c @@ -1030,36 +1030,38 @@ static void IFaceRefCount(void) /* IDirect3DTexture interface (unlike the others) alters the original IDirectDrawSurface ref count */ ret = IDirectDrawSurface_QueryInterface(surf, &IID_IDirect3DTexture, (void **) &tex); - if (ret == E_NOINTERFACE) return; /* win64 */ - ref = getRefcount((IUnknown *) tex); - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - - IDirectDrawSurface_QueryInterface(surf, &IID_IDirect3DTexture2, (void **) &tex2); - ref = getRefcount((IUnknown *) tex); - todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); - ref = getRefcount((IUnknown *) tex2); - todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); - - IDirectDrawSurface_QueryInterface(surf, &IID_IDirectDrawGammaControl, (void **) &gamma); - ref = getRefcount((IUnknown *) gamma); - todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); - - ref = IDirect3DTexture2_Release(tex2); /* Release the texture */ - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - - ref = IDirect3DTexture_Release(tex); /* Release the texture */ - todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); - - ref = IDirectDrawGammaControl_Release(gamma); /* Release the gamma control */ - todo_wine ok(ref == 0, "Refcount is %u, expected 0\n", ref); + if (SUCCEEDED(ret)) + { + ref = getRefcount((IUnknown *) tex); + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + + IDirectDrawSurface_QueryInterface(surf, &IID_IDirect3DTexture2, (void **) &tex2); + ref = getRefcount((IUnknown *) tex); + todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); + ref = getRefcount((IUnknown *) tex2); + todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); + + IDirectDrawSurface_QueryInterface(surf, &IID_IDirectDrawGammaControl, (void **) &gamma); + ref = getRefcount((IUnknown *) gamma); + todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); + + ref = IDirect3DTexture2_Release(tex2); /* Release the texture */ + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + + ref = IDirect3DTexture_Release(tex); /* Release the texture */ + todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); + + ref = IDirectDrawGammaControl_Release(gamma); /* Release the gamma control */ + todo_wine ok(ref == 0, "Refcount is %u, expected 0\n", ref); + } ref = IDirectDrawSurface2_Release(surf2); /* Release one of the 2 surf2 interfaces */ todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref);
1
0
0
0
Alexandre Julliard : ddraw/tests: Fix a failing test on 64-bit.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: 340f5734bf46d7c39519be416d50edac0a78251f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=340f5734bf46d7c39519be416…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Tue Jul 14 11:28:37 2009 +0200 ddraw/tests: Fix a failing test on 64-bit. --- dlls/ddraw/tests/refcount.c | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/dlls/ddraw/tests/refcount.c b/dlls/ddraw/tests/refcount.c index f0496e3..9ad560b 100644 --- a/dlls/ddraw/tests/refcount.c +++ b/dlls/ddraw/tests/refcount.c @@ -358,6 +358,14 @@ static void test_d3d_ifaces(void) ok(ref == 1, "IDirectDraw reference count is %ld\n", ref); hr = IDirectDraw_QueryInterface(DDraw1, &IID_IDirect3D, (void **) &D3D1); + if (hr == E_NOINTERFACE) /* win64 */ + { + IDirectDraw4_Release(DDraw4); + IDirectDraw2_Release(DDraw2); + IDirectDraw_Release(DDraw1); + skip( "no IDirect3D support\n" ); + return; + } ok(hr == DD_OK, "IDirectDraw_QueryInterface returned %08x\n", hr); ref = getRefcount( (IUnknown *) DDraw4); ok(ref == 1, "IDirectDraw4 reference count is %ld\n", ref);
1
0
0
0
Hans Leidekker : include: Add IWbemStatusCodeText and IWbemLocator interfaces.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: 9bfd49b5b24e6f4e64712875114af1aa1daf566c URL:
http://source.winehq.org/git/wine.git/?a=commit;h=9bfd49b5b24e6f4e647128751…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Mon Jul 13 16:10:07 2009 +0200 include: Add IWbemStatusCodeText and IWbemLocator interfaces. --- .gitignore | 1 + include/Makefile.in | 1 + include/wbemcli.idl | 211 +++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 213 insertions(+), 0 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=9bfd49b5b24e6f4e64712…
1
0
0
0
Piotr Caban : jscript: Added Date_getYear implementation.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: 55b8952ba2caa10a5242a5392340e5b74589ba66 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=55b8952ba2caa10a5242a5392…
Author: Piotr Caban <piotr.caban(a)gmail.com> Date: Tue Jul 14 01:37:11 2009 +0200 jscript: Added Date_getYear implementation. --- dlls/jscript/date.c | 33 +++++++++++++++++++++++++++++++++ 1 files changed, 33 insertions(+), 0 deletions(-) diff --git a/dlls/jscript/date.c b/dlls/jscript/date.c index 642c9ec..b65f03e 100644 --- a/dlls/jscript/date.c +++ b/dlls/jscript/date.c @@ -87,6 +87,7 @@ static const WCHAR setMonthW[] = {'s','e','t','M','o','n','t','h',0}; static const WCHAR setUTCMonthW[] = {'s','e','t','U','T','C','M','o','n','t','h',0}; static const WCHAR setFullYearW[] = {'s','e','t','F','u','l','l','Y','e','a','r',0}; static const WCHAR setUTCFullYearW[] = {'s','e','t','U','T','C','F','u','l','l','Y','e','a','r',0}; +static const WCHAR getYearW[] = {'g','e','t','Y','e','a','r',0}; static const WCHAR UTCW[] = {'U','T','C',0}; static const WCHAR parseW[] = {'p','a','r','s','e',0}; @@ -2134,6 +2135,37 @@ static HRESULT Date_setUTCFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DI return S_OK; } +/* ECMA-262 3rd Edition B2.4 */ +static HRESULT Date_getYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + DateInstance *date; + DOUBLE t, year; + + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + date = (DateInstance*)dispex; + t = local_time(date->time, date); + + + if(isnan(t)) { + if(retv) + num_set_nan(retv); + return S_OK; + } + + year = year_from_time(t); + if(retv) + num_set_val(retv, (1900<=year && year<2000)?year-1900:year); + + return S_OK; +} + static HRESULT Date_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) { @@ -2160,6 +2192,7 @@ static const builtin_prop_t Date_props[] = { {getUTCMinutesW, Date_getUTCMinutes, PROPF_METHOD}, {getUTCMonthW, Date_getUTCMonth, PROPF_METHOD}, {getUTCSecondsW, Date_getUTCSeconds, PROPF_METHOD}, + {getYearW, Date_getYear, PROPF_METHOD}, {hasOwnPropertyW, Date_hasOwnProperty, PROPF_METHOD}, {isPrototypeOfW, Date_isPrototypeOf, PROPF_METHOD}, {propertyIsEnumerableW, Date_propertyIsEnumerable, PROPF_METHOD},
1
0
0
0
Piotr Caban : jscript: Added String_fromCharCode implementation.
by Alexandre Julliard
14 Jul '09
14 Jul '09
Module: wine Branch: master Commit: c44056d4b2b34e838a305d29a385c96677d08d64 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c44056d4b2b34e838a305d29a…
Author: Piotr Caban <piotr.caban(a)gmail.com> Date: Tue Jul 14 01:36:58 2009 +0200 jscript: Added String_fromCharCode implementation. --- dlls/jscript/string.c | 47 ++++++++++++++++++++++++++++++++++++++++++++- dlls/jscript/tests/api.js | 7 ++++++ 2 files changed, 53 insertions(+), 1 deletions(-) diff --git a/dlls/jscript/string.c b/dlls/jscript/string.c index 6aa6302..cf3c5be 100644 --- a/dlls/jscript/string.c +++ b/dlls/jscript/string.c @@ -66,6 +66,7 @@ static const WCHAR hasOwnPropertyW[] = {'h','a','s','O','w','n','P','r','o','p', static const WCHAR propertyIsEnumerableW[] = {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; +static const WCHAR fromCharCodeW[] = {'f','r','o','m','C','h','a','r','C','o','d','e',0}; static HRESULT String_length(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) @@ -1557,6 +1558,37 @@ static const builtin_info_t String_info = { NULL }; +/* ECMA-262 3rd Edition 15.5.3.2 */ +static HRESULT StringConstr_fromCharCode(DispatchEx *dispex, LCID lcid, WORD flags, + DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) +{ + DWORD i, code; + BSTR ret; + HRESULT hres; + + ret = SysAllocStringLen(NULL, arg_cnt(dp)); + if(!ret) + return E_OUTOFMEMORY; + + for(i=0; i<arg_cnt(dp); i++) { + hres = to_uint32(dispex->ctx, get_arg(dp, i), ei, &code); + if(FAILED(hres)) { + SysFreeString(ret); + return hres; + } + + ret[i] = code; + } + + if(retv) { + V_VT(retv) = VT_BSTR; + V_BSTR(retv) = ret; + } + else SysFreeString(ret); + + return S_OK; +} + static HRESULT StringConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { @@ -1636,6 +1668,19 @@ static HRESULT string_alloc(script_ctx_t *ctx, BOOL use_constr, StringInstance * return S_OK; } +static const builtin_prop_t StringConstr_props[] = { + {fromCharCodeW, StringConstr_fromCharCode, PROPF_METHOD}, +}; + +static const builtin_info_t StringConstr_info = { + JSCLASS_FUNCTION, + {NULL, Function_value, 0}, + sizeof(StringConstr_props)/sizeof(*StringConstr_props), + StringConstr_props, + NULL, + NULL +}; + HRESULT create_string_constr(script_ctx_t *ctx, DispatchEx **ret) { StringInstance *string; @@ -1645,7 +1690,7 @@ HRESULT create_string_constr(script_ctx_t *ctx, DispatchEx **ret) if(FAILED(hres)) return hres; - hres = create_builtin_function(ctx, StringConstr_value, NULL, PROPF_CONSTR, &string->dispex, ret); + hres = create_builtin_function(ctx, StringConstr_value, &StringConstr_info, PROPF_CONSTR, &string->dispex, ret); jsdisp_release(&string->dispex); return hres; diff --git a/dlls/jscript/tests/api.js b/dlls/jscript/tests/api.js index 1e3a6dc..cf70ebc 100644 --- a/dlls/jscript/tests/api.js +++ b/dlls/jscript/tests/api.js @@ -405,6 +405,13 @@ ok(tmp === "<SUP>test</SUP>", "'test'.sup() = " + tmp); tmp = "test".sup(3); ok(tmp === "<SUP>test</SUP>", "'test'.sup(3) = " + tmp); +ok(String.fromCharCode() === "", "String.fromCharCode() = " + String.fromCharCode()); +ok(String.fromCharCode(65,"66",67) === "ABC", "String.fromCharCode(65,'66',67) = " + String.fromCharCode(65,"66",67)); +ok(String.fromCharCode(1024*64+65, -1024*64+65) === "AA", + "String.fromCharCode(1024*64+65, -1024*64+65) = " + String.fromCharCode(1024*64+65, -1024*64+65)); +ok(String.fromCharCode(65, NaN, undefined).length === 3, + "String.fromCharCode(65, NaN, undefined).length = " + String.fromCharCode(65, NaN, undefined).length); + var arr = new Array(); ok(typeof(arr) === "object", "arr () is not object"); ok((arr.length === 0), "arr.length is not 0");
1
0
0
0
← Newer
1
...
45
46
47
48
49
50
51
...
107
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
Results per page:
10
25
50
100
200