Rebase against fb4d36c66131d1c45ebdcb5d56151e8f7782ebd1.

This commit is contained in:
Alistair Leslie-Hughes
2023-07-12 08:54:04 +10:00
parent e5cf862a14
commit a88d536fba
5 changed files with 97 additions and 97 deletions

View File

@@ -1,4 +1,4 @@
From 474a1f4337afc7d612dda95b607fd01652aae8f1 Mon Sep 17 00:00:00 2001
From 665645589e51105d02d95507d00eb1d464cdc716 Mon Sep 17 00:00:00 2001
From: Paul Gofman <gofmanp@gmail.com>
Date: Mon, 25 Feb 2019 14:24:50 +0300
Subject: [PATCH] d3d9: Support SWVP vertex shader float constants limits.
@@ -10,7 +10,7 @@ Subject: [PATCH] d3d9: Support SWVP vertex shader float constants limits.
3 files changed, 29 insertions(+), 9 deletions(-)
diff --git a/dlls/d3d9/d3d9_private.h b/dlls/d3d9/d3d9_private.h
index 50c3b38d795..13e93316c6f 100644
index 81a37e7dffc..97c3532c2f4 100644
--- a/dlls/d3d9/d3d9_private.h
+++ b/dlls/d3d9/d3d9_private.h
@@ -40,6 +40,7 @@
@@ -25,13 +25,13 @@ index 50c3b38d795..13e93316c6f 100644
};
void d3d9_caps_from_wined3dcaps(const struct d3d9 *d3d9, unsigned int adapter_ordinal,
- D3DCAPS9 *caps, const struct wined3d_caps *wined3d_caps) DECLSPEC_HIDDEN;
+ D3DCAPS9 *caps, const struct wined3d_caps *wined3d_caps, DWORD flags) DECLSPEC_HIDDEN;
BOOL d3d9_init(struct d3d9 *d3d9, BOOL extended) DECLSPEC_HIDDEN;
- D3DCAPS9 *caps, const struct wined3d_caps *wined3d_caps);
+ D3DCAPS9 *caps, const struct wined3d_caps *wined3d_caps, DWORD flags);
BOOL d3d9_init(struct d3d9 *d3d9, BOOL extended);
struct fvf_declaration
diff --git a/dlls/d3d9/device.c b/dlls/d3d9/device.c
index c8b906a981f..b271d8385b8 100644
index b4bf51f9426..33306a76e32 100644
--- a/dlls/d3d9/device.c
+++ b/dlls/d3d9/device.c
@@ -367,7 +367,7 @@ static BOOL wined3d_swapchain_desc_from_d3d9(struct wined3d_swapchain_desc *swap
@@ -55,7 +55,7 @@ index c8b906a981f..b271d8385b8 100644
caps->NumSimultaneousRTs = min(D3D_MAX_SIMULTANEOUS_RENDERTARGETS, caps->NumSimultaneousRTs);
if (caps->PixelShaderVersion > 3)
@@ -755,6 +758,7 @@ static HRESULT WINAPI d3d9_device_GetDirect3D(IDirect3DDevice9Ex *iface, IDirect
@@ -753,6 +756,7 @@ static HRESULT WINAPI d3d9_device_GetDirect3D(IDirect3DDevice9Ex *iface, IDirect
static HRESULT WINAPI d3d9_device_GetDeviceCaps(IDirect3DDevice9Ex *iface, D3DCAPS9 *caps)
{
struct d3d9_device *device = impl_from_IDirect3DDevice9Ex(iface);
@@ -63,7 +63,7 @@ index c8b906a981f..b271d8385b8 100644
struct wined3d_caps wined3d_caps;
HRESULT hr;
@@ -763,13 +767,15 @@ static HRESULT WINAPI d3d9_device_GetDeviceCaps(IDirect3DDevice9Ex *iface, D3DCA
@@ -761,13 +765,15 @@ static HRESULT WINAPI d3d9_device_GetDeviceCaps(IDirect3DDevice9Ex *iface, D3DCA
if (!caps)
return D3DERR_INVALIDCALL;
@@ -80,7 +80,7 @@ index c8b906a981f..b271d8385b8 100644
return hr;
}
@@ -3654,14 +3660,20 @@ static HRESULT WINAPI d3d9_device_SetVertexShaderConstantF(IDirect3DDevice9Ex *i
@@ -3655,14 +3661,20 @@ static HRESULT WINAPI d3d9_device_SetVertexShaderConstantF(IDirect3DDevice9Ex *i
UINT reg_idx, const float *data, UINT count)
{
struct d3d9_device *device = impl_from_IDirect3DDevice9Ex(iface);
@@ -103,7 +103,7 @@ index c8b906a981f..b271d8385b8 100644
return D3DERR_INVALIDCALL;
}
@@ -3677,14 +3689,21 @@ static HRESULT WINAPI d3d9_device_GetVertexShaderConstantF(IDirect3DDevice9Ex *i
@@ -3678,14 +3690,21 @@ static HRESULT WINAPI d3d9_device_GetVertexShaderConstantF(IDirect3DDevice9Ex *i
UINT start_idx, float *constants, UINT count)
{
struct d3d9_device *device = impl_from_IDirect3DDevice9Ex(iface);
@@ -126,7 +126,7 @@ index c8b906a981f..b271d8385b8 100644
{
WARN("Trying to access %u constants, but d3d9 only supports %u\n",
start_idx + count, device->vs_uniform_count);
@@ -4742,7 +4761,7 @@ HRESULT device_init(struct d3d9_device *device, struct d3d9 *parent, struct wine
@@ -4702,7 +4721,7 @@ HRESULT device_init(struct d3d9_device *device, struct d3d9 *parent, struct wine
device->immediate_context = wined3d_device_get_immediate_context(device->wined3d_device);
wined3d_get_device_caps(wined3d_adapter, wined3d_device_type_from_d3d(device_type), &wined3d_caps);
@@ -136,10 +136,10 @@ index c8b906a981f..b271d8385b8 100644
device->vs_uniform_count = caps.MaxVertexShaderConst;
if (flags & D3DCREATE_ADAPTERGROUP_DEVICE)
diff --git a/dlls/d3d9/directx.c b/dlls/d3d9/directx.c
index b6cb25cf8ea..72e86f95f0c 100644
index 2a7a0ff3368..59b6b9910b9 100644
--- a/dlls/d3d9/directx.c
+++ b/dlls/d3d9/directx.c
@@ -450,7 +450,7 @@ static HRESULT WINAPI d3d9_GetDeviceCaps(IDirect3D9Ex *iface, UINT adapter, D3DD
@@ -447,7 +447,7 @@ static HRESULT WINAPI d3d9_GetDeviceCaps(IDirect3D9Ex *iface, UINT adapter, D3DD
hr = wined3d_get_device_caps(wined3d_adapter, wined3d_device_type_from_d3d(device_type), &wined3d_caps);
wined3d_mutex_unlock();
@@ -149,5 +149,5 @@ index b6cb25cf8ea..72e86f95f0c 100644
return hr;
}
--
2.30.2
2.40.1