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 2010
----- 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
955 discussions
Start a n
N
ew thread
Michael Stefaniuc : mciwave: Avoid using long.
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: f9d2b85ea577ab0179794ac9c5b1a087e9e6dd60 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=f9d2b85ea577ab0179794ac9c…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Fri May 21 12:13:22 2010 +0200 mciwave: Avoid using long. --- dlls/mciwave/mciwave.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/mciwave/mciwave.c b/dlls/mciwave/mciwave.c index 6485288..67cf09a 100644 --- a/dlls/mciwave/mciwave.c +++ b/dlls/mciwave/mciwave.c @@ -277,7 +277,7 @@ static DWORD WAVE_ConvertTimeFormatToByte(WINE_MCIWAVE* wmw, DWORD val) static DWORD WAVE_mciReadFmt(WINE_MCIWAVE* wmw, const MMCKINFO* pckMainRIFF) { MMCKINFO mmckInfo; - long r; + LONG r; LPWAVEFORMATEX pwfx; mmckInfo.ckid = mmioFOURCC('f', 'm', 't', ' '); @@ -300,7 +300,7 @@ static DWORD WAVE_mciReadFmt(WINE_MCIWAVE* wmw, const MMCKINFO* pckMainRIFF) TRACE("nAvgBytesPerSec=%d\n", pwfx->nAvgBytesPerSec); TRACE("nBlockAlign=%d\n", pwfx->nBlockAlign); TRACE("wBitsPerSample=%u !\n", pwfx->wBitsPerSample); - if (r >= (long)sizeof(WAVEFORMATEX)) + if (r >= sizeof(WAVEFORMATEX)) TRACE("cbSize=%u !\n", pwfx->cbSize); if ((pwfx->wFormatTag != WAVE_FORMAT_PCM) && (r < sizeof(WAVEFORMATEX) || (r < sizeof(WAVEFORMATEX) + pwfx->cbSize))) {
1
0
0
0
Michael Stefaniuc : winemp3.acm: Avoid using the long type.
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: 5b9fb3c5be6f0d182df6cd4b0145548701da0652 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5b9fb3c5be6f0d182df6cd4b0…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Fri May 21 12:13:36 2010 +0200 winemp3.acm: Avoid using the long type. --- dlls/winemp3.acm/mpegl3.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/winemp3.acm/mpegl3.c b/dlls/winemp3.acm/mpegl3.c index 6074501..6a2dbee 100644 --- a/dlls/winemp3.acm/mpegl3.c +++ b/dlls/winemp3.acm/mpegl3.c @@ -298,7 +298,7 @@ typedef struct tagAcmMpeg3Data OSStatus lastError; } AcmMpeg3Data; -static inline const char* wine_dbgstr_fourcc(unsigned long fourcc) +static inline const char* wine_dbgstr_fourcc(ULONG fourcc) { char buf[4] = { (char) (fourcc >> 24), (char) (fourcc >> 16), (char) (fourcc >> 8), (char) fourcc };
1
0
0
0
Michael Stefaniuc : user32: Avoid using long.
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: bf7241c12567c81ba4cc78b58c9550401cee95f7 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=bf7241c12567c81ba4cc78b58…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Fri May 21 12:12:47 2010 +0200 user32: Avoid using long. --- dlls/user32/dialog.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/user32/dialog.c b/dlls/user32/dialog.c index 79f5182..aac8a4d 100644 --- a/dlls/user32/dialog.c +++ b/dlls/user32/dialog.c @@ -1374,7 +1374,7 @@ UINT WINAPI GetDlgItemInt( HWND hwnd, INT id, BOOL *translated, { char str[30]; char * endptr; - long result = 0; + LONG_PTR result = 0; if (translated) *translated = FALSE; if (!SendDlgItemMessageA(hwnd, id, WM_GETTEXT, sizeof(str), (LPARAM)str))
1
0
0
0
Michael Stefaniuc : mcicda: Avoid using long.
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: 309e92f449d8de5d70dc24ef912bb77c8ba5bf74 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=309e92f449d8de5d70dc24ef9…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Fri May 21 12:13:15 2010 +0200 mcicda: Avoid using long. --- dlls/mcicda/mcicda.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/mcicda/mcicda.c b/dlls/mcicda/mcicda.c index 9f62594..cb8840e 100644 --- a/dlls/mcicda/mcicda.c +++ b/dlls/mcicda/mcicda.c @@ -564,7 +564,7 @@ static DWORD MCICDA_GetDevCaps(UINT wDevID, DWORD dwFlags, static DWORD CDROM_Audio_GetSerial(CDROM_TOC* toc) { - unsigned long serial = 0; + DWORD serial = 0; int i; WORD wMagic; DWORD dwStart, dwEnd;
1
0
0
0
Henri Verbeet : wined3d: Set the device.c GLINFO_LOCATION to *gl_info.
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: 11b8c425e924be02f97340ccebfe95ae719bded8 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=11b8c425e924be02f97340cce…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Fri May 21 09:35:25 2010 +0200 wined3d: Set the device.c GLINFO_LOCATION to *gl_info. --- dlls/wined3d/device.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index 7a8b9da..7c06e6c 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -34,7 +34,7 @@ #include "wined3d_private.h" WINE_DEFAULT_DEBUG_CHANNEL(d3d); -#define GLINFO_LOCATION This->adapter->gl_info +#define GLINFO_LOCATION (*gl_info) /* Define the default light parameters as specified by MSDN */ const WINED3DLIGHT WINED3D_default_light = { @@ -5232,6 +5232,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; const struct wined3d_format_desc *src_format; const struct wined3d_format_desc *dst_format; + const struct wined3d_gl_info *gl_info; struct wined3d_context *context; const unsigned char *data; UINT update_w, update_h; @@ -5273,6 +5274,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, return IWineD3DSurface_BltFast(dst_surface, dst_x, dst_y, src_surface, src_rect, 0); context = context_acquire(This, NULL); + gl_info = context->gl_info; ENTER_GL(); GL_EXTCALL(glActiveTextureARB(GL_TEXTURE0_ARB));
1
0
0
0
Henri Verbeet : wined3d: Explicitly pass GL info to buffer_get_sysmem().
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: 5dff410254a3f2d1de5fe6f43aed6ebadd1d6935 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5dff410254a3f2d1de5fe6f43…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Fri May 21 09:35:24 2010 +0200 wined3d: Explicitly pass GL info to buffer_get_sysmem(). --- dlls/wined3d/buffer.c | 12 ++++------ dlls/wined3d/device.c | 16 ++++++++------ dlls/wined3d/drawprim.c | 44 ++++++++++++++++++++------------------- dlls/wined3d/state.c | 2 +- dlls/wined3d/wined3d_private.h | 2 +- 5 files changed, 39 insertions(+), 37 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=5dff410254a3f2d1de5fe…
1
0
0
0
Henri Verbeet : wined3d: Explicitly pass GL info to buffer_create_buffer_object().
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: e6473094026f9bb2953672afb407d529ca6db9bf URL:
http://source.winehq.org/git/wine.git/?a=commit;h=e6473094026f9bb2953672afb…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Fri May 21 09:35:23 2010 +0200 wined3d: Explicitly pass GL info to buffer_create_buffer_object(). --- dlls/wined3d/buffer.c | 9 ++++----- dlls/wined3d/device.c | 3 ++- dlls/wined3d/wined3d_private.h | 3 ++- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/dlls/wined3d/buffer.c b/dlls/wined3d/buffer.c index 7d3d078..fbd39b9 100644 --- a/dlls/wined3d/buffer.c +++ b/dlls/wined3d/buffer.c @@ -117,10 +117,9 @@ static void delete_gl_buffer(struct wined3d_buffer *This, const struct wined3d_g } /* Context activation is done by the caller. */ -static void buffer_create_buffer_object(struct wined3d_buffer *This) +static void buffer_create_buffer_object(struct wined3d_buffer *This, const struct wined3d_gl_info *gl_info) { GLenum error, gl_usage; - const struct wined3d_gl_info *gl_info = &This->resource.device->adapter->gl_info; TRACE("Creating an OpenGL vertex buffer object for IWineD3DVertexBuffer %p Usage(%s)\n", This, debug_d3dusage(This->resource.usage)); @@ -613,7 +612,7 @@ static inline void fixup_transformed_pos(float *p) } /* Context activation is done by the caller. */ -const BYTE *buffer_get_memory(IWineD3DBuffer *iface, GLuint *buffer_object) +const BYTE *buffer_get_memory(IWineD3DBuffer *iface, const struct wined3d_gl_info *gl_info, GLuint *buffer_object) { struct wined3d_buffer *This = (struct wined3d_buffer *)iface; @@ -622,7 +621,7 @@ const BYTE *buffer_get_memory(IWineD3DBuffer *iface, GLuint *buffer_object) { if (This->flags & WINED3D_BUFFER_CREATEBO) { - buffer_create_buffer_object(This); + buffer_create_buffer_object(This, gl_info); This->flags &= ~WINED3D_BUFFER_CREATEBO; if (This->buffer_object) { @@ -946,7 +945,7 @@ static void STDMETHODCALLTYPE buffer_PreLoad(IWineD3DBuffer *iface) /* TODO: Make converting independent from VBOs */ if (This->flags & WINED3D_BUFFER_CREATEBO) { - buffer_create_buffer_object(This); + buffer_create_buffer_object(This, gl_info); This->flags &= ~WINED3D_BUFFER_CREATEBO; } else diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index e73ecc9..fd8cd60 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -213,7 +213,8 @@ void device_stream_info_from_declaration(IWineD3DDeviceImpl *This, else { TRACE("Stream %u isn't UP, %p\n", element->input_slot, This->stateBlock->streamSource[element->input_slot]); - data = buffer_get_memory(This->stateBlock->streamSource[element->input_slot], &buffer_object); + data = buffer_get_memory(This->stateBlock->streamSource[element->input_slot], + &This->adapter->gl_info, &buffer_object); /* Can't use vbo's if the base vertex index is negative. OpenGL doesn't accept negative offsets * (or rather offsets bigger than the vbo, because the pointer is unsigned), so use system memory diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index e1f4282..947456a 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -2503,7 +2503,8 @@ struct wined3d_buffer UINT *conversion_shift; /* NULL if no shifted conversion */ }; -const BYTE *buffer_get_memory(IWineD3DBuffer *iface, GLuint *buffer_object) DECLSPEC_HIDDEN; +const BYTE *buffer_get_memory(IWineD3DBuffer *iface, const struct wined3d_gl_info *gl_info, + GLuint *buffer_object) DECLSPEC_HIDDEN; BYTE *buffer_get_sysmem(struct wined3d_buffer *This) DECLSPEC_HIDDEN; HRESULT buffer_init(struct wined3d_buffer *buffer, IWineD3DDeviceImpl *device, UINT size, DWORD usage, WINED3DFORMAT format, WINED3DPOOL pool, GLenum bind_hint,
1
0
0
0
Henri Verbeet : wined3d: Set the buffer.c GLINFO_LOCATION to *gl_info.
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: e536f99871a8ca6bf8f02d18a438f52936eaddf0 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=e536f99871a8ca6bf8f02d18a…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Fri May 21 09:35:22 2010 +0200 wined3d: Set the buffer.c GLINFO_LOCATION to *gl_info. --- dlls/wined3d/buffer.c | 16 ++++++++++------ 1 files changed, 10 insertions(+), 6 deletions(-) diff --git a/dlls/wined3d/buffer.c b/dlls/wined3d/buffer.c index 8372b7a..7d3d078 100644 --- a/dlls/wined3d/buffer.c +++ b/dlls/wined3d/buffer.c @@ -29,7 +29,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d); -#define GLINFO_LOCATION This->resource.device->adapter->gl_info +#define GLINFO_LOCATION (*gl_info) #define VB_MAXDECLCHANGES 100 /* After that number of decl changes we stop converting */ #define VB_RESETDECLCHANGE 1000 /* Reset the decl changecount after that number of draws */ @@ -98,7 +98,7 @@ static inline BOOL buffer_is_fully_dirty(struct wined3d_buffer *This) } /* Context activation is done by the caller */ -static void delete_gl_buffer(struct wined3d_buffer *This) +static void delete_gl_buffer(struct wined3d_buffer *This, const struct wined3d_gl_info *gl_info) { if(!This->buffer_object) return; @@ -226,7 +226,7 @@ static void buffer_create_buffer_object(struct wined3d_buffer *This) fail: /* Clean up all vbo init, but continue because we can work without a vbo :-) */ ERR("Failed to create a vertex buffer object. Continuing, but performance issues may occur\n"); - delete_gl_buffer(This); + delete_gl_buffer(This, gl_info); buffer_clear_dirty_areas(This); } @@ -552,7 +552,7 @@ static BOOL buffer_find_decl(struct wined3d_buffer *This) } /* Context activation is done by the caller. */ -static void buffer_check_buffer_object_size(struct wined3d_buffer *This) +static void buffer_check_buffer_object_size(struct wined3d_buffer *This, const struct wined3d_gl_info *gl_info) { UINT size = This->conversion_stride ? This->conversion_stride * (This->resource.size / This->stride) : This->resource.size; @@ -675,6 +675,8 @@ static ULONG STDMETHODCALLTYPE buffer_AddRef(IWineD3DBuffer *iface) /* Context activation is done by the caller. */ BYTE *buffer_get_sysmem(struct wined3d_buffer *This) { + const struct wined3d_gl_info *gl_info = &This->resource.device->adapter->gl_info; + /* AllocatedMemory exists if the buffer is double buffered or has no buffer object at all */ if(This->resource.allocatedMemory) return This->resource.allocatedMemory; @@ -709,7 +711,7 @@ static void STDMETHODCALLTYPE buffer_UnLoad(IWineD3DBuffer *iface) This->flags &= ~WINED3D_BUFFER_DOUBLEBUFFER; } - delete_gl_buffer(This); + delete_gl_buffer(This, context->gl_info); This->flags |= WINED3D_BUFFER_CREATEBO; /* Recreate the buffer object next load */ buffer_clear_dirty_areas(This); @@ -926,6 +928,7 @@ static void STDMETHODCALLTYPE buffer_PreLoad(IWineD3DBuffer *iface) struct wined3d_buffer *This = (struct wined3d_buffer *)iface; IWineD3DDeviceImpl *device = This->resource.device; UINT start = 0, end = 0, len = 0, vertices; + const struct wined3d_gl_info *gl_info; struct wined3d_context *context; BOOL decl_changed = FALSE; unsigned int i, j; @@ -936,6 +939,7 @@ static void STDMETHODCALLTYPE buffer_PreLoad(IWineD3DBuffer *iface) This->flags &= ~(WINED3D_BUFFER_NOSYNC | WINED3D_BUFFER_DISCARD); context = context_acquire(device, NULL); + gl_info = context->gl_info; if (!This->buffer_object) { @@ -993,7 +997,7 @@ static void STDMETHODCALLTYPE buffer_PreLoad(IWineD3DBuffer *iface) IWineD3DDeviceImpl_MarkStateDirty(device, STATE_STREAMSRC); goto end; } - buffer_check_buffer_object_size(This); + buffer_check_buffer_object_size(This, gl_info); /* The declaration changed, reload the whole buffer */ WARN("Reloading buffer because of decl change\n");
1
0
0
0
Henri Verbeet : wined3d: Introduce a separate function for translating front buffer coordinates to GL coordinates .
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: db0784e1da50dec1be5d14f93cb9ff0b6c93a9d9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=db0784e1da50dec1be5d14f93…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Fri May 21 09:35:21 2010 +0200 wined3d: Introduce a separate function for translating front buffer coordinates to GL coordinates. --- dlls/wined3d/arb_program_shader.c | 12 +-------- dlls/wined3d/device.c | 38 +++++++-------------------- dlls/wined3d/surface.c | 51 ++++++++++++------------------------ dlls/wined3d/wined3d_private.h | 1 + 4 files changed, 29 insertions(+), 73 deletions(-) diff --git a/dlls/wined3d/arb_program_shader.c b/dlls/wined3d/arb_program_shader.c index f62ff56..c0b3924 100644 --- a/dlls/wined3d/arb_program_shader.c +++ b/dlls/wined3d/arb_program_shader.c @@ -7004,17 +7004,7 @@ HRESULT arbfp_blit_surface(IWineD3DDeviceImpl *device, IWineD3DSurfaceImpl *src_ * whereas the real gl drawable size is the size of the window. */ dst_swapchain = (dst_surface->Flags & SFLAG_SWAPCHAIN) ? (IWineD3DSwapChainImpl *)dst_surface->container : NULL; if (dst_swapchain && dst_surface == dst_swapchain->front_buffer) - { - RECT windowsize; - POINT offset = {0,0}; - UINT h; - ClientToScreen(context->win_handle, &offset); - GetClientRect(context->win_handle, &windowsize); - h = windowsize.bottom - windowsize.top; - dst_rect.left -= offset.x; dst_rect.right -=offset.x; - dst_rect.top -= offset.y; dst_rect.bottom -=offset.y; - dst_rect.top += dst_surface->currentDesc.Height - h; dst_rect.bottom += dst_surface->currentDesc.Height - h; - } + surface_translate_frontbuffer_coords(dst_surface, context->win_handle, &dst_rect); arbfp_blit_set((IWineD3DDevice *)device, src_surface); diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index feb3949..e73ecc9 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -5740,7 +5740,6 @@ void stretch_rect_fbo(IWineD3DDeviceImpl *device, IWineD3DSurfaceImpl *src_surfa const struct wined3d_gl_info *gl_info; struct wined3d_context *context; GLenum gl_filter; - POINT offset = {0, 0}; RECT src_rect, dst_rect; TRACE("device %p, src_surface %p, src_rect_in %s, dst_surface %p, dst_rect_in %s, filter %s (0x%08x).\n", @@ -5788,19 +5787,11 @@ void stretch_rect_fbo(IWineD3DDeviceImpl *device, IWineD3DSurfaceImpl *src_surfa TRACE("Source surface %p is onscreen\n", src_surface); - if(buffer == GL_FRONT) { - RECT windowsize; - UINT h; - ClientToScreen(context->win_handle, &offset); - GetClientRect(context->win_handle, &windowsize); - h = windowsize.bottom - windowsize.top; - src_rect.left -= offset.x; src_rect.right -=offset.x; - src_rect.top = offset.y + h - src_rect.top; - src_rect.bottom = offset.y + h - src_rect.bottom; - } else { - src_rect.top = src_surface->currentDesc.Height - src_rect.top; - src_rect.bottom = src_surface->currentDesc.Height - src_rect.bottom; - } + if (buffer == GL_FRONT) + surface_translate_frontbuffer_coords(src_surface, context->win_handle, &src_rect); + + src_rect.top = src_surface->currentDesc.Height - src_rect.top; + src_rect.bottom = src_surface->currentDesc.Height - src_rect.bottom; ENTER_GL(); context_bind_fbo(context, GL_READ_FRAMEBUFFER, NULL); @@ -5822,20 +5813,11 @@ void stretch_rect_fbo(IWineD3DDeviceImpl *device, IWineD3DSurfaceImpl *src_surfa TRACE("Destination surface %p is onscreen\n", dst_surface); - if(buffer == GL_FRONT) { - RECT windowsize; - UINT h; - ClientToScreen(context->win_handle, &offset); - GetClientRect(context->win_handle, &windowsize); - h = windowsize.bottom - windowsize.top; - dst_rect.left -= offset.x; dst_rect.right -=offset.x; - dst_rect.top = offset.y + h - dst_rect.top; - dst_rect.bottom = offset.y + h - dst_rect.bottom; - } else { - /* Screen coords = window coords, surface height = window height */ - dst_rect.top = dst_surface->currentDesc.Height - dst_rect.top; - dst_rect.bottom = dst_surface->currentDesc.Height - dst_rect.bottom; - } + if (buffer == GL_FRONT) + surface_translate_frontbuffer_coords(dst_surface, context->win_handle, &dst_rect); + + dst_rect.top = dst_surface->currentDesc.Height - dst_rect.top; + dst_rect.bottom = dst_surface->currentDesc.Height - dst_rect.bottom; ENTER_GL(); context_bind_fbo(context, GL_DRAW_FRAMEBUFFER, NULL); diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 9e1d434..ca796c5 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -3380,6 +3380,21 @@ static BOOL fbo_blit_supported(const struct wined3d_gl_info *gl_info, enum blit_ const RECT *dst_rect, DWORD dst_usage, WINED3DPOOL dst_pool, const struct wined3d_format_desc *dst_format_desc); +/* Front buffer coordinates are always full screen coordinates, but our GL + * drawable is limited to the window's client area. The sysmem and texture + * copies do have the full screen size. Note that GL has a bottom-left + * origin, while D3D has a top-left origin. */ +void surface_translate_frontbuffer_coords(IWineD3DSurfaceImpl *surface, HWND window, RECT *rect) +{ + POINT offset = {0, surface->currentDesc.Height}; + RECT windowsize; + + GetClientRect(window, &windowsize); + offset.y -= windowsize.bottom - windowsize.top; + ScreenToClient(window, &offset); + OffsetRect(rect, offset.x, offset.y); +} + /* Not called from the VTable */ static HRESULT IWineD3DSurfaceImpl_BltOverride(IWineD3DSurfaceImpl *dst_surface, const RECT *DestRect, IWineD3DSurfaceImpl *src_surface, const RECT *SrcRect, DWORD Flags, const WINEDDBLTFX *DDBltFx, @@ -3674,25 +3689,8 @@ static HRESULT IWineD3DSurfaceImpl_BltOverride(IWineD3DSurfaceImpl *dst_surface, context = context_acquire(device, dst_surface); context_apply_blit_state(context, device); - /* The coordinates of the ddraw front buffer are always fullscreen ('screen coordinates', - * while OpenGL coordinates are window relative. - * Also beware of the origin difference(top left vs bottom left). - * Also beware that the front buffer's surface size is screen width x screen height, - * whereas the real gl drawable size is the size of the window. - */ if (dstSwapchain && dst_surface == dstSwapchain->front_buffer) - { - RECT windowsize; - POINT offset = {0,0}; - UINT h; - ClientToScreen(context->win_handle, &offset); - GetClientRect(context->win_handle, &windowsize); - h = windowsize.bottom - windowsize.top; - dst_rect.left -= offset.x; dst_rect.right -=offset.x; - dst_rect.top -= offset.y; dst_rect.bottom -=offset.y; - dst_rect.top += dst_surface->currentDesc.Height - h; - dst_rect.bottom += dst_surface->currentDesc.Height - h; - } + surface_translate_frontbuffer_coords(dst_surface, context->win_handle, &dst_rect); if (!device->blitter->blit_supported(&device->adapter->gl_info, BLIT_OP_BLIT, &src_rect, src_surface->resource.usage, src_surface->resource.pool, src_surface->resource.format_desc, @@ -4351,22 +4349,7 @@ static inline void surface_blt_to_drawable(IWineD3DSurfaceImpl *This, const RECT } if ((This->Flags & SFLAG_SWAPCHAIN) && This == ((IWineD3DSwapChainImpl *)This->container)->front_buffer) - { - RECT windowsize; - POINT offset = {0, 0}; - UINT h; - - ClientToScreen(context->win_handle, &offset); - GetClientRect(context->win_handle, &windowsize); - h = windowsize.bottom - windowsize.top; - - dst_rect.left -= offset.x; - dst_rect.right -=offset.x; - dst_rect.top -= offset.y; - dst_rect.bottom -=offset.y; - dst_rect.top += This->currentDesc.Height - h; - dst_rect.bottom += This->currentDesc.Height - h; - } + surface_translate_frontbuffer_coords(This, context->win_handle, &dst_rect); device->blitter->set_shader((IWineD3DDevice *) device, This); diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 0147c2f..e1f4282 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -2101,6 +2101,7 @@ HRESULT surface_init(IWineD3DSurfaceImpl *surface, WINED3DSURFTYPE surface_type, UINT width, UINT height, UINT level, BOOL lockable, BOOL discard, WINED3DMULTISAMPLE_TYPE multisample_type, UINT multisample_quality, IWineD3DDeviceImpl *device, DWORD usage, WINED3DFORMAT format, WINED3DPOOL pool, IUnknown *parent, const struct wined3d_parent_ops *parent_ops) DECLSPEC_HIDDEN; +void surface_translate_frontbuffer_coords(IWineD3DSurfaceImpl *surface, HWND window, RECT *rect) DECLSPEC_HIDDEN; /* Predeclare the shared Surface functions */ HRESULT WINAPI IWineD3DBaseSurfaceImpl_QueryInterface(IWineD3DSurface *iface,
1
0
0
0
Juan Lang : rsaenh: Implement CALG_SSL3_SHAMD5 hashing.
by Alexandre Julliard
21 May '10
21 May '10
Module: wine Branch: master Commit: 62d806601bfa992f2e36ff4d208ea9781218bcd6 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=62d806601bfa992f2e36ff4d2…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Thu May 20 17:23:25 2010 -0700 rsaenh: Implement CALG_SSL3_SHAMD5 hashing. --- dlls/rsaenh/implglue.c | 1 + dlls/rsaenh/rsaenh.c | 3 ++- dlls/rsaenh/tests/rsaenh.c | 2 -- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dlls/rsaenh/implglue.c b/dlls/rsaenh/implglue.c index 7ecfc28..c217007 100644 --- a/dlls/rsaenh/implglue.c +++ b/dlls/rsaenh/implglue.c @@ -342,6 +342,7 @@ BOOL encrypt_block_impl(ALG_ID aiAlgid, DWORD dwKeySpec, KEY_CONTEXT *pKeyContex case CALG_RSA_KEYX: case CALG_RSA_SIGN: + case CALG_SSL3_SHAMD5: outlen = inlen = (mp_count_bits(&pKeyContext->rsa.N)+7)/8; if (enc) { if (rsa_exptmod(in, inlen, out, &outlen, dwKeySpec, &pKeyContext->rsa) != CRYPT_OK) { diff --git a/dlls/rsaenh/rsaenh.c b/dlls/rsaenh/rsaenh.c index 8a5be99..89bb786 100644 --- a/dlls/rsaenh/rsaenh.c +++ b/dlls/rsaenh/rsaenh.c @@ -1426,7 +1426,7 @@ static BOOL build_hash_signature(BYTE *pbSignature, DWORD dwLen, ALG_ID aiAlgid, ALG_ID aiAlgid; DWORD dwLen; CONST BYTE abOID[19]; - } aOIDDescriptor[8] = { + } aOIDDescriptor[] = { { CALG_MD2, 18, { 0x30, 0x20, 0x30, 0x0c, 0x06, 0x08, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x02, 0x02, 0x05, 0x00, 0x04, 0x10 } }, { CALG_MD4, 18, { 0x30, 0x20, 0x30, 0x0c, 0x06, 0x08, 0x2a, 0x86, 0x48, @@ -1444,6 +1444,7 @@ static BOOL build_hash_signature(BYTE *pbSignature, DWORD dwLen, ALG_ID aiAlgid, { CALG_SHA_384, 19, { 0x30, 0x51, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0x04, 0x40 } }, + { CALG_SSL3_SHAMD5, 0, { 0 } }, { 0, 0, { 0 } } }; DWORD dwIdxOID, i, j; diff --git a/dlls/rsaenh/tests/rsaenh.c b/dlls/rsaenh/tests/rsaenh.c index 1bab33f..5ee85f4 100644 --- a/dlls/rsaenh/tests/rsaenh.c +++ b/dlls/rsaenh/tests/rsaenh.c @@ -654,9 +654,7 @@ static void test_hashes(void) ok(result, "%08x\n", GetLastError()); ok(len == 128, "expected len 128, got %d\n", len); result = CryptSignHash(hHash, AT_KEYEXCHANGE, NULL, 0, pbSigValue, &len); - todo_wine ok(result, "%08x\n", GetLastError()); - todo_wine ok(!memcmp(pbSigValue, signed_ssl3_shamd5_hash, len), "unexpected value\n"); if (len != 128 || memcmp(pbSigValue, signed_ssl3_shamd5_hash, len)) {
1
0
0
0
← Newer
1
...
25
26
27
28
29
30
31
...
96
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
Results per page:
10
25
50
100
200