From: Elizabeth Figura zfigura@codeweavers.com
--- dlls/d3dcompiler_43/tests/hlsl_d3d9.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/d3dcompiler_43/tests/hlsl_d3d9.c b/dlls/d3dcompiler_43/tests/hlsl_d3d9.c index e736f932b39..1799a958ee8 100644 --- a/dlls/d3dcompiler_43/tests/hlsl_d3d9.c +++ b/dlls/d3dcompiler_43/tests/hlsl_d3d9.c @@ -288,16 +288,16 @@ static void init_readback(IDirect3DDevice9 *device, struct readback *rb) D3DSURFACE_DESC desc; HRESULT hr;
- hr = IDirect3DDevice9Ex_GetRenderTarget(device, 0, &rt); + hr = IDirect3DDevice9_GetRenderTarget(device, 0, &rt); ok(hr == D3D_OK, "Got unexpected hr %#lx.\n", hr);
hr = IDirect3DSurface9_GetDesc(rt, &desc); ok(hr == D3D_OK, "Got unexpected hr %#lx.\n", hr); - hr = IDirect3DDevice9Ex_CreateOffscreenPlainSurface(device, desc.Width, desc.Height, + hr = IDirect3DDevice9_CreateOffscreenPlainSurface(device, desc.Width, desc.Height, desc.Format, D3DPOOL_SYSTEMMEM, &rb->surface, NULL); ok(hr == D3D_OK, "Got unexpected hr %#lx.\n", hr);
- hr = IDirect3DDevice9Ex_GetRenderTargetData(device, rt, rb->surface); + hr = IDirect3DDevice9_GetRenderTargetData(device, rt, rb->surface); ok(hr == D3D_OK, "Got unexpected hr %#lx.\n", hr);
hr = IDirect3DSurface9_LockRect(rb->surface, &rb->rect, NULL, D3DLOCK_READONLY);
From: Elizabeth Figura zfigura@codeweavers.com
--- dlls/mfplat/tests/mfplat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/mfplat/tests/mfplat.c b/dlls/mfplat/tests/mfplat.c index 40853f6fc00..7aba4666f45 100644 --- a/dlls/mfplat/tests/mfplat.c +++ b/dlls/mfplat/tests/mfplat.c @@ -177,7 +177,7 @@ static void get_d3d9_surface_readback(IDirect3DSurface9 *surface, struct d3d9_su rb->surf_desc.Format, D3DPOOL_SYSTEMMEM, &rb->readback_surface, NULL); ok(hr == D3D_OK, "Failed to create surface, hr %#lx.\n", hr);
- hr = IDirect3DDevice9Ex_GetRenderTargetData(device, surface, rb->readback_surface); + hr = IDirect3DDevice9_GetRenderTargetData(device, surface, rb->readback_surface); ok(hr == D3D_OK, "Failed to get render target data, hr %#lx.\n", hr);
hr = IDirect3DSurface9_LockRect(rb->readback_surface, &rb->map_desc, NULL, 0);
From: Elizabeth Figura zfigura@codeweavers.com
--- dlls/d3dx9_36/effect.c | 2 +- dlls/d3dx9_36/render.c | 8 +++++--- dlls/d3dx9_36/texture.c | 8 ++++---- 3 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/dlls/d3dx9_36/effect.c b/dlls/d3dx9_36/effect.c index ea965ce789b..d84ad749f30 100644 --- a/dlls/d3dx9_36/effect.c +++ b/dlls/d3dx9_36/effect.c @@ -4164,7 +4164,7 @@ static BOOL param_on_lost_device(void *data, struct d3dx_parameter *param) cube_texture = *(IDirect3DCubeTexture9 **)param->data; if (!cube_texture) return FALSE; - IDirect3DTexture9_GetLevelDesc(cube_texture, 0, &surface_desc); + IDirect3DCubeTexture9_GetLevelDesc(cube_texture, 0, &surface_desc); if (surface_desc.Pool != D3DPOOL_DEFAULT) return FALSE; break; diff --git a/dlls/d3dx9_36/render.c b/dlls/d3dx9_36/render.c index 6bef9430f80..31a2a2e3aff 100644 --- a/dlls/d3dx9_36/render.c +++ b/dlls/d3dx9_36/render.c @@ -503,7 +503,8 @@ static ULONG WINAPI D3DXRenderToEnvMap_Release(ID3DXRenderToEnvMap *iface)
if (!ref) { - if (render->dst_cube_texture) IDirect3DSurface9_Release(render->dst_cube_texture); + if (render->dst_cube_texture) + IDirect3DCubeTexture9_Release(render->dst_cube_texture);
if (render->render_target) IDirect3DSurface9_Release(render->render_target); if (render->depth_stencil) IDirect3DSurface9_Release(render->depth_stencil); @@ -585,7 +586,8 @@ static HRESULT WINAPI D3DXRenderToEnvMap_BeginCube(ID3DXRenderToEnvMap *iface, return D3D_OK;
cleanup: - if (render->dst_cube_texture) IDirect3DSurface9_Release(render->dst_cube_texture); + if (render->dst_cube_texture) + IDirect3DCubeTexture9_Release(render->dst_cube_texture); render->dst_cube_texture = NULL;
if (render->render_target) IDirect3DSurface9_Release(render->render_target); @@ -705,7 +707,7 @@ static HRESULT WINAPI D3DXRenderToEnvMap_End(ID3DXRenderToEnvMap *iface, render->depth_stencil = NULL; }
- IDirect3DSurface9_Release(render->dst_cube_texture); + IDirect3DCubeTexture9_Release(render->dst_cube_texture); render->dst_cube_texture = NULL;
render->state = INITIAL; diff --git a/dlls/d3dx9_36/texture.c b/dlls/d3dx9_36/texture.c index 5a68b2dd1c4..8314146a264 100644 --- a/dlls/d3dx9_36/texture.c +++ b/dlls/d3dx9_36/texture.c @@ -84,7 +84,7 @@ HRESULT WINAPI D3DXFilterTexture(IDirect3DBaseTexture9 *texture, else { numfaces = 6; - IDirect3DCubeTexture9_GetLevelDesc((IDirect3DTexture9*) texture, srclevel, &desc); + IDirect3DCubeTexture9_GetLevelDesc((IDirect3DCubeTexture9 *)texture, srclevel, &desc); }
if (filter == D3DX_DEFAULT) @@ -1303,7 +1303,7 @@ HRESULT WINAPI D3DXFillTexture(struct IDirect3DTexture9 *texture, LPD3DXFILL2D f if (!texture || !function) return D3DERR_INVALIDCALL;
- miplevels = IDirect3DBaseTexture9_GetLevelCount(texture); + miplevels = IDirect3DTexture9_GetLevelCount(texture);
for (m = 0; m < miplevels; m++) { @@ -1652,7 +1652,7 @@ HRESULT WINAPI D3DXFillCubeTexture(struct IDirect3DCubeTexture9 *texture, LPD3DX if (texture == NULL || function == NULL) return D3DERR_INVALIDCALL;
- miplevels = IDirect3DBaseTexture9_GetLevelCount(texture); + miplevels = IDirect3DCubeTexture9_GetLevelCount(texture);
for (m = 0; m < miplevels; m++) { @@ -1713,7 +1713,7 @@ HRESULT WINAPI D3DXFillVolumeTexture(struct IDirect3DVolumeTexture9 *texture, LP if (texture == NULL || function == NULL) return D3DERR_INVALIDCALL;
- miplevels = IDirect3DBaseTexture9_GetLevelCount(texture); + miplevels = IDirect3DVolumeTexture9_GetLevelCount(texture);
for (m = 0; m < miplevels; m++) {
From: Elizabeth Figura zfigura@codeweavers.com
--- dlls/d3dx9_36/tests/line.c | 1 + dlls/d3dx9_36/tests/math.c | 1 + dlls/d3dx9_36/tests/shader.c | 1 + 3 files changed, 3 insertions(+)
diff --git a/dlls/d3dx9_36/tests/line.c b/dlls/d3dx9_36/tests/line.c index 8056e021c95..cdcb91715fe 100644 --- a/dlls/d3dx9_36/tests/line.c +++ b/dlls/d3dx9_36/tests/line.c @@ -16,6 +16,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */
+#define COBJMACROS #include "wine/test.h" #include "d3dx9.h"
diff --git a/dlls/d3dx9_36/tests/math.c b/dlls/d3dx9_36/tests/math.c index 3345c412481..638d2bddc45 100644 --- a/dlls/d3dx9_36/tests/math.c +++ b/dlls/d3dx9_36/tests/math.c @@ -19,6 +19,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */
+#define COBJMACROS #include "wine/test.h" #include "d3dx9.h" #include <math.h> diff --git a/dlls/d3dx9_36/tests/shader.c b/dlls/d3dx9_36/tests/shader.c index 2b40abef53c..f0c03052404 100644 --- a/dlls/d3dx9_36/tests/shader.c +++ b/dlls/d3dx9_36/tests/shader.c @@ -17,6 +17,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */
+#define COBJMACROS #include "wine/test.h" #include "d3dx9.h"
Hi,
It looks like your patch introduced the new failures shown below. Please investigate and fix them before resubmitting your patch. If they are not new, fixing them anyway would help a lot. Otherwise please ask for the known failures list to be updated.
The tests also ran into some preexisting test failures. If you know how to fix them that would be helpful. See the TestBot job for the details:
The full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=146500
Your paranoid android.
=== w8adm (32 bit report) ===
mfplat: mfplat.c:1077: Test failed: Unexpected refcount 3
=== w864 (64 bit report) ===
mfplat: mfplat.c:1077: Test failed: Unexpected refcount 3
=== w1064_2qxl (64 bit report) ===
mfplat: mfplat.c:1077: Test failed: Unexpected refcount 3
=== w1064_adm (64 bit report) ===
mfplat: mfplat.c:1077: Test failed: Unexpected refcount 3
This merge request was approved by Matteo Bruni.
Is the last patch just for consistency or is there anything more to it?
This merge request was approved by Nikolay Sivov.
I incorrectly assumed that COBJMACROS was necessary for all such wrappers; it seems that's not the case.
This patch series was motivated by a patch I wrote to convert d3d9.h and some other headers into IDLs. This does seem like quite a lot of an improvement in several respects, but it also breaks subtle aspects of header compatibility like this. I don't know how much we care about those though.