Fixes Sim City 3000 Building Architect.
--
v3: ddraw/tests: Add tests for multiple devices.
ddraw: Support multiple devices per ddraw object.
ddraw: Sync wined3d render target in d3d_device_sync_rendertarget().
ddraw: Store wined3d state in d3d_device.
wined3d: Factor out wined3d_texture_set_lod() function.
ddraw: Don't apply state in ddraw_surface_blt().
ddraw: Store matrix handle in the global table.
ddraw: Store surface handles in the global table.
ddraw: Store material handles in the global table.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5329
This fixes a performance regression introduced by 8b3944e1341baaf693927c8b758851d2dbba725a ("ntdll: Only allocate debug info in critical sections with RTL_CRITICAL_SECTION_FLAG_FORCE_DEBUG_INFO.").
Critical section was using a fallback semaphore path if no debug info is present. That was apparently to support MakeCriticalSectionGlobal() which was deprecated and removed from kernel32 exports around Win2000.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5379
@rbernon The change which the blamed commit (unintentionally) introduced is that after loosing debug info critical sections started to use slower semaphore path. I sent a patch for that (https://gitlab.winehq.org/wine/wine/-/merge_requests/5379) which fixes mentioned 2 mf tests here. But I think that blamed patch most likely only uncovered a pre-existing race in either mf implementation or mf tests, I didn't debug that part.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5261#note_65695
This matches the Windows behavior: the contents/size of an IMMDeviceCollection do not change after it's created. Any unplugged devices remain in the collection (but with a changed state).
This shouldn't change anything on Wine since it currently doesn't add/remove devices after initialization, but is needed to add that in the future.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5376
Since we are adding more and more media formats to wg_format, the current wg_format struct is getting ugly.
Everytime we add a video format, we need to duplicate width, height, fps. Everytime we add a audio format, we need to duplicate channels, rate. So it would be better if we could share width, height, fps fields between different video formats, also share channels and rate fields between different audio formats.
What makes me found the current wg_format is not in a good shape is when I was writting code for Proton, I found that I need to write some code like this if want to get width/height/fps from a wg_format:
```
static bool get_video_info_from_wg_format(struct wg_format *format,
int32_t *width, int32_t *height, uint32_t *fps_n, uint32_t *fps_d)
{
switch (format->major_type)
{
case WG_MAJOR_TYPE_VIDEO:
*width = format->u.video.width;
*height = format->u.video.height;
*fps_n = format->u.video.fps_n;
*fps_d = format->u.video.fps_d;
return true;
case WG_MAJOR_TYPE_VIDEO_CINEPAK:
*width = format->u.video_cinepak.width;
*height = format->u.video_cinepak.height;
*fps_n = format->u.video_cinepak.fps_n;
*fps_d = format->u.video_cinepak.fps_d;
return true;
case WG_MAJOR_TYPE_VIDEO_H264:
*width = format->u.video_h264.width;
*height = format->u.video_h264.height;
*fps_n = format->u.video_h264.fps_n;
*fps_d = format->u.video_h264.fps_d;
return true;
case WG_MAJOR_TYPE_VIDEO_WMV:
*width = format->u.video_wmv.width;
*height = format->u.video_wmv.height;
*fps_n = format->u.video_wmv.fps_n;
*fps_d = format->u.video_wmv.fps_d;
return true;
case WG_MAJOR_TYPE_VIDEO_INDEO:
*width = format->u.video_indeo.width;
*height = format->u.video_indeo.height;
*fps_n = format->u.video_indeo.fps_n;
*fps_d = format->u.video_indeo.fps_d;
return true;
case WG_MAJOR_TYPE_VIDEO_MPEG1:
*width = format->u.video_mpeg1.width;
*height = format->u.video_mpeg1.height;
*fps_n = format->u.video_mpeg1.fps_n;
*fps_d = format->u.video_mpeg1.fps_d;
return true;
default:
GST_ERROR("Type %d is not a video format.\n", format->major_type);
return false;
}
}
```
Apparently, the code above is ugly. By refactoring wg_format, we can avoid code like this.
This patch is a draft now, it only contains unixlib.h code.
Zeb, I'd like to confirm that if this refactoring would be acceptable for you. If do, I'll continue finishing the remaining parts.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5369
When a process is made a system process, `release_thread_desktop( thread, 0 )` is called and we remove the process threads from their desktop thread list, as well as decrementing the desktop user count. Later, when the process gets killed on shutdown, `release_thread_desktop( thread, 1 )` is called, and we remove the thread list node again.
This is 1) wrong, we only want to decrement the desktop user count in this case, and 2) causes an invalid write and corrupts the list the second time we remove the entry.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5375
First part of Proton shared memory series. The full branch can be seen at https://gitlab.winehq.org/rbernon/wine/-/commits/mr/shared-memories.
--
v27: win32u: Use the desktop shared data for GetCursorPos.
server: Move the last cursor time to the desktop session object.
server: Move the cursor position to the desktop session object.
win32u: Open desktop shared objects from session mapping.
server: Return the desktop object info in get_thread_desktop.
server: Allocate shared session object for desktops.
win32u: Open the global session shared mapping.
include: Add ReadNoFence64 inline helpers.
server: Create a global session shared mapping.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3103
I've tried implementing this before but importing user32 from ntdll isn't a reliable
thing (so I recently rewrote it using the ntdll equivalents of LoadLibrary() and GetProcAddress())
Note: This is a weird way to implement this function (Windows implements this
in ntdll instead) but that would probably require a user32/ntdll rewrite (so this
is the next best tning to get the application working)
--
v3: ntdll: Implement NtdllDefWindowProc_A().
https://gitlab.winehq.org/wine/wine/-/merge_requests/5236
This series:
- add a couple of commands to winedbg to ease scripting
(mainly reload a minidump from parser, run a debuggee with
arguments...).
- a couple of quick fixes (updating CPU info displayed on reload)
and detecting reloading a minidump for a different machine.
WOW64 support in minidump (dbghelp & winedbg) will require quite
some work.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5374
Presently the wine file explorer has a create shortcut entry that does nothing. This implements the FCIDM_SHVIEW_CREATELINK command.
This is a patch that was first submitted in 2017 and I unfortunately let the revision request fall unimplemented.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5373
I missed that Zhiyi was out so I've just reordered this, calling __wine_get_vulkan_driver from winex11 d3dkmt instead.
--
v2: win32u: Move vkGet(Device|Instance)ProcAddr helpers inline.
winevulkan: Stop generating the wine/vulkan_driver.h header.
win32u: Move vkGet(Instance|Device)ProcAddr out the drivers.
win32u: Move vulkan init guard out of the drivers.
win32u: Introduce new win32u vulkan function table.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5365
These two commits shouldn't change anything functional wise, but with minimal changes on wine side, they allow easy integration of d3d9/tests/visual.c into GoogleTest native runner. visual.c code is C++ compatible, except the `enums`.
Second change is done, because we had to redefine `ok()` macro, so without proper braces around conditions it cannot be expanded to multiple lines.
Here is [MR how we import](https://github.com/axeldavy/Xnine/pull/12) the `visual.c`
Third commit just correct my name in the `.mailmap`
My main goal here is bring code which run in Mesa3D CI workflow as closer to the original wine d3d9 tests, so we can easily update from wine and eventually provide also fixes and improvements back.
If you find this MR suitable, we could try figure out a way, to incorporate data about [nine_todo](https://github.com/axeldavy/Xnine/commit/7ac97c8350ea5b2bfd7307c…, of course only if you find some use of these extra information.
/cc @zfigura
--
v7: mailmap: Add a mailmap entry for myself with the proper name
d3d9/tests: replace LPDWORD cast with float_to_int function
https://gitlab.winehq.org/wine/wine/-/merge_requests/5324
Fixes a regression from 9d537999e315a7, which removed closing the file.
This causes Windows widl build to be to remove the temporary file on exit.
--
v2: widl: Always close parsed input file.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5364
--
v2: ntdll/tests: Add more tests for xstate.
ntdll, wineboot: Support more xstate features.
ntdll: Mind generic xstate masks in server context conversion.
ntdll: Factor out context_to_server() function.
ntdll: Factor out xstate_from_server() function.
ntdll: Support generic xstate in Unix-side manipulation functions.
ntdll: Preserve untouched parts of xstate in NtSetContextThread().
ntdll: Only save AVX xstate in wine_syscall_dispatcher.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5346
--
v6: mfplat/mediatype: Use MFCreateWaveFormatExFromMFMediaType in init_am_media_type_audio_format.
mfplat/mediatype: Implement MFCreateMediaTypeFromRepresentation.
mfplat/mediatype: Force WAVEFORMATEXTENSIBLE in MFCreateWaveFormatExFromMFMediaType in some cases.
mfplat/mediatype: Support audio major type in MFInitMediaTypeFromAMMediaType.
mfplat/mediatype: Check format pointers and sizes in MFInitMediaTypeFromAMMediaType.
mfplat/tests: Check how AAC attributes are copied from user data.
mfplat/tests: Test initializing mediatype from AAC WAVEFORMATEXTENSIBLE.
mfplat/tests: Add some broken results for Win7.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5362
--
v5: mfplat/mediatype: Use MFCreateWaveFormatExFromMFMediaType in init_am_media_type_audio_format.
mfplat/mediatype: Implement MFCreateMediaTypeFromRepresentation.
mfplat/mediatype: Force WAVEFORMATEXTENSIBLE in MFCreateWaveFormatExFromMFMediaType in some cases.
mfplat/mediatype: Support audio major type in MFInitMediaTypeFromAMMediaType.
mfplat/mediatype: Check format pointers and sizes in MFInitMediaTypeFromAMMediaType.
mfplat/tests: Check how AAC attributes are copied from user data.
mfplat/tests: Test initializing mediatype from AAC WAVEFORMATEXTENSIBLE.
mfplat/tests: Add some broken results for Win7.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5362
I've tried implementing this before but importing user32 from ntdll isn't a reliable
thing (so I recently rewrote it using the ntdll equivalents of LoadLibrary() and GetProcAddress())
Note: This is a weird way to implement this function (Windows implements this
in ntdll instead) but that would probably require a user32/ntdll rewrite (so this
is the next best tning to get the application working)
--
v2: ntdll: Implement NtdllDefWindowProc_A().
https://gitlab.winehq.org/wine/wine/-/merge_requests/5236
I *think* this will fix the test timeouts that happen on Gitlab since https://gitlab.winehq.org/wine/wine/-/merge_requests/5262.
I'm not completely sure that it will, because the failure is very elusive and somehow only happening on Gitlab CI, but there's a logic behind it: we were previously enumerating monitors from the adapters we found, so every monitor enumerated had a matching adapter. We are now enumerating monitors directly, and matching their adapter next.
How we then end up with a monitor without a matching adapter is still unclear, but I think it's better to fix it like this for now, as it is plaguing MRs with failures and long timeouts.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5368
On Wed Mar 13 14:02:46 2024 +0000, Akihiro Sagawa wrote:
> Reading ImmSetActiveContext() in dlls/imm32/imm.c, it initializes COM
> with the COINIT_APARTMENTTHREADED parameter, not COINIT_MULTITHREADED.
> My test shows that IDirectSound::Initialize() creates a multithread apartment.
> Could you share your thoughts on this point?
If observed state is different then it's probably not coming from imm32/user32, yes.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5250#note_65538
--
v3: mfplat/mediatype: Use MFCreateWaveFormatExFromMFMediaType in init_am_media_type_audio_format.
mfplat/mediatype: Implement MFCreateMediaTypeFromRepresentation.
mfplat/mediatype: Force WAVEFORMATEXTENSIBLE in MFCreateWaveFormatExFromMFMediaType in some cases.
mfplat/mediatype: Support audio major type in MFInitMediaTypeFromAMMediaType.
mfplat/mediatype: Check format pointers and sizes in MFInitMediaTypeFromAMMediaType.
mfplat/tests: Check how AAC attributes are copied from user data.
mfplat/tests: Test initializing mediatype from AAC WAVEFORMATEXTENSIBLE.
mfplat/tests: Add some broken results for Win7.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5362
Not when making the loop header available, which is too early and might lead to open too many loops at once.
This fixes an assertion failure with some shaders seen in the wild.
--
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/737
--
v4: server: Process internal messages when checking queue status.
server: Check for internal hardware messages before others.
win32u: Use a structure to pass peek_message arguments.
server: Send WM_WINE_SETCURSOR message only when necessary.
server: Send WM_WINE_CLIPCURSOR message only when necessary.
winex11: Accept key and mouse events with QS_RAWINPUT.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5322
SM1 support for LOGIC_NOT, LOGIC_OR, and LOGIC_AND.
--
v4: vkd3d-shader/spirv: Throw compiler error on unrecognized register.
vkd3d-shader/spirv: Implement VKD3DSIH_ABS.
vkd3d-shader/d3dbc: Implement HLSL_OP2_LOGIC_AND for SM1.
vkd3d-shader/d3dbc: Implement HLSL_OP2_LOGIC_OR for SM1.
vkd3d-shader/hlsl: Cast to bool before applying LOGIC_NOT.
vkd3d-shader/hlsl: Support LOGIC_NOT for SM1.
tests: Add tests for LOGIC_NOT on uniforms.
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/724
## Goal
Make non-input hidraw devices work again.
## Description
The current device backend selection policy is input-device oriented and it does not handle non-input hidraw devices correctly. Pre-9.1 versions handled all hidraw devices with hidraw backend, but since 9.1, there have been changes/additions to the backend selection policy which have caused non-input hidraw devices to stop working.
## Changes in nutshell
- add `device_desc.has_hid_input_relative` which tells if the device has hid subsystem ancestor AND the hid ancestor has an input subsystem descendant; this is useful for detecting if a hidraw device is a non-input device or not (non-input hidraw devices do not have hid input relatives)
- prefer hidraw backend for all such non-input hidraw devices
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/5331
--
v2: mfplat/mediatype: Use MFCreateWaveFormatExFromMFMediaType in init_am_media_type_audio_format.
mfplat/mediatype: Implement MFCreateMediaTypeFromRepresentation.
mfplat/mediatype: Force WAVEFORMATEXTENSIBLE in MFCreateWaveFormatExFromMFMediaType in some cases.
mfplat/mediatype: Support audio major type in MFInitMediaTypeFromAMMediaType.
mfplat/mediatype: Check format pointers and sizes in MFInitMediaTypeFromAMMediaType.
mfplat/tests: Check how AAC attributes are copied from user data.
mfplat/tests: Test initializing mediatype from AAC WAVEFORMATEXTENSIBLE.
mfplat/tests: Add some broken results for Win7.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5362
test_reuseaddr and test_exclusiveaddruse bind to the wildcard address
(0.0.0.0 or [::]). This may trigger a firewall alert on Windows 7, and
the alert UI window may interfere with user32:msg tests.
Fix this by trying to disable the firewall, and skipping the wildcard
address tests if it fails.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53891
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=54202
--
v2: ws2_32/tests: Try to disable firewall before testing with any addr.
ws2_32/tests: Factor out test_exclusiveaddruse from test_reuseaddr.
ws2_32/tests: Do ANY address tests in a separate loop in test_reuseaddr.
webservices/tests: Move firewall code to a common header.
https://gitlab.winehq.org/wine/wine/-/merge_requests/2000
Some symbols (e.g., RtlPcToFileHeader) are exported by both kernel32 and
ntdll. In this case, prefer ntdll's export over kernel32's one.
--
v2: ntdll/tests: Import RtlPcToFileHeader statically.
ntdll/tests: Import from ntdll before other DLLs.
https://gitlab.winehq.org/wine/wine/-/merge_requests/5358
--
v10: vkd3d-shader/spirv: Handle the sequentially consistent ordering flag for atomic instructions.
vkd3d-shader/spirv: Emit a warning if the atomic instruction volatile flag is unhandled.
vkd3d-shader/dxil: Implement the DXIL ATOMICRMW instruction.
vkd3d-shader/dxil: Implement DX instructions ThreadId, GroupId, ThreadIdInGroup and FlattenedThreadIdInGroup.
tests/shader-runner: Add TGSM tests.
vkd3d-shader/dxil: Emit an error if a constant code is unhandled.
vkd3d-shader/spirv: Support 64-bit register info component type in spirv_compiler_emit_load_reg().
vkd3d-shader/spirv: Do not assert if a TGSM store data register is not UINT.
vkd3d-shader/spirv: Do not assert if a TGSM load dst register is not UINT.
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/707
--
v9: vkd3d-shader/spirv: Handle the sequentially consistent ordering flag for atomic instructions.
vkd3d-shader/spirv: Emit a warning if the atomic instruction volatile flag is unhandled.
vkd3d-shader/dxil: Implement the DXIL ATOMICRMW instruction.
vkd3d-shader/dxil: Implement DX instructions ThreadId, GroupId, ThreadIdInGroup and FlattenedThreadIdInGroup.
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/707