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
October 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
796 discussions
Start a n
N
ew thread
Michael Stefaniuc : wmp: Use wide-char string literals.
by Alexandre Julliard
27 Oct '20
27 Oct '20
Module: wine Branch: master Commit: 6f92e48447c3e18f5c2723dd54028045cffc1759 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6f92e48447c3e18f5c2723dd…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Tue Oct 27 00:06:37 2020 +0100 wmp: Use wide-char string literals. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wmp/oleobj.c | 6 ++---- dlls/wmp/player.c | 29 ++++++++++++----------------- dlls/wmp/tests/media.c | 49 +++++++++++++++++++------------------------------ dlls/wmp/tests/oleobj.c | 8 +++----- 4 files changed, 36 insertions(+), 56 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=6f92e48447c3e18f5c27…
1
0
0
0
Zebediah Figura : ntdll: Semi-stub SystemModuleInformationEx.
by Alexandre Julliard
27 Oct '20
27 Oct '20
Module: wine Branch: master Commit: ebd92b980a46d0ae5b1c211c7b0028565c9c147d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ebd92b980a46d0ae5b1c211c…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Mon Oct 26 18:40:08 2020 -0500 ntdll: Semi-stub SystemModuleInformationEx. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=45666
Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/tests/info.c | 2 +- dlls/ntdll/unix/system.c | 35 +++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 1 deletion(-) diff --git a/dlls/ntdll/tests/info.c b/dlls/ntdll/tests/info.c index 6805cfb6a8e..70ea7d5146b 100644 --- a/dlls/ntdll/tests/info.c +++ b/dlls/ntdll/tests/info.c @@ -500,7 +500,7 @@ static void test_query_module(void) status = pNtQuerySystemInformation(SystemModuleInformationEx, NULL, 0, &size); if (status == STATUS_INVALID_INFO_CLASS) { - todo_wine win_skip("SystemModuleInformationEx is not supported.\n"); + win_skip("SystemModuleInformationEx is not supported.\n"); return; } ok(status == STATUS_INFO_LENGTH_MISMATCH, "got %#x\n", status); diff --git a/dlls/ntdll/unix/system.c b/dlls/ntdll/unix/system.c index 7ac084a9899..faa7532cfef 100644 --- a/dlls/ntdll/unix/system.c +++ b/dlls/ntdll/unix/system.c @@ -2357,6 +2357,41 @@ NTSTATUS WINAPI NtQuerySystemInformation( SYSTEM_INFORMATION_CLASS class, break; } + case SystemModuleInformationEx: + { + /* FIXME: return some fake info for now */ + static const char *fake_modules[] = + { + "\\SystemRoot\\system32\\ntoskrnl.exe", + "\\SystemRoot\\system32\\hal.dll", + "\\SystemRoot\\system32\\drivers\\mountmgr.sys" + }; + + ULONG i; + RTL_PROCESS_MODULE_INFORMATION_EX *module_info = info; + + len = sizeof(*module_info) * ARRAY_SIZE(fake_modules) + sizeof(module_info->NextOffset); + if (len <= size) + { + memset( info, 0, len ); + for (i = 0; i < ARRAY_SIZE(fake_modules); i++) + { + SYSTEM_MODULE *sm = &module_info[i].BaseInfo; + sm->ImageBaseAddress = (char *)0x10000000 + 0x200000 * i; + sm->ImageSize = 0x200000; + sm->LoadOrderIndex = i; + sm->LoadCount = 1; + strcpy( (char *)sm->Name, fake_modules[i] ); + sm->NameOffset = strrchr( fake_modules[i], '\\' ) - fake_modules[i] + 1; + module_info[i].NextOffset = sizeof(*module_info); + } + module_info[ARRAY_SIZE(fake_modules)].NextOffset = 0; + } + else ret = STATUS_INFO_LENGTH_MISMATCH; + + break; + } + case SystemHandleInformation: { struct handle_info *handle_info;
1
0
0
0
Zebediah Figura : ntdll/tests: Add more tests for SystemModuleInformation[Ex].
by Alexandre Julliard
27 Oct '20
27 Oct '20
Module: wine Branch: master Commit: bf9235aa56cb73275c7c76ac3a515fb2d66c943b URL:
https://source.winehq.org/git/wine.git/?a=commit;h=bf9235aa56cb73275c7c76ac…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Mon Oct 26 18:40:07 2020 -0500 ntdll/tests: Add more tests for SystemModuleInformation[Ex]. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/tests/info.c | 71 ++++++++++++++++++++++++++++++++++--------------- include/winternl.h | 9 +++++++ 2 files changed, 58 insertions(+), 22 deletions(-) diff --git a/dlls/ntdll/tests/info.c b/dlls/ntdll/tests/info.c index b09c57b97a7..6805cfb6a8e 100644 --- a/dlls/ntdll/tests/info.c +++ b/dlls/ntdll/tests/info.c @@ -469,37 +469,64 @@ static void test_query_procperf(void) static void test_query_module(void) { + const RTL_PROCESS_MODULE_INFORMATION_EX *infoex; + SYSTEM_MODULE_INFORMATION *info; NTSTATUS status; - ULONG ReturnLength; - ULONG ModuleCount, i; + ULONG size, i; + char *buffer; - ULONG SystemInformationLength = sizeof(SYSTEM_MODULE_INFORMATION); - SYSTEM_MODULE_INFORMATION* smi = HeapAlloc(GetProcessHeap(), 0, SystemInformationLength); - SYSTEM_MODULE* sm; + status = pNtQuerySystemInformation(SystemModuleInformation, NULL, 0, &size); + ok(status == STATUS_INFO_LENGTH_MISMATCH, "got %#x\n", status); + ok(size > 0, "expected nonzero size\n"); - /* Request the needed length */ - status = pNtQuerySystemInformation(SystemModuleInformation, smi, 0, &ReturnLength); - ok( status == STATUS_INFO_LENGTH_MISMATCH, "Expected STATUS_INFO_LENGTH_MISMATCH, got %08x\n", status); - ok( ReturnLength > 0, "Expected a ReturnLength to show the needed length\n"); + info = malloc(size); + status = pNtQuerySystemInformation(SystemModuleInformation, info, size, &size); + ok(!status, "got %#x\n", status); - SystemInformationLength = ReturnLength; - smi = HeapReAlloc(GetProcessHeap(), 0, smi , SystemInformationLength); - status = pNtQuerySystemInformation(SystemModuleInformation, smi, SystemInformationLength, &ReturnLength); - ok( status == STATUS_SUCCESS, "Expected STATUS_SUCCESS, got %08x\n", status); + ok(info->ModulesCount > 0, "Expected some modules to be loaded\n"); - ModuleCount = smi->ModulesCount; - sm = &smi->Modules[0]; - /* our implementation is a stub for now */ - ok( ModuleCount > 0, "Expected some modules to be loaded\n"); + for (i = 0; i < info->ModulesCount; i++) + { + const SYSTEM_MODULE *module = &info->Modules[i]; - /* Loop through all the modules/drivers, Wine doesn't get here (yet) */ - for (i = 0; i < ModuleCount ; i++) + ok(module->LoadOrderIndex == i, "%u: got index %u\n", i, module->LoadOrderIndex); + ok(!!module->ImageBaseAddress, "%u: got NULL address\n", i); + ok(module->ImageSize, "%u: got 0 size\n", i); + ok(module->LoadCount, "%u: got 0 load count\n", i); + } + + free(info); + + status = pNtQuerySystemInformation(SystemModuleInformationEx, NULL, 0, &size); + if (status == STATUS_INVALID_INFO_CLASS) { - ok( i == sm->LoadOrderIndex, "LoadOrderIndex (%d) should have matched %u\n", sm->LoadOrderIndex, i); - sm++; + todo_wine win_skip("SystemModuleInformationEx is not supported.\n"); + return; + } + ok(status == STATUS_INFO_LENGTH_MISMATCH, "got %#x\n", status); + ok(size > 0, "expected nonzero size\n"); + + buffer = malloc(size); + status = pNtQuerySystemInformation(SystemModuleInformationEx, buffer, size, &size); + ok(!status, "got %#x\n", status); + + infoex = (const void *)buffer; + for (i = 0; infoex->NextOffset; i++) + { + const SYSTEM_MODULE *module = &infoex->BaseInfo; + + ok(module->LoadOrderIndex == i, "%u: got index %u\n", i, module->LoadOrderIndex); + ok(!!module->ImageBaseAddress, "%u: got NULL address\n", i); + ok(module->ImageSize, "%u: got 0 size\n", i); + ok(module->LoadCount, "%u: got 0 load count\n", i); + + infoex = (const void *)((const char *)infoex + infoex->NextOffset); } + ok(((char *)infoex - buffer) + sizeof(infoex->NextOffset) == size, + "got size %u, null terminator %u\n", size, (char *)infoex - buffer); + + free(buffer); - HeapFree( GetProcessHeap(), 0, smi); } static void test_query_handle(void) diff --git a/include/winternl.h b/include/winternl.h index fbce63655ba..bd6a2c35932 100644 --- a/include/winternl.h +++ b/include/winternl.h @@ -2805,6 +2805,15 @@ typedef struct _SYSTEM_MODULE_INFORMATION #define PROCESS_CREATE_FLAGS_SUSPENDED 0x00000200 #define PROCESS_CREATE_FLAGS_EXTENDED_UNKNOWN 0x00000400 +typedef struct _RTL_PROCESS_MODULE_INFORMATION_EX +{ + USHORT NextOffset; + SYSTEM_MODULE BaseInfo; + ULONG ImageCheckSum; + ULONG TimeDateStamp; + void *DefaultBase; +} RTL_PROCESS_MODULE_INFORMATION_EX; + #define THREAD_CREATE_FLAGS_CREATE_SUSPENDED 0x00000001 #define THREAD_CREATE_FLAGS_SKIP_THREAD_ATTACH 0x00000002 #define THREAD_CREATE_FLAGS_HIDE_FROM_DEBUGGER 0x00000004
1
0
0
0
Zebediah Figura : ntdll: Don't check "info" for NULL in NtQuerySystemInformation(SystemModuleInformation).
by Alexandre Julliard
27 Oct '20
27 Oct '20
Module: wine Branch: master Commit: 6257da8b429e251637d32608f92c934c2e91ad5d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6257da8b429e251637d32608…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Mon Oct 26 18:40:06 2020 -0500 ntdll: Don't check "info" for NULL in NtQuerySystemInformation(SystemModuleInformation). Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/unix/system.c | 37 +++++++++++++++++-------------------- 1 file changed, 17 insertions(+), 20 deletions(-) diff --git a/dlls/ntdll/unix/system.c b/dlls/ntdll/unix/system.c index 6ff277c2d0c..7ac084a9899 100644 --- a/dlls/ntdll/unix/system.c +++ b/dlls/ntdll/unix/system.c @@ -2333,30 +2333,27 @@ NTSTATUS WINAPI NtQuerySystemInformation( SYSTEM_INFORMATION_CLASS class, "\\SystemRoot\\system32\\drivers\\mountmgr.sys" }; - if (!info) ret = STATUS_ACCESS_VIOLATION; - else - { - ULONG i; - SYSTEM_MODULE_INFORMATION *smi = info; + ULONG i; + SYSTEM_MODULE_INFORMATION *smi = info; - len = offsetof( SYSTEM_MODULE_INFORMATION, Modules[ARRAY_SIZE(fake_modules)] ); - if (len <= size) + len = offsetof( SYSTEM_MODULE_INFORMATION, Modules[ARRAY_SIZE(fake_modules)] ); + if (len <= size) + { + memset( smi, 0, len ); + for (i = 0; i < ARRAY_SIZE(fake_modules); i++) { - memset( smi, 0, len ); - for (i = 0; i < ARRAY_SIZE(fake_modules); i++) - { - SYSTEM_MODULE *sm = &smi->Modules[i]; - sm->ImageBaseAddress = (char *)0x10000000 + 0x200000 * i; - sm->ImageSize = 0x200000; - sm->LoadOrderIndex = i; - sm->LoadCount = 1; - strcpy( (char *)sm->Name, fake_modules[i] ); - sm->NameOffset = strrchr( fake_modules[i], '\\' ) - fake_modules[i] + 1; - } - smi->ModulesCount = i; + SYSTEM_MODULE *sm = &smi->Modules[i]; + sm->ImageBaseAddress = (char *)0x10000000 + 0x200000 * i; + sm->ImageSize = 0x200000; + sm->LoadOrderIndex = i; + sm->LoadCount = 1; + strcpy( (char *)sm->Name, fake_modules[i] ); + sm->NameOffset = strrchr( fake_modules[i], '\\' ) - fake_modules[i] + 1; } - else ret = STATUS_INFO_LENGTH_MISMATCH; + smi->ModulesCount = i; } + else ret = STATUS_INFO_LENGTH_MISMATCH; + break; }
1
0
0
0
Derek Lesho : winegstreamer: Insert audioconvert into decoded audio streams.
by Alexandre Julliard
26 Oct '20
26 Oct '20
Module: wine Branch: master Commit: 93107c08f5aa7f37ad7ece9cd7ca248dba3030ce URL:
https://source.winehq.org/git/wine.git/?a=commit;h=93107c08f5aa7f37ad7ece9c…
Author: Derek Lesho <dlesho(a)codeweavers.com> Date: Thu Oct 8 16:49:04 2020 -0500 winegstreamer: Insert audioconvert into decoded audio streams. Signed-off-by: Derek Lesho <dlesho(a)codeweavers.com> Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winegstreamer/media_source.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/dlls/winegstreamer/media_source.c b/dlls/winegstreamer/media_source.c index 3371585328d..0991710755c 100644 --- a/dlls/winegstreamer/media_source.c +++ b/dlls/winegstreamer/media_source.c @@ -410,6 +410,19 @@ static HRESULT media_stream_connect_to_sink(struct media_stream *stream) gst_element_sync_state_with_parent(videoconvert); } + else if (!strcmp(stream_type, "audio/x-raw")) + { + GstElement *audioconvert = gst_element_factory_make("audioconvert", NULL); + + gst_bin_add(GST_BIN(stream->parent_source->container), audioconvert); + + stream->my_sink = gst_element_get_static_pad(audioconvert, "sink"); + + if (!gst_element_link(audioconvert, stream->appsink)) + return E_FAIL; + + gst_element_sync_state_with_parent(audioconvert); + } else { stream->my_sink = gst_element_get_static_pad(stream->appsink, "sink");
1
0
0
0
Derek Lesho : winegstreamer: Insert videoconvert into decoded-video streams.
by Alexandre Julliard
26 Oct '20
26 Oct '20
Module: wine Branch: master Commit: 528e6870adaa934fdd1cf7d48343e82aeaa06905 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=528e6870adaa934fdd1cf7d4…
Author: Derek Lesho <dlesho(a)codeweavers.com> Date: Tue Oct 13 10:26:42 2020 -0500 winegstreamer: Insert videoconvert into decoded-video streams. Signed-off-by: Derek Lesho <dlesho(a)codeweavers.com> Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winegstreamer/media_source.c | 125 +++++++++++++++++++++++++++++++++----- 1 file changed, 111 insertions(+), 14 deletions(-) diff --git a/dlls/winegstreamer/media_source.c b/dlls/winegstreamer/media_source.c index 5f3c43a0204..3371585328d 100644 --- a/dlls/winegstreamer/media_source.c +++ b/dlls/winegstreamer/media_source.c @@ -384,6 +384,43 @@ static const IMFMediaStreamVtbl media_stream_vtbl = media_stream_RequestSample }; +/* Setup a chain of elements which should hopefully allow transformations to any IMFMediaType + the user throws at us through gstreamer's caps negotiation. */ +static HRESULT media_stream_connect_to_sink(struct media_stream *stream) +{ + GstCaps *source_caps = gst_pad_get_current_caps(stream->their_src); + const gchar *stream_type; + + if (!source_caps) + return E_FAIL; + + stream_type = gst_structure_get_name(gst_caps_get_structure(source_caps, 0)); + gst_caps_unref(source_caps); + + if (!strcmp(stream_type, "video/x-raw")) + { + GstElement *videoconvert = gst_element_factory_make("videoconvert", NULL); + + gst_bin_add(GST_BIN(stream->parent_source->container), videoconvert); + + stream->my_sink = gst_element_get_static_pad(videoconvert, "sink"); + + if (!gst_element_link(videoconvert, stream->appsink)) + return E_FAIL; + + gst_element_sync_state_with_parent(videoconvert); + } + else + { + stream->my_sink = gst_element_get_static_pad(stream->appsink, "sink"); + } + + if (gst_pad_link(stream->their_src, stream->my_sink) != GST_PAD_LINK_OK) + return E_FAIL; + + return S_OK; +} + static HRESULT new_media_stream(struct media_source *source, GstPad *pad, DWORD stream_id, struct media_stream **out_stream) { struct media_stream *object = heap_alloc_zero(sizeof(*object)); @@ -414,8 +451,8 @@ static HRESULT new_media_stream(struct media_source *source, GstPad *pad, DWORD g_object_set(object->appsink, "sync", FALSE, NULL); g_object_set(object->appsink, "max-buffers", 5, NULL); - object->my_sink = gst_element_get_static_pad(object->appsink, "sink"); - gst_pad_link(object->their_src, object->my_sink); + if (FAILED(hr = media_stream_connect_to_sink(object))) + goto fail; gst_element_sync_state_with_parent(object->appsink); @@ -435,28 +472,88 @@ static HRESULT media_stream_init_desc(struct media_stream *stream) { GstCaps *current_caps = gst_pad_get_current_caps(stream->their_src); IMFMediaTypeHandler *type_handler; + IMFMediaType **stream_types = NULL; IMFMediaType *stream_type = NULL; + DWORD type_count = 0; + const gchar *major_type; + unsigned int i; HRESULT hr; - stream_type = mf_media_type_from_caps(current_caps); - gst_caps_unref(current_caps); - if (!stream_type) - return E_FAIL; + major_type = gst_structure_get_name(gst_caps_get_structure(current_caps, 0)); + + if (!strcmp(major_type, "video/x-raw")) + { + /* These are the most common native output types of decoders: +
https://docs.microsoft.com/en-us/windows/win32/medfound/mft-decoder-expose-…
*/ + static const GUID *const video_types[] = + { + &MFVideoFormat_NV12, + &MFVideoFormat_YV12, + &MFVideoFormat_YUY2, + &MFVideoFormat_IYUV, + &MFVideoFormat_I420, + }; - hr = MFCreateStreamDescriptor(stream->stream_id, 1, &stream_type, &stream->descriptor); + IMFMediaType *base_type = mf_media_type_from_caps(current_caps); + GUID base_subtype; - IMFMediaType_Release(stream_type); + IMFMediaType_GetGUID(base_type, &MF_MT_SUBTYPE, &base_subtype); - if (FAILED(hr)) - return hr; + stream_types = heap_alloc( sizeof(IMFMediaType *) * ARRAY_SIZE(video_types) + 1); - if (FAILED(hr = IMFStreamDescriptor_GetMediaTypeHandler(stream->descriptor, &type_handler))) - return hr; + stream_types[0] = base_type; + type_count = 1; - hr = IMFMediaTypeHandler_SetCurrentMediaType(type_handler, stream_type); + for (i = 0; i < ARRAY_SIZE(video_types); i++) + { + IMFMediaType *new_type; - IMFMediaTypeHandler_Release(type_handler); + if (IsEqualGUID(&base_subtype, video_types[i])) + continue; + if (FAILED(hr = MFCreateMediaType(&new_type))) + goto done; + stream_types[type_count++] = new_type; + + if (FAILED(hr = IMFMediaType_CopyAllItems(base_type, (IMFAttributes *) new_type))) + goto done; + if (FAILED(hr = IMFMediaType_SetGUID(new_type, &MF_MT_SUBTYPE, video_types[i]))) + goto done; + } + } + else + { + stream_type = mf_media_type_from_caps(current_caps); + if (stream_type) + { + stream_types = &stream_type; + type_count = 1; + } + } + + if (!type_count) + { + ERR("Failed to establish an IMFMediaType from any of the possible stream caps!\n"); + return E_FAIL; + } + + if (FAILED(hr = MFCreateStreamDescriptor(stream->stream_id, type_count, stream_types, &stream->descriptor))) + goto done; + + if (FAILED(hr = IMFStreamDescriptor_GetMediaTypeHandler(stream->descriptor, &type_handler))) + goto done; + + if (FAILED(hr = IMFMediaTypeHandler_SetCurrentMediaType(type_handler, stream_types[0]))) + goto done; + +done: + gst_caps_unref(current_caps); + if (type_handler) + IMFMediaTypeHandler_Release(type_handler); + for (i = 0; i < type_count; i++) + IMFMediaType_Release(stream_types[i]); + if (stream_types != &stream_type) + heap_free(stream_types); return hr; }
1
0
0
0
Myah Caron : kernelbase: Implement VirtualAlloc2.
by Alexandre Julliard
26 Oct '20
26 Oct '20
Module: wine Branch: master Commit: c55349f6c8aa12801666145f0e345fbe3e6e11c3 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c55349f6c8aa12801666145f…
Author: Myah Caron <qsniyg(a)protonmail.com> Date: Sat Oct 17 01:44:52 2020 +0000 kernelbase: Implement VirtualAlloc2. Signed-off-by: Myah Caron <qsniyg(a)protonmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernelbase/kernelbase.spec | 1 + dlls/kernelbase/memory.c | 15 +++++++++++++++ include/winbase.h | 1 + 3 files changed, 17 insertions(+) diff --git a/dlls/kernelbase/kernelbase.spec b/dlls/kernelbase/kernelbase.spec index 9c7babde7fd..da35b5e5c6e 100644 --- a/dlls/kernelbase/kernelbase.spec +++ b/dlls/kernelbase/kernelbase.spec @@ -1672,6 +1672,7 @@ # @ stub VerifyPackageId # @ stub VerifyPackageRelativeApplicationId # @ stub VerifyScripts +@ stdcall VirtualAlloc2(long ptr long long long ptr long) @ stdcall VirtualAlloc(ptr long long long) @ stdcall VirtualAllocEx(long ptr long long long) @ stdcall VirtualAllocExNuma(long ptr long long long long) diff --git a/dlls/kernelbase/memory.c b/dlls/kernelbase/memory.c index 4ead38f2bc0..2bfd3893e8e 100644 --- a/dlls/kernelbase/memory.c +++ b/dlls/kernelbase/memory.c @@ -299,6 +299,21 @@ LPVOID WINAPI DECLSPEC_HOTPATCH VirtualAllocEx( HANDLE process, void *addr, SIZE } +/*********************************************************************** + * VirtualAlloc2 (kernelbase.@) + */ +LPVOID WINAPI DECLSPEC_HOTPATCH VirtualAlloc2( HANDLE process, void *addr, SIZE_T size, + DWORD type, DWORD protect, + MEM_EXTENDED_PARAMETER *parameters, ULONG count ) +{ + LPVOID ret = addr; + + if (!set_ntstatus( NtAllocateVirtualMemoryEx( process, &ret, &size, type, protect, parameters, count ))) + return NULL; + return ret; +} + + /*********************************************************************** * VirtualFree (kernelbase.@) */ diff --git a/include/winbase.h b/include/winbase.h index f1c3198c21a..82797efc2b0 100644 --- a/include/winbase.h +++ b/include/winbase.h @@ -2744,6 +2744,7 @@ WINBASEAPI BOOL WINAPI VerifyVersionInfoA(LPOSVERSIONINFOEXA,DWORD,DWORDL WINBASEAPI BOOL WINAPI VerifyVersionInfoW(LPOSVERSIONINFOEXW,DWORD,DWORDLONG); #define VerifyVersionInfo WINELIB_NAME_AW(VerifyVersionInfo) WINBASEAPI LPVOID WINAPI VirtualAlloc(LPVOID,SIZE_T,DWORD,DWORD); +WINBASEAPI LPVOID WINAPI VirtualAlloc2(HANDLE,LPVOID,SIZE_T,DWORD,DWORD,MEM_EXTENDED_PARAMETER*,ULONG); WINBASEAPI LPVOID WINAPI VirtualAllocEx(HANDLE,LPVOID,SIZE_T,DWORD,DWORD); WINBASEAPI LPVOID WINAPI VirtualAllocExNuma(HANDLE,void*,SIZE_T,DWORD,DWORD,DWORD); WINBASEAPI BOOL WINAPI VirtualFree(LPVOID,SIZE_T,DWORD);
1
0
0
0
Myah Caron : ntdll: Stub NtAllocateVirtualMemoryEx.
by Alexandre Julliard
26 Oct '20
26 Oct '20
Module: wine Branch: master Commit: d453db5ba205fc687f48eae9d9a66afcaa4c5d93 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d453db5ba205fc687f48eae9…
Author: Myah Caron <qsniyg(a)protonmail.com> Date: Sat Oct 17 01:44:17 2020 +0000 ntdll: Stub NtAllocateVirtualMemoryEx. Signed-off-by: Myah Caron <qsniyg(a)protonmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/ntdll.spec | 2 ++ dlls/ntdll/tests/virtual.c | 21 +++++++++++++++++++++ dlls/ntdll/unix/virtual.c | 15 +++++++++++++++ include/winternl.h | 1 + 4 files changed, 39 insertions(+) diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec index ca427c46c04..dbd2eab1fa1 100644 --- a/dlls/ntdll/ntdll.spec +++ b/dlls/ntdll/ntdll.spec @@ -141,6 +141,7 @@ # @ stub NtAllocateUserPhysicalPages @ stdcall -syscall NtAllocateUuids(ptr ptr ptr ptr) @ stdcall -syscall NtAllocateVirtualMemory(long ptr long ptr long long) +@ stdcall -syscall NtAllocateVirtualMemoryEx(long ptr ptr long long ptr long) @ stdcall -syscall NtAreMappedFilesTheSame(ptr ptr) @ stdcall -syscall NtAssignProcessToJobObject(long long) @ stub NtCallbackReturn @@ -1146,6 +1147,7 @@ # @ stub ZwAllocateUserPhysicalPages @ stdcall -private -syscall ZwAllocateUuids(ptr ptr ptr ptr) NtAllocateUuids @ stdcall -private -syscall ZwAllocateVirtualMemory(long ptr long ptr long long) NtAllocateVirtualMemory +@ stdcall -private -syscall ZwAllocateVirtualMemoryEx(long ptr ptr long long ptr long) NtAllocateVirtualMemoryEx @ stdcall -private -syscall ZwAreMappedFilesTheSame(ptr ptr) NtAreMappedFilesTheSame @ stdcall -private -syscall ZwAssignProcessToJobObject(long long) NtAssignProcessToJobObject @ stub ZwCallbackReturn diff --git a/dlls/ntdll/tests/virtual.c b/dlls/ntdll/tests/virtual.c index 7049f234a9f..9c2cf824018 100644 --- a/dlls/ntdll/tests/virtual.c +++ b/dlls/ntdll/tests/virtual.c @@ -34,6 +34,8 @@ static NTSTATUS (WINAPI *pRtlCreateUserStack)(SIZE_T, SIZE_T, ULONG, SIZE_T, SIZ static ULONG64 (WINAPI *pRtlGetEnabledExtendedFeatures)(ULONG64); static NTSTATUS (WINAPI *pRtlFreeUserStack)(void *); static BOOL (WINAPI *pIsWow64Process)(HANDLE, PBOOL); +static NTSTATUS (WINAPI *pNtAllocateVirtualMemoryEx)(HANDLE, PVOID *, SIZE_T *, ULONG, ULONG, + MEM_EXTENDED_PARAMETER *, ULONG); static const BOOL is_win64 = sizeof(void*) != sizeof(int); static SYSTEM_BASIC_INFORMATION sbi; @@ -215,6 +217,24 @@ static void test_NtAllocateVirtualMemory(void) size = 0; status = NtFreeVirtualMemory(NtCurrentProcess(), &addr1, &size, MEM_RELEASE); ok(status == STATUS_SUCCESS, "NtFreeVirtualMemory failed\n"); + + if (!pNtAllocateVirtualMemoryEx) + { + win_skip("NtAllocateVirtualMemoryEx() is missing\n"); + return; + } + + /* simple allocation should succeed */ + size = 0x1000; + addr1 = NULL; + status = pNtAllocateVirtualMemoryEx(NtCurrentProcess(), &addr1, &size, MEM_RESERVE | MEM_COMMIT, + PAGE_EXECUTE_READWRITE, NULL, 0); + ok(status == STATUS_SUCCESS, "NtAllocateVirtualMemoryEx returned %08x\n", status); + + /* specifying a count of >0 with NULL parameters should fail */ + status = pNtAllocateVirtualMemoryEx(NtCurrentProcess(), &addr1, &size, MEM_RESERVE | MEM_COMMIT, + PAGE_EXECUTE_READWRITE, NULL, 1); + ok(status == STATUS_INVALID_PARAMETER, "NtAllocateVirtualMemoryEx returned %08x\n", status); } static void test_RtlCreateUserStack(void) @@ -648,6 +668,7 @@ START_TEST(virtual) pRtlCreateUserStack = (void *)GetProcAddress(mod, "RtlCreateUserStack"); pRtlFreeUserStack = (void *)GetProcAddress(mod, "RtlFreeUserStack"); pRtlGetEnabledExtendedFeatures = (void *)GetProcAddress(mod, "RtlGetEnabledExtendedFeatures"); + pNtAllocateVirtualMemoryEx = (void *)GetProcAddress(mod, "NtAllocateVirtualMemoryEx"); NtQuerySystemInformation(SystemBasicInformation, &sbi, sizeof(sbi), NULL); trace("system page size %#x\n", sbi.PageSize); diff --git a/dlls/ntdll/unix/virtual.c b/dlls/ntdll/unix/virtual.c index d79e3de662e..614159b7d90 100644 --- a/dlls/ntdll/unix/virtual.c +++ b/dlls/ntdll/unix/virtual.c @@ -3452,6 +3452,21 @@ NTSTATUS WINAPI NtAllocateVirtualMemory( HANDLE process, PVOID *ret, ULONG_PTR z return status; } +/*********************************************************************** + * NtAllocateVirtualMemoryEx (NTDLL.@) + * ZwAllocateVirtualMemoryEx (NTDLL.@) + */ +NTSTATUS WINAPI NtAllocateVirtualMemoryEx( HANDLE process, PVOID *ret, SIZE_T *size_ptr, ULONG type, + ULONG protect, MEM_EXTENDED_PARAMETER *parameters, + ULONG count ) +{ + if (count && !parameters) return STATUS_INVALID_PARAMETER; + + if (count) FIXME( "Ignoring %d extended parameters %p\n", count, parameters ); + + return NtAllocateVirtualMemory( process, ret, 0, size_ptr, type, protect ); +} + /*********************************************************************** * NtFreeVirtualMemory (NTDLL.@) diff --git a/include/winternl.h b/include/winternl.h index 89ea58c2d93..fbce63655ba 100644 --- a/include/winternl.h +++ b/include/winternl.h @@ -3020,6 +3020,7 @@ NTSYSAPI NTSTATUS WINAPI NtAlertThread(HANDLE ThreadHandle); NTSYSAPI NTSTATUS WINAPI NtAllocateLocallyUniqueId(PLUID lpLuid); NTSYSAPI NTSTATUS WINAPI NtAllocateUuids(PULARGE_INTEGER,PULONG,PULONG,PUCHAR); NTSYSAPI NTSTATUS WINAPI NtAllocateVirtualMemory(HANDLE,PVOID*,ULONG_PTR,SIZE_T*,ULONG,ULONG); +NTSYSAPI NTSTATUS WINAPI NtAllocateVirtualMemoryEx(HANDLE,PVOID*,SIZE_T*,ULONG,ULONG,MEM_EXTENDED_PARAMETER*,ULONG); NTSYSAPI NTSTATUS WINAPI NtAreMappedFilesTheSame(PVOID,PVOID); NTSYSAPI NTSTATUS WINAPI NtAssignProcessToJobObject(HANDLE,HANDLE); NTSYSAPI NTSTATUS WINAPI NtCallbackReturn(PVOID,ULONG,NTSTATUS);
1
0
0
0
Myah Caron : include: Introduce MEM_EXTENDED_PARAMETER.
by Alexandre Julliard
26 Oct '20
26 Oct '20
Module: wine Branch: master Commit: 3c8832711ea75f6a2b9d536050d21a6d39f96cb5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3c8832711ea75f6a2b9d5360…
Author: Myah Caron <qsniyg(a)protonmail.com> Date: Sat Oct 17 01:43:47 2020 +0000 include: Introduce MEM_EXTENDED_PARAMETER. Signed-off-by: Myah Caron <qsniyg(a)protonmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- include/winnt.h | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/include/winnt.h b/include/winnt.h index 10b3253923b..1945ee82eab 100644 --- a/include/winnt.h +++ b/include/winnt.h @@ -736,6 +736,35 @@ typedef struct _MEMORY_BASIC_INFORMATION DWORD Type; } MEMORY_BASIC_INFORMATION, *PMEMORY_BASIC_INFORMATION; +#define MEM_EXTENDED_PARAMETER_TYPE_BITS 8 + +typedef enum MEM_EXTENDED_PARAMETER_TYPE { + MemExtendedParameterInvalidType = 0, + MemExtendedParameterAddressRequirements, + MemExtendedParameterNumaNode, + MemExtendedParameterPartitionHandle, + MemExtendedParameterUserPhysicalHandle, + MemExtendedParameterAttributeFlags, + MemExtendedParameterMax +} MEM_EXTENDED_PARAMETER_TYPE, *PMEM_EXTENDED_PARAMETER_TYPE; + +typedef struct DECLSPEC_ALIGN(8) MEM_EXTENDED_PARAMETER { + struct + { + DWORD64 Type : MEM_EXTENDED_PARAMETER_TYPE_BITS; + DWORD64 Reserved : 64 - MEM_EXTENDED_PARAMETER_TYPE_BITS; + } DUMMYSTRUCTNAME; + + union + { + DWORD64 ULong64; + PVOID Pointer; + SIZE_T Size; + HANDLE Handle; + DWORD ULong; + } DUMMYUNIONNAME; +} MEM_EXTENDED_PARAMETER, *PMEM_EXTENDED_PARAMETER; + #define PAGE_NOACCESS 0x01 #define PAGE_READONLY 0x02 #define PAGE_READWRITE 0x04
1
0
0
0
Zebediah Figura : ntdll: Stub NtQuerySystemInformation(SystemExtendedProcessInformation).
by Alexandre Julliard
26 Oct '20
26 Oct '20
Module: wine Branch: master Commit: ab1469597ab3382059ce4ed99b1481fd692678f9 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ab1469597ab3382059ce4ed9…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Sat Oct 24 10:47:15 2020 -0500 ntdll: Stub NtQuerySystemInformation(SystemExtendedProcessInformation). Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=46870
Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/unix/system.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dlls/ntdll/unix/system.c b/dlls/ntdll/unix/system.c index b85a3c7b6ad..6ff277c2d0c 100644 --- a/dlls/ntdll/unix/system.c +++ b/dlls/ntdll/unix/system.c @@ -2615,6 +2615,12 @@ NTSTATUS WINAPI NtQuerySystemInformation( SYSTEM_INFORMATION_CLASS class, break; } + case SystemExtendedProcessInformation: + FIXME("SystemExtendedProcessInformation, size %u, info %p, stub!\n", size, info); + memset( info, 0, size ); + ret = STATUS_SUCCESS; + break; + default: FIXME( "(0x%08x,%p,0x%08x,%p) stub\n", class, info, size, ret_size );
1
0
0
0
← Newer
1
...
8
9
10
11
12
13
14
...
80
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
Results per page:
10
25
50
100
200