[PATCH v2 0/6] MR228: d3dx: improvements to texture creation functions

Matteo Bruni (@Mystral) wine at gitlab.winehq.org
Tue Jun 14 17:50:09 CDT 2022


Matteo Bruni (@Mystral) commented about dlls/d3dx10_43/tests/d3dx10.c:
> +    ok(hr2 == 0xdeadbeef, "Got unexpected hr2 %#x.\n", hr2);
> +    hr2 = 0xdeadbeef;
> +    hr = D3DX10CreateTextureFromResourceA(device, NULL, NULL, NULL, NULL, &resource, &hr2);
>      ok(hr == D3DX10_ERR_INVALID_DATA, "Got unexpected hr %#x.\n", hr);
> -    hr = D3DX10CreateTextureFromResourceA(device, NULL, "deadbeef", NULL, NULL, &resource, NULL);
> +    ok(hr2 == 0xdeadbeef, "Got unexpected hr2 %#x.\n", hr2);
> +    hr2 = 0xdeadbeef;
> +    hr = D3DX10CreateTextureFromResourceA(device, NULL, "deadbeef", NULL, NULL, &resource, &hr2);
>      ok(hr == D3DX10_ERR_INVALID_DATA, "Got unexpected hr %#x.\n", hr);
> +    ok(hr2 == 0xdeadbeef, "Got unexpected hr2 %#x.\n", hr2);
>  
>      for (i = 0; i < ARRAY_SIZE(test_image); ++i)
>      {
>          winetest_push_context("Test %u", i);
>          resource_module = create_resource_module(test_resource_name, test_image[i].data, test_image[i].size);
>  
This could use an additional test similar to the one from 35939bbe0c04534da07ece7f6a47a560d356f7a1:

```
        hr2 = 0xdeadbeef;
        hr = D3DX10CreateTextureFromResourceW(device, resource_module, L"deadbeef", NULL, NULL, &resource, &hr2);
        ok(hr == D3DX10_ERR_INVALID_DATA, "Got unexpected hr %#x.\n", hr);
        ok(hr2 == 0xdeadbeef, "Got unexpected hr2 %#x.\n", hr2);
```

-- 
https://gitlab.winehq.org/wine/wine/-/merge_requests/228#note_2063



More information about the wine-devel mailing list