Zhiyi Zhang (@zhiyi) commented about dlls/win32u/sysparams.c:
> + struct adapter *adapter;
> + ULONG idx = 0, count;
> +
> + TRACE( "(%p)\n", desc );
> +
> + if (!desc) return STATUS_INVALID_PARAMETER;
> +
> + if (!desc->pAdapters)
> + {
> + desc->NumAdapters = max_adapters;
> + return STATUS_SUCCESS;
> + }
> +
> + if (!lock_display_devices()) return STATUS_UNSUCCESSFUL;
> +
> + if ((count = list_count( &adapters )) > max_adapters)
This is wrong. adapters in sysparams.c are GDI adapters, they are not the same adapter in D3DKMT terms. Adapters in D3DKMT terms mean GPUs. So you need to add a list of GPUs to the cache and then do enumeration from that. You should do the initialization from the SetupAPI registry data. For example, basically with the following code. However, since you're in win32u. You can't use SetupAPI directly and you need to convert these to NT registry calls instead. See prepare_devices() for some example code for how to do it.
```
devinfo = SetupDiCreateDeviceInfoList( &GUID_DEVCLASS_DISPLAY, DIGCF_PRESENT );
for (i = 0; SetupDiEnumDeviceInfo( set, i, &device ); ++i)
{
if (SetupDiGetDevicePropertyW( device, &device_data, &DEVPROPKEY_GPU_LUID, &type,
(BYTE *)&luid_desc.AdapterLuid, sizeof( luid_desc.AdapterLuid ),
NULL, 0))
add_to_gpu_list;
}
```
Then `NumOfSources` is the number of GDI adapters with the same GPU LUID. As for bPrecisePresentRegionsPreferred, I guess you can just return TRUE.
The GPU list construction can be done in update_display_cache_from_registry().
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4857#note_58130
--
v3: win32u: Don't move an owned window on top of its owner if it's not activated ever.
user32/tests: Test the z-order for an owned window that's not activated ever.
win32u: Skip windows that are not activated even once in activate_other_window().
user32/tests: Add window activation tests.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4066
This allows for the basic features necessary to compile sm1 shaders. This is the
first step towards comprehensive Direct3D 1-9 support in the Vulkan backend.
Fixed-function d3d states that must be emulated with shaders in Vulkan (e.g.
alpha test) are not yet implemented, nor is the fixed-function pipeline.
Accordingly it is unlikely that any real applications run yet.
Tested with vkd3d's tests. Specifically, run `make crosstest` in a vkd3d tree,
then:
wine tests/shader_runner.cross64.exe ../vkd3d/tests/hlsl/writemask-assignop-0.shader_test
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4875