Rebase against ca29ac4650f7f9a96cfaa75a7919ef007306cbbb

This commit is contained in:
Alistair Leslie-Hughes
2019-01-29 10:30:19 +11:00
parent 60f0f50382
commit 1c5f409745
5 changed files with 93 additions and 90 deletions

View File

@@ -1,4 +1,4 @@
From 076d1ae00db0f95713e64bea1d2649cbdcdf5939 Mon Sep 17 00:00:00 2001
From 1c46cc796a20b263f708aebf5428e59408fea200 Mon Sep 17 00:00:00 2001
From: Christian Costa <titan.costa@gmail.com>
Date: Fri, 30 Mar 2018 08:22:02 +0000
Subject: [PATCH] d3dx9_36: add DXTn support
@@ -29,7 +29,7 @@ Subject: [PATCH] d3dx9_36: add DXTn support
22 files changed, 118 insertions(+), 32 deletions(-)
diff --git a/dlls/d3dx9_24/Makefile.in b/dlls/d3dx9_24/Makefile.in
index 482c92d..d969a55 100644
index 02e64d3..0484639 100644
--- a/dlls/d3dx9_24/Makefile.in
+++ b/dlls/d3dx9_24/Makefile.in
@@ -1,6 +1,6 @@
@@ -38,10 +38,10 @@ index 482c92d..d969a55 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_25/Makefile.in b/dlls/d3dx9_25/Makefile.in
index be4c769..b232290 100644
index 57ed1da..3461967 100644
--- a/dlls/d3dx9_25/Makefile.in
+++ b/dlls/d3dx9_25/Makefile.in
@@ -1,6 +1,6 @@
@@ -50,10 +50,10 @@ index be4c769..b232290 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_26/Makefile.in b/dlls/d3dx9_26/Makefile.in
index c5e9e85..525009d 100644
index 04d9ba4..291daf3 100644
--- a/dlls/d3dx9_26/Makefile.in
+++ b/dlls/d3dx9_26/Makefile.in
@@ -1,6 +1,6 @@
@@ -62,10 +62,10 @@ index c5e9e85..525009d 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_27/Makefile.in b/dlls/d3dx9_27/Makefile.in
index ee7f0e2..da98482 100644
index faec9b2..5a52b60 100644
--- a/dlls/d3dx9_27/Makefile.in
+++ b/dlls/d3dx9_27/Makefile.in
@@ -1,6 +1,6 @@
@@ -74,10 +74,10 @@ index ee7f0e2..da98482 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_28/Makefile.in b/dlls/d3dx9_28/Makefile.in
index 0944200..d50e035 100644
index b8aad93..8eecbc0 100644
--- a/dlls/d3dx9_28/Makefile.in
+++ b/dlls/d3dx9_28/Makefile.in
@@ -1,6 +1,6 @@
@@ -86,10 +86,10 @@ index 0944200..d50e035 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_29/Makefile.in b/dlls/d3dx9_29/Makefile.in
index 88cb110..cfc1a15 100644
index 29c76c4..0299369 100644
--- a/dlls/d3dx9_29/Makefile.in
+++ b/dlls/d3dx9_29/Makefile.in
@@ -1,6 +1,6 @@
@@ -98,10 +98,10 @@ index 88cb110..cfc1a15 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_30/Makefile.in b/dlls/d3dx9_30/Makefile.in
index 6ab2ff2..726c92e 100644
index 810edc9..7bdc074 100644
--- a/dlls/d3dx9_30/Makefile.in
+++ b/dlls/d3dx9_30/Makefile.in
@@ -1,6 +1,6 @@
@@ -110,10 +110,10 @@ index 6ab2ff2..726c92e 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_31/Makefile.in b/dlls/d3dx9_31/Makefile.in
index 3d44da1..2014301 100644
index fce2b53..0ef9c91 100644
--- a/dlls/d3dx9_31/Makefile.in
+++ b/dlls/d3dx9_31/Makefile.in
@@ -1,6 +1,6 @@
@@ -122,10 +122,10 @@ index 3d44da1..2014301 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_32/Makefile.in b/dlls/d3dx9_32/Makefile.in
index 37cc279..442258d 100644
index ad53b26..25e2a1c 100644
--- a/dlls/d3dx9_32/Makefile.in
+++ b/dlls/d3dx9_32/Makefile.in
@@ -1,6 +1,6 @@
@@ -134,10 +134,10 @@ index 37cc279..442258d 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_33/Makefile.in b/dlls/d3dx9_33/Makefile.in
index 5b03ec1..cc98ed2 100644
index 318ddce..a6ec6db 100644
--- a/dlls/d3dx9_33/Makefile.in
+++ b/dlls/d3dx9_33/Makefile.in
@@ -1,6 +1,6 @@
@@ -146,10 +146,10 @@ index 5b03ec1..cc98ed2 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_34/Makefile.in b/dlls/d3dx9_34/Makefile.in
index b7f9c46..4862fe9 100644
index 451a371..ff79b58 100644
--- a/dlls/d3dx9_34/Makefile.in
+++ b/dlls/d3dx9_34/Makefile.in
@@ -1,6 +1,6 @@
@@ -158,10 +158,10 @@ index b7f9c46..4862fe9 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_35/Makefile.in b/dlls/d3dx9_35/Makefile.in
index 9c196ea..3f529c9 100644
index 978d0b0..aa8ea65 100644
--- a/dlls/d3dx9_35/Makefile.in
+++ b/dlls/d3dx9_35/Makefile.in
@@ -1,6 +1,6 @@
@@ -170,10 +170,10 @@ index 9c196ea..3f529c9 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_36/Makefile.in b/dlls/d3dx9_36/Makefile.in
index da8098d..166031e 100644
index 847edec..1427571 100644
--- a/dlls/d3dx9_36/Makefile.in
+++ b/dlls/d3dx9_36/Makefile.in
@@ -1,7 +1,7 @@
@@ -182,11 +182,11 @@ index da8098d..166031e 100644
IMPORTLIB = d3dx9
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
DELAYIMPORTS = windowscodecs
C_SRCS = \
animation.c \
diff --git a/dlls/d3dx9_36/surface.c b/dlls/d3dx9_36/surface.c
index cae80a8..0900d04 100644
index d236feb..3c308d3 100644
--- a/dlls/d3dx9_36/surface.c
+++ b/dlls/d3dx9_36/surface.c
@@ -27,6 +27,8 @@
@@ -197,8 +197,8 @@ index cae80a8..0900d04 100644
+
WINE_DEFAULT_DEBUG_CHANNEL(d3dx);
@@ -1784,6 +1786,24 @@ void point_filter_argb_pixels(const BYTE *src, UINT src_row_pitch, UINT src_slic
HRESULT WINAPI WICCreateImagingFactory_Proxy(UINT, IWICImagingFactory**);
@@ -1876,6 +1878,24 @@ void point_filter_argb_pixels(const BYTE *src, UINT src_row_pitch, UINT src_slic
}
}
@@ -223,7 +223,7 @@ index cae80a8..0900d04 100644
/************************************************************
* D3DXLoadSurfaceFromMemory
*
@@ -1823,10 +1843,12 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
@@ -1915,10 +1935,12 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
{
const struct pixel_format_desc *srcformatdesc, *destformatdesc;
IDirect3DSurface9 *surface;
@@ -237,7 +237,7 @@ index cae80a8..0900d04 100644
TRACE("(%p, %p, %s, %p, %#x, %u, %p, %s, %#x, 0x%08x)\n",
dst_surface, dst_palette, wine_dbgstr_rect(dst_rect), src_memory, src_format,
@@ -1907,18 +1929,65 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
@@ -1999,18 +2021,65 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
}
else /* Stretching or format conversion. */
{
@@ -307,7 +307,7 @@ index cae80a8..0900d04 100644
}
else /* if ((filter & 0xf) == D3DX_FILTER_POINT) */
{
@@ -1927,12 +1996,29 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
@@ -2019,12 +2088,29 @@ HRESULT WINAPI D3DXLoadSurfaceFromMemory(IDirect3DSurface9 *dst_surface,
/* Always apply a point filter until D3DX_FILTER_LINEAR,
* D3DX_FILTER_TRIANGLE and D3DX_FILTER_BOX are implemented. */
@@ -341,10 +341,10 @@ index cae80a8..0900d04 100644
/************************************************************
diff --git a/dlls/d3dx9_36/tests/surface.c b/dlls/d3dx9_36/tests/surface.c
index 6cb1ddb..885191e 100644
index 2c83dc2..95b64a0 100644
--- a/dlls/d3dx9_36/tests/surface.c
+++ b/dlls/d3dx9_36/tests/surface.c
@@ -1195,7 +1195,7 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device)
@@ -1224,7 +1224,7 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device)
hr = IDirect3DTexture9_GetSurfaceLevel(tex, 0, &newsurf);
ok(SUCCEEDED(hr), "Failed to get the surface, hr %#x.\n", hr);
hr = D3DXLoadSurfaceFromSurface(newsurf, NULL, NULL, surf, NULL, NULL, D3DX_FILTER_NONE, 0);
@@ -353,7 +353,7 @@ index 6cb1ddb..885191e 100644
check_release((IUnknown*)newsurf, 1);
check_release((IUnknown*)tex, 0);
}
@@ -1221,7 +1221,7 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device)
@@ -1250,7 +1250,7 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device)
hr = IDirect3DTexture9_GetSurfaceLevel(tex, 0, &newsurf);
ok(SUCCEEDED(hr), "Failed to get the surface, hr %#x.\n", hr);
hr = D3DXLoadSurfaceFromSurface(newsurf, NULL, NULL, surf, NULL, NULL, D3DX_FILTER_NONE, 0);
@@ -362,7 +362,7 @@ index 6cb1ddb..885191e 100644
check_release((IUnknown*)newsurf, 1);
check_release((IUnknown*)tex, 0);
}
@@ -1234,10 +1234,10 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device)
@@ -1263,10 +1263,10 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device)
hr = IDirect3DTexture9_GetSurfaceLevel(tex, 0, &newsurf);
ok(SUCCEEDED(hr), "Failed to get the surface, hr %#x.\n", hr);
hr = D3DXLoadSurfaceFromSurface(newsurf, NULL, NULL, surf, NULL, NULL, D3DX_FILTER_NONE, 0);
@@ -376,7 +376,7 @@ index 6cb1ddb..885191e 100644
check_release((IUnknown*)newsurf, 1);
check_release((IUnknown*)tex, 0);
diff --git a/dlls/d3dx9_37/Makefile.in b/dlls/d3dx9_37/Makefile.in
index ab790a4..51382c7 100644
index a05068c..e5b29d3 100644
--- a/dlls/d3dx9_37/Makefile.in
+++ b/dlls/d3dx9_37/Makefile.in
@@ -1,6 +1,6 @@
@@ -385,10 +385,10 @@ index ab790a4..51382c7 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_38/Makefile.in b/dlls/d3dx9_38/Makefile.in
index 6125c2d..f6257cb 100644
index b092e62..0a37204 100644
--- a/dlls/d3dx9_38/Makefile.in
+++ b/dlls/d3dx9_38/Makefile.in
@@ -1,6 +1,6 @@
@@ -397,10 +397,10 @@ index 6125c2d..f6257cb 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_39/Makefile.in b/dlls/d3dx9_39/Makefile.in
index d97a787..a68ee9f 100644
index 4d17120..d0e2cc9 100644
--- a/dlls/d3dx9_39/Makefile.in
+++ b/dlls/d3dx9_39/Makefile.in
@@ -1,6 +1,6 @@
@@ -409,10 +409,10 @@ index d97a787..a68ee9f 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_40/Makefile.in b/dlls/d3dx9_40/Makefile.in
index 36c5a21..7f2cfe1 100644
index 59f6f3d..0a0d36b 100644
--- a/dlls/d3dx9_40/Makefile.in
+++ b/dlls/d3dx9_40/Makefile.in
@@ -1,6 +1,6 @@
@@ -421,10 +421,10 @@ index 36c5a21..7f2cfe1 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_41/Makefile.in b/dlls/d3dx9_41/Makefile.in
index d4552cf..c5c3ab1 100644
index f18443a..f477a20 100644
--- a/dlls/d3dx9_41/Makefile.in
+++ b/dlls/d3dx9_41/Makefile.in
@@ -1,6 +1,6 @@
@@ -433,10 +433,10 @@ index d4552cf..c5c3ab1 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_42/Makefile.in b/dlls/d3dx9_42/Makefile.in
index 5806fce..e9a8e89 100644
index cb142b7..4d93a84 100644
--- a/dlls/d3dx9_42/Makefile.in
+++ b/dlls/d3dx9_42/Makefile.in
@@ -1,6 +1,6 @@
@@ -445,10 +445,10 @@ index 5806fce..e9a8e89 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
diff --git a/dlls/d3dx9_43/Makefile.in b/dlls/d3dx9_43/Makefile.in
index 72ba8b4..33185bf 100644
index 3e6111a..5812d03 100644
--- a/dlls/d3dx9_43/Makefile.in
+++ b/dlls/d3dx9_43/Makefile.in
@@ -1,6 +1,6 @@
@@ -457,8 +457,8 @@ index 72ba8b4..33185bf 100644
-IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32
+IMPORTS = d3d9 d3dcompiler dxguid d3dxof ole32 gdi32 user32 wined3d
PARENTSRC = ../d3dx9_36
DELAYIMPORTS = windowscodecs
C_SRCS = \
--
1.9.1