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
August 2007
----- 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
3 participants
1085 discussions
Start a n
N
ew thread
Stefan Dösinger : wined3d: Restructure Stateblock:: apply a bit.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: f5e6313cf68d694dac3666af99fc93669dd437c4 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=f5e6313cf68d694dac3666af9…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Sat Aug 4 00:46:37 2007 +0200 wined3d: Restructure Stateblock::apply a bit. --- dlls/wined3d/device.c | 2 +- dlls/wined3d/stateblock.c | 290 +++++++++++++++++++++++++++++++++------------ 2 files changed, 214 insertions(+), 78 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=f5e6313cf68d694dac366…
1
0
0
0
Stefan Dösinger : wined3d: Add a wined3d private WINED3DSBT_RECORDED.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: a06e002e93b61d54048672461f0072abd28d7e45 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=a06e002e93b61d54048672461…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Fri Aug 3 22:48:42 2007 +0200 wined3d: Add a wined3d private WINED3DSBT_RECORDED. --- dlls/d3d8/device.c | 6 ++++++ dlls/d3d9/stateblock.c | 6 ++++++ dlls/ddraw/device.c | 5 +++++ include/wine/wined3d_types.h | 1 + 4 files changed, 18 insertions(+), 0 deletions(-) diff --git a/dlls/d3d8/device.c b/dlls/d3d8/device.c index 0b2436d..74a0d13 100644 --- a/dlls/d3d8/device.c +++ b/dlls/d3d8/device.c @@ -1165,6 +1165,12 @@ static HRESULT WINAPI IDirect3DDevice8Impl_CreateStateBlock(LPDIRECT3DDEVICE8 if TRACE("(%p) Relay\n", This); + if(Type != D3DSBT_ALL && Type != D3DSBT_PIXELSTATE && + Type != D3DSBT_VERTEXSTATE ) { + WARN("Unexpected stateblock type, returning D3DERR_INVALIDCALL\n"); + return D3DERR_INVALIDCALL; + } + object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IDirect3DStateBlock8Impl)); if (NULL == object) { *pToken = 0; diff --git a/dlls/d3d9/stateblock.c b/dlls/d3d9/stateblock.c index 2cd79ea..33eda64 100644 --- a/dlls/d3d9/stateblock.c +++ b/dlls/d3d9/stateblock.c @@ -121,6 +121,12 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateStateBlock(LPDIRECT3DDEVICE9 iface, D3 HRESULT hrc = D3D_OK; TRACE("(%p) Relay\n", This); + + if(Type != D3DSBT_ALL && Type != D3DSBT_PIXELSTATE && + Type != D3DSBT_VERTEXSTATE ) { + WARN("Unexpected stateblock type, returning D3DERR_INVALIDCALL\n"); + return D3DERR_INVALIDCALL; + } object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IDirect3DStateBlock9Impl)); if (NULL == object) return E_OUTOFMEMORY; diff --git a/dlls/ddraw/device.c b/dlls/ddraw/device.c index 56e5cf3..3091017 100644 --- a/dlls/ddraw/device.c +++ b/dlls/ddraw/device.c @@ -5070,6 +5070,11 @@ IDirect3DDeviceImpl_7_CreateStateBlock(IDirect3DDevice7 *iface, WARN("BlockHandle == NULL, returning DDERR_INVALIDPARAMS\n"); return DDERR_INVALIDPARAMS; } + if(Type != D3DSBT_ALL && Type != D3DSBT_PIXELSTATE && + Type != D3DSBT_VERTEXSTATE ) { + WARN("Unexpected stateblock type, returning DDERR_INVALIDPARAMS\n"); + return DDERR_INVALIDPARAMS; + } EnterCriticalSection(&ddraw_cs); *BlockHandle = IDirect3DDeviceImpl_CreateHandle(This); diff --git a/include/wine/wined3d_types.h b/include/wine/wined3d_types.h index baebdc3..b7dc333 100644 --- a/include/wine/wined3d_types.h +++ b/include/wine/wined3d_types.h @@ -1208,6 +1208,7 @@ typedef enum _WINED3DSTATEBLOCKTYPE { WINED3DSBT_ALL = 1, WINED3DSBT_PIXELSTATE = 2, WINED3DSBT_VERTEXSTATE = 3, + WINED3DSBT_RECORDED = 4, /* WineD3D private */ WINED3DSBT_FORCE_DWORD = 0xffffffff } WINED3DSTATEBLOCKTYPE;
1
0
0
0
Stefan Dösinger : wined3d: Optimize float constants in stateblocks.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: b21c7854822b1aa979b6ed43796af41c205ba5fd URL:
http://source.winehq.org/git/wine.git/?a=commit;h=b21c7854822b1aa979b6ed437…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Fri Aug 3 20:26:29 2007 +0200 wined3d: Optimize float constants in stateblocks. --- dlls/wined3d/device.c | 24 +++++++++++++- dlls/wined3d/stateblock.c | 68 +++++++++++++++++++++------------------- dlls/wined3d/wined3d_private.h | 4 ++ 3 files changed, 62 insertions(+), 34 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=b21c7854822b1aa979b6e…
1
0
0
0
Stefan Dösinger : wined3d: Optimize sampler states in stateblocks.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: 59fb2928b8ba6dd0a4ffdd0fd5fd629533ab4b52 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=59fb2928b8ba6dd0a4ffdd0fd…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Fri Aug 3 20:23:52 2007 +0200 wined3d: Optimize sampler states in stateblocks. --- dlls/wined3d/device.c | 27 ++++++++++++++++++++-- dlls/wined3d/stateblock.c | 46 ++++++++++++++------------------------- dlls/wined3d/wined3d_private.h | 2 + 3 files changed, 43 insertions(+), 32 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index 4c53c8a..4e7a83b 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -497,6 +497,13 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateStateBlock(IWineD3DDevice* iface, object->num_contained_tss_states++; } } + for(i = 0; i < MAX_COMBINED_SAMPLERS; i++) { + for(j = 1; j <= WINED3D_HIGHEST_SAMPLER_STATE; j++) { + object->contained_sampler_states[object->num_contained_sampler_states].stage = i; + object->contained_sampler_states[object->num_contained_sampler_states].state = j; + object->num_contained_sampler_states++; + } + } } else if (Type == WINED3DSBT_PIXELSTATE) { @@ -532,10 +539,12 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateStateBlock(IWineD3DDevice* iface, object->num_contained_tss_states++; } } - for (j = 0 ; j < 16; j++) { + for (j = 0 ; j < MAX_COMBINED_SAMPLERS; j++) { for (i =0; i < NUM_SAVEDPIXELSTATES_S;i++) { - object->changed.samplerState[j][SavedPixelStates_S[i]] = TRUE; + object->contained_sampler_states[object->num_contained_sampler_states].stage = j; + object->contained_sampler_states[object->num_contained_sampler_states].state = SavedPixelStates_S[i]; + object->num_contained_sampler_states++; } } @@ -572,9 +581,12 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateStateBlock(IWineD3DDevice* iface, object->num_contained_tss_states++; } } - for (j = 0 ; j < 16; j++){ + for (j = 0 ; j < MAX_COMBINED_SAMPLERS; j++){ for (i =0; i < NUM_SAVEDVERTEXSTATES_S;i++) { object->changed.samplerState[j][SavedVertexStates_S[i]] = TRUE; + object->contained_sampler_states[object->num_contained_sampler_states].stage = j; + object->contained_sampler_states[object->num_contained_sampler_states].state = SavedVertexStates_S[i]; + object->num_contained_sampler_states++; } } @@ -4407,6 +4419,15 @@ static HRESULT WINAPI IWineD3DDeviceImpl_EndStateBlock(IWineD3DDevice *iface, IW } } } + for(i = 0; i < MAX_COMBINED_SAMPLERS; i++){ + for (j = 1; j < WINED3D_HIGHEST_SAMPLER_STATE; j++) { + if(object->changed.samplerState[i][j]) { + object->contained_sampler_states[object->num_contained_sampler_states].stage = i; + object->contained_sampler_states[object->num_contained_sampler_states].state = j; + object->num_contained_sampler_states++; + } + } + } *ppStateBlock = (IWineD3DStateBlock*) object; This->isRecordingState = FALSE; diff --git a/dlls/wined3d/stateblock.c b/dlls/wined3d/stateblock.c index ef05dd2..1de46f2 100644 --- a/dlls/wined3d/stateblock.c +++ b/dlls/wined3d/stateblock.c @@ -583,14 +583,15 @@ static HRESULT WINAPI IWineD3DStateBlockImpl_Capture(IWineD3DStateBlock *iface) TRACE("Updating texture %d to %p (was %p)\n", j, targetStateBlock->textures[j], This->textures[j]); This->textures[j] = targetStateBlock->textures[j]; } - for (i = 1; i <= WINED3D_HIGHEST_SAMPLER_STATE ; i++){ /* States are 1 based */ - if (This->changed.samplerState[j][i]) { - TRACE("Updating sampler state %d,%d to %d (was %d)\n", - j, i, targetStateBlock->samplerState[j][i], - This->samplerState[j][i]); - This->samplerState[j][i] = targetStateBlock->samplerState[j][i]; - } - } + } + + for (j = 0; j < This->num_contained_sampler_states; j++) { + DWORD stage = This->contained_sampler_states[j].stage; + DWORD state = This->contained_sampler_states[j].state; + TRACE("Updating sampler state %d,%d to %d (was %d)\n", + stage, state, targetStateBlock->samplerState[stage][state], + This->samplerState[stage][state]); + This->samplerState[stage][state] = targetStateBlock->samplerState[stage][state]; } } @@ -738,33 +739,12 @@ should really perform a delta so that only the changes get updated*/ IWineD3DDevice_SetTexture(pDevice, WINED3DVERTEXTEXTURESAMPLER0 + j - MAX_FRAGMENT_SAMPLERS, This->textures[j]); } } - for (i = 1; i <= WINED3D_HIGHEST_SAMPLER_STATE; i++){ - if (This->changed.samplerState[j][i]) { - ((IWineD3DDeviceImpl *)pDevice)->stateBlock->samplerState[j][i] = This->samplerState[j][i]; - ((IWineD3DDeviceImpl *)pDevice)->stateBlock->changed.samplerState[j][i] = TRUE; - } - } - /* SetTexture catches nop changes, so the above call does not assure that the sampler is updated */ - IWineD3DDeviceImpl_MarkStateDirty((IWineD3DDeviceImpl *)pDevice, STATE_SAMPLER(j)); } } else if (This->blockType == WINED3DSBT_PIXELSTATE) { - for (j = 0; j < MAX_COMBINED_SAMPLERS; j++) { - for (i = 0; i < NUM_SAVEDPIXELSTATES_S; i++) { - ((IWineD3DDeviceImpl *)pDevice)->stateBlock->samplerState[j][SavedPixelStates_S[i]] = This->samplerState[j][SavedPixelStates_S[i]]; - } - } - } else if (This->blockType == WINED3DSBT_VERTEXSTATE) { - for (j = 0; j < MAX_COMBINED_SAMPLERS; j++) { - for (i = 0; i < NUM_SAVEDVERTEXSTATES_S; i++) { - ((IWineD3DDeviceImpl *)pDevice)->stateBlock->samplerState[j][SavedVertexStates_S[i]] = This->samplerState[j][SavedVertexStates_S[i]]; - } - } - - } else { FIXME("Unrecognized state block type %d\n", This->blockType); } @@ -783,6 +763,14 @@ should really perform a delta so that only the changes get updated*/ /* TODO: Record a display list to apply all gl states. For now apply by brute force */ IWineD3DDeviceImpl_MarkStateDirty((IWineD3DDeviceImpl *)pDevice, STATE_TEXTURESTAGE(stage, state)); } + /* Sampler states */ + for (i = 0; i < This->num_contained_sampler_states; i++) { + DWORD stage = This->contained_sampler_states[i].stage; + DWORD state = This->contained_sampler_states[i].state; + ((IWineD3DDeviceImpl *)pDevice)->stateBlock->samplerState[stage][state] = This->samplerState[stage][state]; + ((IWineD3DDeviceImpl *)pDevice)->stateBlock->changed.samplerState[stage][state] = TRUE; + IWineD3DDeviceImpl_MarkStateDirty((IWineD3DDeviceImpl *)pDevice, STATE_SAMPLER(stage)); + } ((IWineD3DDeviceImpl *)pDevice)->stateBlock->lowest_disabled_stage = MAX_TEXTURES - 1; for(j = 0; j < MAX_TEXTURES - 1; j++) { diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index c2b5af3..c2b1d58 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -1386,6 +1386,8 @@ struct IWineD3DStateBlockImpl unsigned int num_contained_ps_consts_b; struct StageState contained_tss_states[MAX_TEXTURES * (WINED3D_HIGHEST_TEXTURE_STATE)]; unsigned int num_contained_tss_states; + struct StageState contained_sampler_states[MAX_COMBINED_SAMPLERS * WINED3D_HIGHEST_SAMPLER_STATE]; + unsigned int num_contained_sampler_states; }; extern void stateblock_savedstates_set(
1
0
0
0
Stefan Dösinger : wined3d: Fix a field in the wined3d header.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: 6e7a10f55099d21d474516d700462f26ec1258af URL:
http://source.winehq.org/git/wine.git/?a=commit;h=6e7a10f55099d21d474516d70…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Tue Aug 14 23:44:25 2007 +0200 wined3d: Fix a field in the wined3d header. --- dlls/wined3d/wined3d_private.h | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index c82abb5..c2b5af3 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -1374,7 +1374,7 @@ struct IWineD3DStateBlockImpl /* Contained state management */ DWORD contained_render_states[WINEHIGHEST_RENDER_STATE + 1]; unsigned int num_contained_render_states; - DWORD contained_transform_states[WINEHIGHEST_RENDER_STATE + 1]; + DWORD contained_transform_states[HIGHEST_TRANSFORMSTATE + 1]; unsigned int num_contained_transform_states; DWORD contained_vs_consts_i[MAX_CONST_I]; unsigned int num_contained_vs_consts_i;
1
0
0
0
Mikołaj Zalewski : winedos: Make UMB executable.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: 570eb6093ea0e96e35dc9a23d3de42e2cf166d3f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=570eb6093ea0e96e35dc9a23d…
Author: Mikołaj Zalewski <mikolaj(a)zalewski.pl> Date: Tue Aug 14 10:05:39 2007 -0700 winedos: Make UMB executable. --- dlls/winedos/himem.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/dlls/winedos/himem.c b/dlls/winedos/himem.c index 240ba3e..3dcc103 100644 --- a/dlls/winedos/himem.c +++ b/dlls/winedos/himem.c @@ -291,4 +291,9 @@ void DOSVM_InitSegments( void ) ptr = DOSVM_AllocDataUMB( DOSVM_RELAY_DATA_SIZE, 0, &DOSVM_dpmi_segments->relay_data_sel); memset( ptr, 0, DOSVM_RELAY_DATA_SIZE ); + + /* + * As we store code in UMB we should make sure it is executable + */ + VirtualProtect((void *)DOSVM_UMB_BOTTOM, DOSVM_UMB_TOP - DOSVM_UMB_BOTTOM, PAGE_EXECUTE_READWRITE, NULL); }
1
0
0
0
Peter Verthez : user32: LB_SETITEMDATA should return 1 on success, not 0.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: 13b376df73c7063ef2a6baf58d8cdfbb385fbf13 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=13b376df73c7063ef2a6baf58…
Author: Peter Verthez <peter.verthez(a)advalvas.be> Date: Tue Aug 14 18:35:18 2007 +0200 user32: LB_SETITEMDATA should return 1 on success, not 0. --- dlls/user32/listbox.c | 3 ++- dlls/user32/tests/listbox.c | 22 ++++++++++++++++++++++ 2 files changed, 24 insertions(+), 1 deletions(-) diff --git a/dlls/user32/listbox.c b/dlls/user32/listbox.c index 166d176..f422531 100644 --- a/dlls/user32/listbox.c +++ b/dlls/user32/listbox.c @@ -2677,7 +2677,8 @@ static LRESULT WINAPI ListBoxWndProc_common( HWND hwnd, UINT msg, return LB_ERR; } descr->items[wParam].data = lParam; - return LB_OKAY; + /* undocumented: returns TRUE, not LB_OKAY (0) */ + return TRUE; case LB_GETCOUNT16: case LB_GETCOUNT: diff --git a/dlls/user32/tests/listbox.c b/dlls/user32/tests/listbox.c index 125bd9d..663e37f 100644 --- a/dlls/user32/tests/listbox.c +++ b/dlls/user32/tests/listbox.c @@ -512,6 +512,27 @@ static void test_itemfrompoint(void) DestroyWindow( hList ); } +static void test_listbox_item_data(void) +{ + HWND hList; + int r, id; + + hList = CreateWindow( "ListBox", "list test", 0, + 1, 1, 600, 100, NULL, NULL, NULL, NULL ); + ok( hList != NULL, "failed to create listbox\n"); + + id = SendMessage( hList, LB_ADDSTRING, 0, (LPARAM) "hi"); + ok( id == 0, "item id wrong\n"); + + r = SendMessage( hList, LB_SETITEMDATA, 0, MAKELPARAM( 20, 0 )); + ok(r == TRUE, "LB_SETITEMDATA returned %d instead of TRUE\n", r); + + r = SendMessage( hList, LB_GETITEMDATA, 0, 0); + ok( r == 20, "get item data failed\n"); + + DestroyWindow( hList ); +} + START_TEST(listbox) { const struct listbox_test SS = @@ -587,4 +608,5 @@ START_TEST(listbox) test_selection(); test_listbox_height(); test_itemfrompoint(); + test_listbox_item_data(); }
1
0
0
0
Roderick Colenbrander : wined3d: Load wglGetProcAddress from opengl32. dll instead of gdi32.dll when USE_WIN32_OPENGL is defined.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: 3d58a065dfd0ceb7cf87c106a007d0819a857fc9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=3d58a065dfd0ceb7cf87c106a…
Author: Roderick Colenbrander <thunderbird2k(a)gmx.net> Date: Tue Aug 14 15:08:20 2007 +0200 wined3d: Load wglGetProcAddress from opengl32.dll instead of gdi32.dll when USE_WIN32_OPENGL is defined. --- dlls/wined3d/directx.c | 11 ++++++++++- 1 files changed, 10 insertions(+), 1 deletions(-) diff --git a/dlls/wined3d/directx.c b/dlls/wined3d/directx.c index 22487bc..bef0c3f 100644 --- a/dlls/wined3d/directx.c +++ b/dlls/wined3d/directx.c @@ -414,12 +414,22 @@ BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) { TRACE_(d3d_caps)("(%p)\n", gl_info); +#ifdef USE_WIN32_OPENGL +#define USE_GL_FUNC(pfn) pfn = (void*)GetProcAddress(mod_gl, (const char *) #pfn); + mod_gl = LoadLibraryA("opengl32.dll"); + if(!mod_gl) { + ERR("Can't load opengl32.dll!\n"); + return FALSE; + } +#else +#define USE_GL_FUNC(pfn) pfn = (void*)p_wglGetProcAddress( (const char *) #pfn); /* To bypass the opengl32 thunks load wglGetProcAddress from gdi32 (glXGetProcAddress wrapper) instead of opengl32's */ mod_gl = LoadLibraryA("gdi32.dll"); if(!mod_gl) { ERR("Can't load gdi32.dll!\n"); return FALSE; } +#endif p_wglGetProcAddress = (void*)GetProcAddress(mod_gl, "wglGetProcAddress"); if(!p_wglGetProcAddress) { @@ -428,7 +438,6 @@ BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) { } /* Dynamicly load all GL core functions */ -#define USE_GL_FUNC(pfn) pfn = (void*)p_wglGetProcAddress( (const char *) #pfn); GL_FUNCS_GEN; #undef USE_GL_FUNC
1
0
0
0
Roderick Colenbrander : wined3d: Use WINE_GLAPI for setting the calling convention needed for OpenGL.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: 6af80e44c0316d226c63d9591905197acdb3f9f0 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=6af80e44c0316d226c63d9591…
Author: Roderick Colenbrander <thunderbird2k(a)gmx.net> Date: Tue Aug 14 14:34:53 2007 +0200 wined3d: Use WINE_GLAPI for setting the calling convention needed for OpenGL. --- include/wine/wined3d_gl.h | 757 ++++++++++++++++++++++----------------------- 1 files changed, 372 insertions(+), 385 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=6af80e44c0316d226c63d…
1
0
0
0
Chris Robinson : wgl: GDI support is not advertised with double buffering.
by Alexandre Julliard
15 Aug '07
15 Aug '07
Module: wine Branch: master Commit: 5e6d3c15e704e34cd264cad333990868d6b83000 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5e6d3c15e704e34cd264cad33…
Author: Chris Robinson <chris.kcat(a)gmail.com> Date: Mon Aug 13 18:36:46 2007 -0700 wgl: GDI support is not advertised with double buffering. --- dlls/opengl32/tests/opengl.c | 26 ++++++++++++++++++++++++++ dlls/winex11.drv/opengl.c | 13 ++++++++++++- 2 files changed, 38 insertions(+), 1 deletions(-) diff --git a/dlls/opengl32/tests/opengl.c b/dlls/opengl32/tests/opengl.c index 6ef1d25..2aca1d6 100644 --- a/dlls/opengl32/tests/opengl.c +++ b/dlls/opengl32/tests/opengl.c @@ -35,6 +35,9 @@ static int (WINAPI *pwglReleasePbufferDCARB)(HPBUFFERARB, HDC); #define WGL_GREEN_BITS_ARB 0x2017 #define WGL_BLUE_BITS_ARB 0x2019 #define WGL_ALPHA_BITS_ARB 0x201B +#define WGL_SUPPORT_GDI_ARB 0x200F +#define WGL_DOUBLE_BUFFER_ARB 0x2011 + static BOOL (WINAPI *pwglChoosePixelFormatARB)(HDC, const int *, const FLOAT *, UINT, int *, UINT *); static BOOL (WINAPI *pwglGetPixelFormatAttribivARB)(HDC, int, int, UINT, const int *, int *); @@ -225,6 +228,28 @@ static void test_colorbits(HDC hdc) iAttribRet[0], iAttribRet[1]); } +static void test_gdi_dbuf(HDC hdc) +{ + const int iAttribList[] = { WGL_SUPPORT_GDI_ARB, WGL_DOUBLE_BUFFER_ARB }; + int iAttribRet[sizeof(iAttribList)/sizeof(iAttribList[0])]; + unsigned int nFormats; + int iPixelFormat; + int res; + + nFormats = DescribePixelFormat(hdc, 0, 0, NULL); + for(iPixelFormat = 1;iPixelFormat <= nFormats;iPixelFormat++) + { + res = pwglGetPixelFormatAttribivARB(hdc, iPixelFormat, 0, + sizeof(iAttribList)/sizeof(iAttribList[0]), iAttribList, + iAttribRet); + ok(res!=FALSE, "wglGetPixelFormatAttribivARB failed for pixel format %d\n", iPixelFormat); + if(res == FALSE) + continue; + + ok(!(iAttribRet[0] && iAttribRet[1]), "GDI support and double buffering on pixel format %d\n", iPixelFormat); + } +} + START_TEST(opengl) { HWND hwnd; @@ -274,6 +299,7 @@ START_TEST(opengl) test_setpixelformat(); test_colorbits(hdc); + test_gdi_dbuf(hdc); wgl_extensions = pwglGetExtensionsStringARB(hdc); if(wgl_extensions == NULL) skip("Skipping opengl32 tests because this OpenGL implementation doesn't support WGL extensions!\n"); diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c index 62d7e2d..516de5f 100644 --- a/dlls/winex11.drv/opengl.c +++ b/dlls/winex11.drv/opengl.c @@ -1301,7 +1301,11 @@ int X11DRV_DescribePixelFormat(X11DRV_PDEVICE *physDev, if(value == GLX_SLOW_CONFIG) ppfd->dwFlags |= PFD_GENERIC_ACCELERATED; - pglXGetFBConfigAttrib(gdi_display, fmt->fbconfig, GLX_DOUBLEBUFFER, &value); if (value) ppfd->dwFlags |= PFD_DOUBLEBUFFER; + pglXGetFBConfigAttrib(gdi_display, fmt->fbconfig, GLX_DOUBLEBUFFER, &value); + if (value) { + ppfd->dwFlags |= PFD_DOUBLEBUFFER; + ppfd->dwFlags &= ~PFD_SUPPORT_GDI; + } pglXGetFBConfigAttrib(gdi_display, fmt->fbconfig, GLX_STEREO, &value); if (value) ppfd->dwFlags |= PFD_STEREO; /* Pixel type */ @@ -2773,6 +2777,13 @@ static GLboolean WINAPI X11DRV_wglGetPixelFormatAttribivARB(HDC hdc, int iPixelF break; case WGL_SUPPORT_GDI_ARB: + if (!fmt) goto pix_error; + hTest = pglXGetFBConfigAttrib(gdi_display, fmt->fbconfig, GLX_DOUBLEBUFFER, &tmp); + if (hTest) goto get_error; + if(tmp) { + piValues[i] = GL_FALSE; + continue; + } curGLXAttr = GLX_X_RENDERABLE; break;
1
0
0
0
← Newer
1
...
53
54
55
56
57
58
59
...
109
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
108
109
Results per page:
10
25
50
100
200