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 2020
----- 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
1 participants
743 discussions
Start a n
N
ew thread
Zebediah Figura : quartz: Retrieve the video format directly from the pin.
by Alexandre Julliard
07 May '20
07 May '20
Module: wine Branch: master Commit: 1ba3f252b5d6c8eb082b6517a10596570282bf38 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=1ba3f252b5d6c8eb082b6517…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Wed May 6 19:28:49 2020 -0500 quartz: Retrieve the video format directly from the pin. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/quartz/quartz_private.h | 3 +-- dlls/quartz/video.c | 43 ++++++++++++++++++++++++------------------- dlls/quartz/videorenderer.c | 23 ----------------------- dlls/quartz/vmr9.c | 23 ----------------------- 4 files changed, 25 insertions(+), 67 deletions(-) diff --git a/dlls/quartz/quartz_private.h b/dlls/quartz/quartz_private.h index 9c39b642c4..2aca600074 100644 --- a/dlls/quartz/quartz_private.h +++ b/dlls/quartz/quartz_private.h @@ -31,6 +31,7 @@ #include "wingdi.h" #include "winuser.h" #include "dshow.h" +#include "dvdmedia.h" #include "wine/debug.h" #include "wine/heap.h" #include "wine/strmbase.h" @@ -174,7 +175,6 @@ typedef struct tagBaseControlVideo typedef HRESULT (WINAPI *BaseControlVideo_GetSourceRect)(BaseControlVideo* This, RECT *pSourceRect); typedef HRESULT (WINAPI *BaseControlVideo_GetStaticImage)(BaseControlVideo* This, LONG *pBufferSize, LONG *pDIBImage); typedef HRESULT (WINAPI *BaseControlVideo_GetTargetRect)(BaseControlVideo* This, RECT *pTargetRect); -typedef VIDEOINFOHEADER* (WINAPI *BaseControlVideo_GetVideoFormat)(BaseControlVideo* This); typedef HRESULT (WINAPI *BaseControlVideo_IsDefaultSourceRect)(BaseControlVideo* This); typedef HRESULT (WINAPI *BaseControlVideo_IsDefaultTargetRect)(BaseControlVideo* This); typedef HRESULT (WINAPI *BaseControlVideo_SetDefaultSourceRect)(BaseControlVideo* This); @@ -187,7 +187,6 @@ typedef struct BaseControlVideoFuncTable BaseControlVideo_GetSourceRect pfnGetSourceRect; BaseControlVideo_GetStaticImage pfnGetStaticImage; BaseControlVideo_GetTargetRect pfnGetTargetRect; - BaseControlVideo_GetVideoFormat pfnGetVideoFormat; BaseControlVideo_IsDefaultSourceRect pfnIsDefaultSourceRect; BaseControlVideo_IsDefaultTargetRect pfnIsDefaultTargetRect; BaseControlVideo_SetDefaultSourceRect pfnSetDefaultSourceRect; diff --git a/dlls/quartz/video.c b/dlls/quartz/video.c index 11baee261d..213e3ce92d 100644 --- a/dlls/quartz/video.c +++ b/dlls/quartz/video.c @@ -120,9 +120,24 @@ static HRESULT WINAPI basic_video_Invoke(IBasicVideo *iface, DISPID id, REFIID i return hr; } +static const VIDEOINFOHEADER *get_video_format(BaseControlVideo *video) +{ + /* Members of VIDEOINFOHEADER up to bmiHeader are identical to those of + * VIDEOINFOHEADER2. */ + return (const VIDEOINFOHEADER *)video->pPin->mt.pbFormat; +} + +static const BITMAPINFOHEADER *get_bitmap_header(BaseControlVideo *video) +{ + const AM_MEDIA_TYPE *mt = &video->pPin->mt; + if (IsEqualGUID(&mt->formattype, &FORMAT_VideoInfo)) + return &((VIDEOINFOHEADER *)mt->pbFormat)->bmiHeader; + else + return &((VIDEOINFOHEADER2 *)mt->pbFormat)->bmiHeader; +} + static HRESULT WINAPI basic_video_get_AvgTimePerFrame(IBasicVideo *iface, REFTIME *pAvgTimePerFrame) { - VIDEOINFOHEADER *vih; BaseControlVideo *This = impl_from_IBasicVideo(iface); if (!pAvgTimePerFrame) @@ -132,14 +147,12 @@ static HRESULT WINAPI basic_video_get_AvgTimePerFrame(IBasicVideo *iface, REFTIM TRACE("(%p/%p)->(%p)\n", This, iface, pAvgTimePerFrame); - vih = This->pFuncsTable->pfnGetVideoFormat(This); - *pAvgTimePerFrame = vih->AvgTimePerFrame; + *pAvgTimePerFrame = get_video_format(This)->AvgTimePerFrame; return S_OK; } static HRESULT WINAPI basic_video_get_BitRate(IBasicVideo *iface, LONG *pBitRate) { - VIDEOINFOHEADER *vih; BaseControlVideo *This = impl_from_IBasicVideo(iface); TRACE("(%p/%p)->(%p)\n", This, iface, pBitRate); @@ -149,14 +162,12 @@ static HRESULT WINAPI basic_video_get_BitRate(IBasicVideo *iface, LONG *pBitRate if (!This->pPin->peer) return VFW_E_NOT_CONNECTED; - vih = This->pFuncsTable->pfnGetVideoFormat(This); - *pBitRate = vih->dwBitRate; + *pBitRate = get_video_format(This)->dwBitRate; return S_OK; } static HRESULT WINAPI basic_video_get_BitErrorRate(IBasicVideo *iface, LONG *pBitErrorRate) { - VIDEOINFOHEADER *vih; BaseControlVideo *This = impl_from_IBasicVideo(iface); TRACE("(%p/%p)->(%p)\n", This, iface, pBitErrorRate); @@ -166,37 +177,32 @@ static HRESULT WINAPI basic_video_get_BitErrorRate(IBasicVideo *iface, LONG *pBi if (!This->pPin->peer) return VFW_E_NOT_CONNECTED; - vih = This->pFuncsTable->pfnGetVideoFormat(This); - *pBitErrorRate = vih->dwBitErrorRate; + *pBitErrorRate = get_video_format(This)->dwBitErrorRate; return S_OK; } static HRESULT WINAPI basic_video_get_VideoWidth(IBasicVideo *iface, LONG *pVideoWidth) { - VIDEOINFOHEADER *vih; BaseControlVideo *This = impl_from_IBasicVideo(iface); TRACE("(%p/%p)->(%p)\n", This, iface, pVideoWidth); if (!pVideoWidth) return E_POINTER; - vih = This->pFuncsTable->pfnGetVideoFormat(This); - *pVideoWidth = vih->bmiHeader.biWidth; + *pVideoWidth = get_bitmap_header(This)->biWidth; return S_OK; } static HRESULT WINAPI basic_video_get_VideoHeight(IBasicVideo *iface, LONG *pVideoHeight) { - VIDEOINFOHEADER *vih; BaseControlVideo *This = impl_from_IBasicVideo(iface); TRACE("(%p/%p)->(%p)\n", This, iface, pVideoHeight); if (!pVideoHeight) return E_POINTER; - vih = This->pFuncsTable->pfnGetVideoFormat(This); - *pVideoHeight = abs(vih->bmiHeader.biHeight); + *pVideoHeight = abs(get_bitmap_header(This)->biHeight); return S_OK; } @@ -550,16 +556,15 @@ static HRESULT WINAPI basic_video_SetDefaultDestinationPosition(IBasicVideo *ifa static HRESULT WINAPI basic_video_GetVideoSize(IBasicVideo *iface, LONG *pWidth, LONG *pHeight) { - VIDEOINFOHEADER *vih; BaseControlVideo *This = impl_from_IBasicVideo(iface); + const BITMAPINFOHEADER *bitmap_header = get_bitmap_header(This); TRACE("(%p/%p)->(%p, %p)\n", This, iface, pWidth, pHeight); if (!pWidth || !pHeight) return E_POINTER; - vih = This->pFuncsTable->pfnGetVideoFormat(This); - *pHeight = vih->bmiHeader.biHeight; - *pWidth = vih->bmiHeader.biWidth; + *pHeight = bitmap_header->biHeight; + *pWidth = bitmap_header->biWidth; return S_OK; } diff --git a/dlls/quartz/videorenderer.c b/dlls/quartz/videorenderer.c index 6e31e19695..b7a82e4faa 100644 --- a/dlls/quartz/videorenderer.c +++ b/dlls/quartz/videorenderer.c @@ -352,28 +352,6 @@ static HRESULT WINAPI VideoRenderer_GetTargetRect(BaseControlVideo* iface, RECT return S_OK; } -static VIDEOINFOHEADER* WINAPI VideoRenderer_GetVideoFormat(BaseControlVideo* iface) -{ - struct video_renderer *This = impl_from_BaseControlVideo(iface); - AM_MEDIA_TYPE *pmt; - - TRACE("(%p/%p)\n", This, iface); - - pmt = &This->renderer.sink.pin.mt; - if (IsEqualIID(&pmt->formattype, &FORMAT_VideoInfo)) { - return (VIDEOINFOHEADER*)pmt->pbFormat; - } else if (IsEqualIID(&pmt->formattype, &FORMAT_VideoInfo2)) { - static VIDEOINFOHEADER vih; - VIDEOINFOHEADER2 *vih2 = (VIDEOINFOHEADER2*)pmt->pbFormat; - memcpy(&vih,vih2,sizeof(VIDEOINFOHEADER)); - memcpy(&vih.bmiHeader, &vih2->bmiHeader, sizeof(BITMAPINFOHEADER)); - return &vih; - } else { - ERR("Unknown format type %s\n", qzdebugstr_guid(&pmt->formattype)); - return NULL; - } -} - static HRESULT WINAPI VideoRenderer_IsDefaultSourceRect(BaseControlVideo* iface) { struct video_renderer *This = impl_from_BaseControlVideo(iface); @@ -430,7 +408,6 @@ static const BaseControlVideoFuncTable renderer_BaseControlVideoFuncTable = { VideoRenderer_GetSourceRect, VideoRenderer_GetStaticImage, VideoRenderer_GetTargetRect, - VideoRenderer_GetVideoFormat, VideoRenderer_IsDefaultSourceRect, VideoRenderer_IsDefaultTargetRect, VideoRenderer_SetDefaultSourceRect, diff --git a/dlls/quartz/vmr9.c b/dlls/quartz/vmr9.c index 8fdcb3809b..abca2a03d1 100644 --- a/dlls/quartz/vmr9.c +++ b/dlls/quartz/vmr9.c @@ -772,28 +772,6 @@ static HRESULT WINAPI VMR9_GetTargetRect(BaseControlVideo* This, RECT *pTargetRe return S_OK; } -static VIDEOINFOHEADER* WINAPI VMR9_GetVideoFormat(BaseControlVideo* This) -{ - struct quartz_vmr* pVMR9 = impl_from_BaseControlVideo(This); - AM_MEDIA_TYPE *pmt; - - TRACE("(%p/%p)\n", pVMR9, This); - - pmt = &pVMR9->renderer.sink.pin.mt; - if (IsEqualIID(&pmt->formattype, &FORMAT_VideoInfo)) { - return (VIDEOINFOHEADER*)pmt->pbFormat; - } else if (IsEqualIID(&pmt->formattype, &FORMAT_VideoInfo2)) { - static VIDEOINFOHEADER vih; - VIDEOINFOHEADER2 *vih2 = (VIDEOINFOHEADER2*)pmt->pbFormat; - memcpy(&vih,vih2,sizeof(VIDEOINFOHEADER)); - memcpy(&vih.bmiHeader, &vih2->bmiHeader, sizeof(BITMAPINFOHEADER)); - return &vih; - } else { - ERR("Unknown format type %s\n", qzdebugstr_guid(&pmt->formattype)); - return NULL; - } -} - static HRESULT WINAPI VMR9_IsDefaultSourceRect(BaseControlVideo* This) { struct quartz_vmr* pVMR9 = impl_from_BaseControlVideo(This); @@ -850,7 +828,6 @@ static const BaseControlVideoFuncTable renderer_BaseControlVideoFuncTable = { VMR9_GetSourceRect, VMR9_GetStaticImage, VMR9_GetTargetRect, - VMR9_GetVideoFormat, VMR9_IsDefaultSourceRect, VMR9_IsDefaultTargetRect, VMR9_SetDefaultSourceRect,
1
0
0
0
Zebediah Figura : quartz: Rename "baseControlWindow" to "window".
by Alexandre Julliard
07 May '20
07 May '20
Module: wine Branch: master Commit: 855f17f3498802f8023213127607f37c3a58b88b URL:
https://source.winehq.org/git/wine.git/?a=commit;h=855f17f3498802f802321312…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Wed May 6 19:28:48 2020 -0500 quartz: Rename "baseControlWindow" to "window". Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/quartz/videorenderer.c | 57 +++++++++++++++++++++++---------------------- dlls/quartz/vmr9.c | 46 ++++++++++++++++++------------------ 2 files changed, 52 insertions(+), 51 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=855f17f3498802f80232…
1
0
0
0
Brendan Shanks : user32/tests: Test success for QueryDisplayConfig() and DisplayConfigGetDeviceInfo().
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: 148fc1adb53aa1d78a67b2a0ee5ea8058d92589a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=148fc1adb53aa1d78a67b2a0…
Author: Brendan Shanks <bshanks(a)codeweavers.com> Date: Wed May 6 10:17:30 2020 -0700 user32/tests: Test success for QueryDisplayConfig() and DisplayConfigGetDeviceInfo(). Signed-off-by: Brendan Shanks <bshanks(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/user32/tests/monitor.c | 111 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 110 insertions(+), 1 deletion(-) diff --git a/dlls/user32/tests/monitor.c b/dlls/user32/tests/monitor.c index c3c43d6f60..205df1c293 100644 --- a/dlls/user32/tests/monitor.c +++ b/dlls/user32/tests/monitor.c @@ -1268,6 +1268,98 @@ static void test_EnumDisplayMonitors(void) } } +static void test_QueryDisplayConfig_result(UINT32 paths, const DISPLAYCONFIG_PATH_INFO *pi, UINT32 modes, const DISPLAYCONFIG_MODE_INFO *mi) +{ + UINT32 i; + LONG ret; + DISPLAYCONFIG_SOURCE_DEVICE_NAME source_name; + DISPLAYCONFIG_TARGET_DEVICE_NAME target_name; + DISPLAYCONFIG_TARGET_PREFERRED_MODE preferred_mode; + DISPLAYCONFIG_ADAPTER_NAME adapter_name; + + for (i = 0; i < paths; i++) + { + source_name.header.type = DISPLAYCONFIG_DEVICE_INFO_GET_SOURCE_NAME; + source_name.header.size = sizeof(source_name); + source_name.header.adapterId = pi[i].sourceInfo.adapterId; + source_name.header.id = pi[i].sourceInfo.id; + source_name.viewGdiDeviceName[0] = '\0'; + ret = pDisplayConfigGetDeviceInfo(&source_name.header); + ok(!ret, "Expected 0, got %d\n", ret); + ok(source_name.viewGdiDeviceName[0] != '\0', "Expected GDI device name, got empty string\n"); + + target_name.header.type = DISPLAYCONFIG_DEVICE_INFO_GET_TARGET_NAME; + target_name.header.size = sizeof(target_name); + target_name.header.adapterId = pi[i].targetInfo.adapterId; + target_name.header.id = pi[i].targetInfo.id; + target_name.monitorDevicePath[0] = '\0'; + ret = pDisplayConfigGetDeviceInfo(&target_name.header); + ok(!ret, "Expected 0, got %d\n", ret); + ok(target_name.monitorDevicePath[0] != '\0', "Expected monitor device path, got empty string\n"); + + preferred_mode.header.type = DISPLAYCONFIG_DEVICE_INFO_GET_TARGET_PREFERRED_MODE; + preferred_mode.header.size = sizeof(preferred_mode); + preferred_mode.header.adapterId = pi[i].targetInfo.adapterId; + preferred_mode.header.id = pi[i].targetInfo.id; + preferred_mode.width = preferred_mode.height = 0; + ret = pDisplayConfigGetDeviceInfo(&preferred_mode.header); + ok(!ret, "Expected 0, got %d\n", ret); + ok(preferred_mode.width > 0 && preferred_mode.height > 0, "Expected non-zero height/width, got %ux%u\n", + preferred_mode.width, preferred_mode.height); + + adapter_name.header.type = DISPLAYCONFIG_DEVICE_INFO_GET_ADAPTER_NAME; + adapter_name.header.size = sizeof(adapter_name); + adapter_name.header.adapterId = pi[i].sourceInfo.adapterId; + adapter_name.adapterDevicePath[0] = '\0'; + ret = pDisplayConfigGetDeviceInfo(&adapter_name.header); + ok(!ret, "Expected 0, got %d\n", ret); + ok(adapter_name.adapterDevicePath[0] != '\0', "Expected adapter device path, got empty string\n"); + + /* Check corresponding modes */ + if (pi[i].sourceInfo.modeInfoIdx == DISPLAYCONFIG_PATH_MODE_IDX_INVALID) + { + skip("Path doesn't contain source modeInfoIdx"); + continue; + } + ok(pi[i].sourceInfo.modeInfoIdx < modes, "Expected index <%d, got %d\n", modes, pi[i].sourceInfo.modeInfoIdx); + if (pi[i].sourceInfo.modeInfoIdx >= modes) + continue; + + ok(mi[pi[i].sourceInfo.modeInfoIdx].infoType == DISPLAYCONFIG_MODE_INFO_TYPE_SOURCE, "Expected infoType %d, got %d\n", + DISPLAYCONFIG_MODE_INFO_TYPE_SOURCE, mi[pi[i].sourceInfo.modeInfoIdx].infoType); + ok(pi[i].sourceInfo.id == mi[pi[i].sourceInfo.modeInfoIdx].id, "Expected id %u, got %u\n", + pi[i].sourceInfo.id, mi[pi[i].sourceInfo.modeInfoIdx].id); + ok(pi[i].sourceInfo.adapterId.HighPart == mi[pi[i].sourceInfo.modeInfoIdx].adapterId.HighPart && + pi[i].sourceInfo.adapterId.LowPart == mi[pi[i].sourceInfo.modeInfoIdx].adapterId.LowPart, + "Expected LUID %08x:%08x, got %08x:%08x\n", + pi[i].sourceInfo.adapterId.HighPart, pi[i].sourceInfo.adapterId.LowPart, + mi[pi[i].sourceInfo.modeInfoIdx].adapterId.HighPart, mi[pi[i].sourceInfo.modeInfoIdx].adapterId.LowPart); + ok(mi[pi[i].sourceInfo.modeInfoIdx].sourceMode.width > 0 && mi[pi[i].sourceInfo.modeInfoIdx].sourceMode.height > 0, + "Expected non-zero height/width, got %ux%u\n", + mi[pi[i].sourceInfo.modeInfoIdx].sourceMode.width, mi[pi[i].sourceInfo.modeInfoIdx].sourceMode.height); + + + if (pi[i].targetInfo.modeInfoIdx == DISPLAYCONFIG_PATH_MODE_IDX_INVALID) + { + skip("Path doesn't contain target modeInfoIdx"); + continue; + } + ok(pi[i].targetInfo.modeInfoIdx < modes, "Expected index <%d, got %d\n", modes, pi[i].targetInfo.modeInfoIdx); + if (pi[i].targetInfo.modeInfoIdx >= modes) + continue; + + ok(mi[pi[i].targetInfo.modeInfoIdx].infoType == DISPLAYCONFIG_MODE_INFO_TYPE_TARGET, "Expected infoType %d, got %d\n", + DISPLAYCONFIG_MODE_INFO_TYPE_SOURCE, mi[pi[i].targetInfo.modeInfoIdx].infoType); + ok(pi[i].targetInfo.id == mi[pi[i].targetInfo.modeInfoIdx].id, "Expected id %u, got %u\n", + pi[i].targetInfo.id, mi[pi[i].targetInfo.modeInfoIdx].id); + ok(pi[i].targetInfo.adapterId.HighPart == mi[pi[i].targetInfo.modeInfoIdx].adapterId.HighPart && + pi[i].targetInfo.adapterId.LowPart == mi[pi[i].targetInfo.modeInfoIdx].adapterId.LowPart, + "Expected LUID %08x:%08x, got %08x:%08x\n", + pi[i].targetInfo.adapterId.HighPart, pi[i].targetInfo.adapterId.LowPart, + mi[pi[i].targetInfo.modeInfoIdx].adapterId.HighPart, mi[pi[i].targetInfo.modeInfoIdx].adapterId.LowPart); + } +} + static void test_QueryDisplayConfig(void) { UINT32 paths, modes; @@ -1315,13 +1407,30 @@ static void test_QueryDisplayConfig(void) ret = pQueryDisplayConfig(0, &paths, pi, &modes, mi, NULL); ok(ret == ERROR_INVALID_PARAMETER, "got %d\n", ret); + /* Below this point, test functionality that requires a WDDM driver on Windows */ paths = modes = 1; memset(pi, 0xFF, sizeof(pi[0])); memset(mi, 0xFF, sizeof(mi[0])); ret = pQueryDisplayConfig(QDC_ALL_PATHS, &paths, pi, &modes, mi, NULL); - ok(ret == ERROR_INSUFFICIENT_BUFFER || ret == ERROR_NOT_SUPPORTED, "got %d\n", ret); + if (ret == ERROR_NOT_SUPPORTED) + { + todo_wine + win_skip("QueryDisplayConfig() functionality is unsupported\n"); + return; + } + ok(ret == ERROR_INSUFFICIENT_BUFFER, "got %d\n", ret); ok (paths == 1, "got %u\n", paths); ok (modes == 1, "got %u\n", modes); + + paths = ARRAY_SIZE(pi); + modes = ARRAY_SIZE(mi); + memset(pi, 0xFF, sizeof(pi)); + memset(mi, 0xFF, sizeof(mi)); + ret = pQueryDisplayConfig(QDC_ONLY_ACTIVE_PATHS, &paths, pi, &modes, mi, NULL); + ok(!ret, "got %d\n", ret); + ok(paths > 0 && modes > 0, "got %u, %u\n", paths, modes); + if (!ret && paths > 0 && modes > 0) + test_QueryDisplayConfig_result(paths, pi, modes, mi); } static void test_DisplayConfigGetDeviceInfo(void)
1
0
0
0
Brendan Shanks : user32/tests: Rename DisplayConfig test functions to match style.
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: c95adb32b8795b78565c9a67e46d0a680b4f2841 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c95adb32b8795b78565c9a67…
Author: Brendan Shanks <bshanks(a)codeweavers.com> Date: Wed May 6 10:17:29 2020 -0700 user32/tests: Rename DisplayConfig test functions to match style. Signed-off-by: Brendan Shanks <bshanks(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/user32/tests/monitor.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/dlls/user32/tests/monitor.c b/dlls/user32/tests/monitor.c index fb5e331c25..c3c43d6f60 100644 --- a/dlls/user32/tests/monitor.c +++ b/dlls/user32/tests/monitor.c @@ -1107,7 +1107,7 @@ static void test_work_area(void) DestroyWindow(hwnd); } -static void test_get_display_config_buffer_sizes(void) +static void test_GetDisplayConfigBufferSizes(void) { UINT32 paths, modes; LONG ret; @@ -1268,7 +1268,7 @@ static void test_EnumDisplayMonitors(void) } } -static void test_query_display_config(void) +static void test_QueryDisplayConfig(void) { UINT32 paths, modes; DISPLAYCONFIG_PATH_INFO pi[10]; @@ -1324,7 +1324,7 @@ static void test_query_display_config(void) ok (modes == 1, "got %u\n", modes); } -static void test_display_config_get_device_info(void) +static void test_DisplayConfigGetDeviceInfo(void) { LONG ret; DISPLAYCONFIG_SOURCE_DEVICE_NAME source_name; @@ -1422,9 +1422,9 @@ static void test_display_config(void) return; } - test_get_display_config_buffer_sizes(); - test_query_display_config(); - test_display_config_get_device_info(); + test_GetDisplayConfigBufferSizes(); + test_QueryDisplayConfig(); + test_DisplayConfigGetDeviceInfo(); } START_TEST(monitor)
1
0
0
0
Brendan Shanks : include: Add additional DISPLAYCONFIG defines.
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: d6dd7d0b058092ab0319fa278ecc209409e54485 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d6dd7d0b058092ab0319fa27…
Author: Brendan Shanks <bshanks(a)codeweavers.com> Date: Wed May 6 10:17:28 2020 -0700 include: Add additional DISPLAYCONFIG defines. Signed-off-by: Brendan Shanks <bshanks(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- include/wingdi.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/include/wingdi.h b/include/wingdi.h index de028f5212..d989fb6f71 100644 --- a/include/wingdi.h +++ b/include/wingdi.h @@ -3637,10 +3637,30 @@ typedef struct DISPLAYCONFIG_SDR_WHITE_LEVEL { ULONG SDRWhiteLevel; } DISPLAYCONFIG_SDR_WHITE_LEVEL; +#define DISPLAYCONFIG_PATH_MODE_IDX_INVALID 0xffffffff +#define DISPLAYCONFIG_PATH_TARGET_MODE_IDX_INVALID 0xffff +#define DISPLAYCONFIG_PATH_DESKTOP_IMAGE_IDX_INVALID 0xffff +#define DISPLAYCONFIG_PATH_SOURCE_MODE_IDX_INVALID 0xffff +#define DISPLAYCONFIG_PATH_CLONE_GROUP_INVALID 0xffff + +#define DISPLAYCONFIG_SOURCE_IN_USE 0x00000001 + +#define DISPLAYCONFIG_TARGET_IN_USE 0x00000001 +#define DISPLAYCONFIG_TARGET_FORCIBLE 0x00000002 +#define DISPLAYCONFIG_TARGET_FORCED_AVAILABILITY_BOOT 0x00000004 +#define DISPLAYCONFIG_TARGET_FORCED_AVAILABILITY_PATH 0x00000008 +#define DISPLAYCONFIG_TARGET_FORCED_AVAILABILITY_SYSTEM 0x00000010 +#define DISPLAYCONFIG_TARGET_IS_HMD 0x00000020 + +#define DISPLAYCONFIG_PATH_ACTIVE 0x00000001 +#define DISPLAYCONFIG_PATH_SUPPORT_VIRTUAL_MODE 0x00000008 + /* For GetDisplayConfigBufferSizes */ #define QDC_ALL_PATHS 0x00000001 #define QDC_ONLY_ACTIVE_PATHS 0x00000002 #define QDC_DATABASE_CURRENT 0x00000004 +#define QDC_VIRTUAL_MODE_AWARE 0x00000010 +#define QDC_INCLUDE_HMD 0x00000020 #define GDI_ERROR (~0u) #define HGDI_ERROR ((HANDLE)~(ULONG_PTR)0)
1
0
0
0
Gabriel Ivăncescu : cmd.exe: Don't treat explicit paths as a PATH search list.
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: a19a770f96ca1b09c4bef449c082b7da38964dca URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a19a770f96ca1b09c4bef449…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Tue May 5 16:10:37 2020 +0300 cmd.exe: Don't treat explicit paths as a PATH search list. For example, the explicit path "C:\some;path" is currently treated as if the PATH environment variable is "C:\some;path" which is obviously wrong, and searches for the directories "C:\some" and "path". Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/cmd/wcmdmain.c | 63 +++++++++++++++++++++++++++++-------------------- 1 file changed, 38 insertions(+), 25 deletions(-) diff --git a/programs/cmd/wcmdmain.c b/programs/cmd/wcmdmain.c index 16843e4087..4026f3e6be 100644 --- a/programs/cmd/wcmdmain.c +++ b/programs/cmd/wcmdmain.c @@ -1045,6 +1045,7 @@ void WCMD_run_program (WCHAR *command, BOOL called) WCHAR pathext[MAXSTRING]; WCHAR *firstParam; BOOL extensionsupplied = FALSE; + BOOL explicit_path = FALSE; BOOL status; DWORD len; static const WCHAR envPath[] = {'P','A','T','H','\0'}; @@ -1084,6 +1085,7 @@ void WCMD_run_program (WCHAR *command, BOOL called) /* Reduce pathtosearch to a path with trailing '\' to support c:\a.bat and c:\windows\a.bat syntax */ if (lastSlash) *(lastSlash + 1) = 0x00; + explicit_path = TRUE; } /* Now extract PATHEXT */ @@ -1103,37 +1105,48 @@ void WCMD_run_program (WCHAR *command, BOOL called) BOOL found = FALSE; BOOL inside_quotes = FALSE; - /* Work on the first directory on the search path */ - pos = pathposn; - while ((inside_quotes || *pos != ';') && *pos != 0) + if (explicit_path) { - if (*pos == '"') - inside_quotes = !inside_quotes; - pos++; + lstrcpyW(thisDir, pathposn); + pathposn = NULL; } + else + { + /* Work on the next directory on the search path */ + pos = pathposn; + while ((inside_quotes || *pos != ';') && *pos != 0) + { + if (*pos == '"') + inside_quotes = !inside_quotes; + pos++; + } - if (*pos) { /* Reached semicolon */ - memcpy(thisDir, pathposn, (pos-pathposn) * sizeof(WCHAR)); - thisDir[(pos-pathposn)] = 0x00; - pathposn = pos+1; - } else { /* Reached string end */ - lstrcpyW(thisDir, pathposn); - pathposn = NULL; - } + if (*pos) /* Reached semicolon */ + { + memcpy(thisDir, pathposn, (pos-pathposn) * sizeof(WCHAR)); + thisDir[(pos-pathposn)] = 0x00; + pathposn = pos+1; + } + else /* Reached string end */ + { + lstrcpyW(thisDir, pathposn); + pathposn = NULL; + } - /* Remove quotes */ - length = lstrlenW(thisDir); - if (thisDir[length - 1] == '"') - thisDir[length - 1] = 0; + /* Remove quotes */ + length = lstrlenW(thisDir); + if (thisDir[length - 1] == '"') + thisDir[length - 1] = 0; - if (*thisDir != '"') - lstrcpyW(temp, thisDir); - else - lstrcpyW(temp, thisDir + 1); + if (*thisDir != '"') + lstrcpyW(temp, thisDir); + else + lstrcpyW(temp, thisDir + 1); - /* Since you can have eg. ..\.. on the path, need to expand - to full information */ - GetFullPathNameW(temp, MAX_PATH, thisDir, NULL); + /* Since you can have eg. ..\.. on the path, need to expand + to full information */ + GetFullPathNameW(temp, MAX_PATH, thisDir, NULL); + } /* 1. If extension supplied, see if that file exists */ lstrcatW(thisDir, slashW);
1
0
0
0
Jacek Caban : winegcc: Use --safeseh winebuild option on msvc target.
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: d784de82c835321111a0e2d637e34757a8aed1fd URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d784de82c835321111a0e2d6…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Wed May 6 16:18:41 2020 +0200 winegcc: Use --safeseh winebuild option on msvc target. lld-link requires all x86 object files to be SEH compatible unless it's explicitly disabled. Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- tools/winegcc/winegcc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/winegcc/winegcc.c b/tools/winegcc/winegcc.c index 89f8eca5c2..8a7db2ad34 100644 --- a/tools/winegcc/winegcc.c +++ b/tools/winegcc/winegcc.c @@ -1250,6 +1250,8 @@ static void build(struct options* opts) if (opts->large_address_aware) strarray_add( spec_args, "--large-address-aware" ); } + if (opts->target_platform == PLATFORM_WINDOWS) strarray_add(spec_args, "--safeseh"); + if (entry_point) { strarray_add(spec_args, "--entry");
1
0
0
0
Jacek Caban : winebuild: Introduce --safeseh option that allows marking assembly files as SEH compatible.
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: e4e05cdaab4044b0e3a66723d51e74daf6a6ac35 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=e4e05cdaab4044b0e3a66723…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Wed May 6 16:18:31 2020 +0200 winebuild: Introduce --safeseh option that allows marking assembly files as SEH compatible. Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- tools/winebuild/build.h | 1 + tools/winebuild/main.c | 7 +++++++ tools/winebuild/utils.c | 6 ++++++ tools/winebuild/winebuild.man.in | 3 +++ 4 files changed, 17 insertions(+) diff --git a/tools/winebuild/build.h b/tools/winebuild/build.h index b30785b74a..c162888a03 100644 --- a/tools/winebuild/build.h +++ b/tools/winebuild/build.h @@ -364,6 +364,7 @@ extern int link_ext_symbols; extern int force_pointer_size; extern int unwind_tables; extern int unix_lib; +extern int safe_seh; extern char *input_file_name; extern char *spec_file_name; diff --git a/tools/winebuild/main.c b/tools/winebuild/main.c index 47f2787b10..efb86b705e 100644 --- a/tools/winebuild/main.c +++ b/tools/winebuild/main.c @@ -47,6 +47,7 @@ int link_ext_symbols = 0; int force_pointer_size = 0; int unwind_tables = 0; int unix_lib = 0; +int safe_seh = 0; #ifdef __i386__ enum target_cpu target_cpu = CPU_x86; @@ -290,6 +291,7 @@ static const char usage_str[] = " -N, --dll-name=DLLNAME Set the DLL name (default: from input file name)\n" " -o, --output=NAME Set the output file name (default: stdout)\n" " -r, --res=RSRC.RES Load resources from RSRC.RES\n" +" --safeseh Mark object files as SEH compatible\n" " --save-temps Do not delete the generated intermediate files\n" " --subsystem=SUBSYS Set the subsystem (one of native, windows, console, wince)\n" " -u, --undefined=SYMBOL Add an undefined reference to SYMBOL when linking\n" @@ -324,6 +326,7 @@ enum long_options_values LONG_OPT_NMCMD, LONG_OPT_NXCOMPAT, LONG_OPT_RESOURCES, + LONG_OPT_SAFE_SEH, LONG_OPT_SAVE_TEMPS, LONG_OPT_STATICLIB, LONG_OPT_SUBSYSTEM, @@ -350,6 +353,7 @@ static const struct option long_options[] = { "nm-cmd", 1, 0, LONG_OPT_NMCMD }, { "nxcompat", 1, 0, LONG_OPT_NXCOMPAT }, { "resources", 0, 0, LONG_OPT_RESOURCES }, + { "safeseh", 0, 0, LONG_OPT_SAFE_SEH }, { "save-temps", 0, 0, LONG_OPT_SAVE_TEMPS }, { "subsystem", 1, 0, LONG_OPT_SUBSYSTEM }, { "version", 0, 0, LONG_OPT_VERSION }, @@ -543,6 +547,9 @@ static char **parse_options( int argc, char **argv, DLLSPEC *spec ) if (optarg[0] == 'n' || optarg[0] == 'N') spec->dll_characteristics &= ~IMAGE_DLLCHARACTERISTICS_NX_COMPAT; break; + case LONG_OPT_SAFE_SEH: + safe_seh = 1; + break; case LONG_OPT_RESOURCES: set_exec_mode( MODE_RESOURCES ); break; diff --git a/tools/winebuild/utils.c b/tools/winebuild/utils.c index 669520711c..2a1fc96092 100644 --- a/tools/winebuild/utils.c +++ b/tools/winebuild/utils.c @@ -684,6 +684,12 @@ void output_standard_file_header(void) else output( "/* File generated automatically; do not edit! */\n" ); output( "/* This file can be copied, modified and distributed without restriction. */\n\n" ); + if (safe_seh) + { + output( "\t.def @feat.00; .scl 3; .type 0; .endef\n" ); + output( "\t.globl @feat.00\n" ); + output( ".set @feat.00, 1\n" ); + } } /* dump a byte stream into the assembly code */ diff --git a/tools/winebuild/winebuild.man.in b/tools/winebuild/winebuild.man.in index 9c91c1a504..63ea2a3226 100644 --- a/tools/winebuild/winebuild.man.in +++ b/tools/winebuild/winebuild.man.in @@ -219,6 +219,9 @@ and will automatically be handled correctly (though the .B \-r option will also work for Win32 files). .TP +.B --safeseh +Mark object files as SEH compatible. +.TP .B --save-temps Do not delete the various temporary files that \fBwinebuild\fR generates. .TP
1
0
0
0
Nikolay Sivov : mf: Fix timer instance leak on error path in SetTimer().
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: 35242aa417cd1dd7d61e72a1c8fdabd29517367f URL:
https://source.winehq.org/git/wine.git/?a=commit;h=35242aa417cd1dd7d61e72a1…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Wed May 6 15:49:11 2020 +0300 mf: Fix timer instance leak on error path in SetTimer(). Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mf/session.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/dlls/mf/session.c b/dlls/mf/session.c index d6b881218b..25832afdbb 100644 --- a/dlls/mf/session.c +++ b/dlls/mf/session.c @@ -4093,15 +4093,19 @@ static HRESULT WINAPI present_clock_timer_SetTimer(IMFTimer *iface, DWORD flags, hr = MF_S_CLOCK_STOPPED; if (SUCCEEDED(hr)) + { list_add_tail(&clock->timers, &clock_timer->entry); + if (cancel_key) + { + *cancel_key = &clock_timer->IUnknown_iface; + IUnknown_AddRef(*cancel_key); + } + } LeaveCriticalSection(&clock->cs); - if (SUCCEEDED(hr) && cancel_key) - { - *cancel_key = &clock_timer->IUnknown_iface; - IUnknown_AddRef(*cancel_key); - } + if (FAILED(hr)) + IUnknown_Release(&clock_timer->IUnknown_iface); return hr; }
1
0
0
0
Nikolay Sivov : dwrite: Enable global directional substitution features.
by Alexandre Julliard
06 May '20
06 May '20
Module: wine Branch: master Commit: 1f90b33daf1051800ca96af9db8d3b6f7868b2fe URL:
https://source.winehq.org/git/wine.git/?a=commit;h=1f90b33daf1051800ca96af9…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Wed May 6 15:44:45 2020 +0300 dwrite: Enable global directional substitution features. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dwrite/shape.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/dlls/dwrite/shape.c b/dlls/dwrite/shape.c index e7693b58ae..0372d739b5 100644 --- a/dlls/dwrite/shape.c +++ b/dlls/dwrite/shape.c @@ -301,6 +301,17 @@ HRESULT shape_get_glyphs(struct scriptshaping_context *context, const unsigned i struct shaping_features features = { 0 }; unsigned int i; + if (!context->is_sideways) + { + if (context->is_rtl) + shape_add_feature(&features, DWRITE_MAKE_OPENTYPE_TAG('r','t','l','a')); + else + { + shape_add_feature(&features, DWRITE_MAKE_OPENTYPE_TAG('l','t','r','a')); + shape_add_feature(&features, DWRITE_MAKE_OPENTYPE_TAG('l','t','r','m')); + } + } + for (i = 0; i < ARRAY_SIZE(common_features); ++i) shape_add_feature(&features, common_features[i]);
1
0
0
0
← Newer
1
...
58
59
60
61
62
63
64
...
75
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
Results per page:
10
25
50
100
200