diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index 7f2cebbb..028ee7e6 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -51,7 +51,7 @@ usage() # Get the upstream commit sha upstream_commit() { - echo "7fe9858988eabf377ab5e2c64d92f973574b1ae8" + echo "0c83f4d5bec8b01e1e6dcbb0a9a9932b6c24570b" } # Show version information diff --git a/patches/wined3d-CSMT_Main/0010-wined3d-Hackily-introduce-a-multithreaded-command-st.patch b/patches/wined3d-CSMT_Main/0010-wined3d-Hackily-introduce-a-multithreaded-command-st.patch index 40b595cf..e4a0975e 100644 --- a/patches/wined3d-CSMT_Main/0010-wined3d-Hackily-introduce-a-multithreaded-command-st.patch +++ b/patches/wined3d-CSMT_Main/0010-wined3d-Hackily-introduce-a-multithreaded-command-st.patch @@ -1,4 +1,4 @@ -From 1ba3d1dcdb9ee4a1d33a333fdac6cd9f4e86443c Mon Sep 17 00:00:00 2001 +From 37e72e356c337dad588e39ddb603a4f17d9d2ddc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Tue, 1 Oct 2013 14:31:56 +0200 Subject: wined3d: Hackily introduce a multithreaded command stream @@ -771,18 +771,18 @@ index a83459c..3bcbf19 100644 HeapFree(GetProcessHeap(), 0, cs); } diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c -index 434d32e..beeb9fa 100644 +index 1dd6a8b..f573dcb 100644 --- a/dlls/wined3d/wined3d_main.c +++ b/dlls/wined3d/wined3d_main.c -@@ -90,6 +90,7 @@ struct wined3d_settings wined3d_settings = - ~0U, /* No GS shader model limit by default. */ +@@ -91,6 +91,7 @@ struct wined3d_settings wined3d_settings = ~0U, /* No PS shader model limit by default. */ + ~0u, /* No CS shader model limit by default. */ FALSE, /* 3D support enabled by default. */ + FALSE, /* No multithreaded CS by default. */ }; struct wined3d * CDECL wined3d_create(DWORD flags) -@@ -331,6 +332,14 @@ static BOOL wined3d_dll_init(HINSTANCE hInstDLL) +@@ -334,6 +335,14 @@ static BOOL wined3d_dll_init(HINSTANCE hInstDLL) TRACE("Disabling 3D support.\n"); wined3d_settings.no_3d = TRUE; } @@ -798,18 +798,18 @@ index 434d32e..beeb9fa 100644 if (appkey) RegCloseKey( appkey ); diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 7bb86d6..d37f30e 100644 +index edb4399..29f218e 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -309,6 +309,7 @@ struct wined3d_settings - unsigned int max_sm_gs; +@@ -310,6 +310,7 @@ struct wined3d_settings unsigned int max_sm_ps; + unsigned int max_sm_cs; BOOL no_3d; + BOOL cs_multithreaded; }; extern struct wined3d_settings wined3d_settings DECLSPEC_HIDDEN; -@@ -2907,6 +2908,18 @@ HRESULT state_init(struct wined3d_state *state, const struct wined3d_gl_info *gl +@@ -2921,6 +2922,18 @@ HRESULT state_init(struct wined3d_state *state, const struct wined3d_gl_info *gl const struct wined3d_d3d_info *d3d_info, DWORD flags) DECLSPEC_HIDDEN; void state_unbind_resources(struct wined3d_state *state) DECLSPEC_HIDDEN; @@ -828,7 +828,7 @@ index 7bb86d6..d37f30e 100644 struct wined3d_cs_ops { void *(*require_space)(struct wined3d_cs *cs, size_t size); -@@ -2918,9 +2931,14 @@ struct wined3d_cs +@@ -2932,9 +2945,14 @@ struct wined3d_cs const struct wined3d_cs_ops *ops; struct wined3d_device *device; struct wined3d_state state; diff --git a/patches/wined3d-CSMT_Main/0015-wined3d-Send-float-constant-updates-through-the-comm.patch b/patches/wined3d-CSMT_Main/0015-wined3d-Send-float-constant-updates-through-the-comm.patch index 973a2aec..f83ebb67 100644 --- a/patches/wined3d-CSMT_Main/0015-wined3d-Send-float-constant-updates-through-the-comm.patch +++ b/patches/wined3d-CSMT_Main/0015-wined3d-Send-float-constant-updates-through-the-comm.patch @@ -1,16 +1,16 @@ -From 7d7e3691cdb6482d0873883abc6a611e30f57edb Mon Sep 17 00:00:00 2001 +From cd89d4b13a8465eca49e4999b43d85d86706c580 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Tue, 20 Aug 2013 15:12:26 +0200 Subject: wined3d: Send float constant updates through the command stream --- - dlls/wined3d/cs.c | 74 +++++++++++++++++++++++++++++++++++++++--- + dlls/wined3d/cs.c | 75 +++++++++++++++++++++++++++++++++++++++--- dlls/wined3d/device.c | 6 ++-- dlls/wined3d/wined3d_private.h | 2 ++ - 3 files changed, 76 insertions(+), 6 deletions(-) + 3 files changed, 77 insertions(+), 6 deletions(-) diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c -index b128af1..1c1987a 100644 +index b128af1..538ca87 100644 --- a/dlls/wined3d/cs.c +++ b/dlls/wined3d/cs.c @@ -65,6 +65,8 @@ enum wined3d_cs_op @@ -61,7 +61,7 @@ index b128af1..1c1987a 100644 /* FIXME: This is not ideal. CS is still running synchronously, so this is ok. * It will go away soon anyway. */ -@@ -1051,6 +1057,64 @@ void wined3d_cs_emit_set_shader(struct wined3d_cs *cs, enum wined3d_shader_type +@@ -1051,6 +1057,65 @@ void wined3d_cs_emit_set_shader(struct wined3d_cs *cs, enum wined3d_shader_type cs->ops->submit(cs); } @@ -110,7 +110,8 @@ index b128af1..1c1987a 100644 + case WINED3D_SHADER_TYPE_GEOMETRY: + case WINED3D_SHADER_TYPE_HULL: + case WINED3D_SHADER_TYPE_DOMAIN: -+ FIXME("Invalid for geometry shaders\n"); ++ case WINED3D_SHADER_TYPE_COMPUTE: ++ FIXME("Invalid for geometry/compute shaders\n"); + return; + + case WINED3D_SHADER_TYPE_COUNT: @@ -126,7 +127,7 @@ index b128af1..1c1987a 100644 static UINT wined3d_cs_exec_set_render_state(struct wined3d_cs *cs, const void *data) { const struct wined3d_cs_set_render_state *op = data; -@@ -1349,6 +1413,8 @@ static UINT (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void +@@ -1349,6 +1414,8 @@ static UINT (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void /* WINED3D_CS_OP_RESET_STATE */ wined3d_cs_exec_reset_state, /* WINED3D_CS_OP_DESTROY_OBJECT */ wined3d_cs_exec_destroy_object, /* WINED3D_CS_OP_STATEBLOCK */ wined3d_cs_exec_transfer_stateblock, @@ -160,10 +161,10 @@ index 33b7fc3..4b2ea91 100644 return WINED3D_OK; } diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index f27dc4e..07ca86c 100644 +index 3fc5b66..8f5c563 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -2996,6 +2996,8 @@ void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform +@@ -3010,6 +3010,8 @@ void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform void wined3d_cs_emit_set_vertex_declaration(struct wined3d_cs *cs, struct wined3d_vertex_declaration *declaration) DECLSPEC_HIDDEN; void wined3d_cs_emit_set_viewport(struct wined3d_cs *cs, const struct wined3d_viewport *viewport) DECLSPEC_HIDDEN; diff --git a/patches/wined3d-CSMT_Main/0024-wined3d-Send-bool-constant-updates-through-the-comma.patch b/patches/wined3d-CSMT_Main/0024-wined3d-Send-bool-constant-updates-through-the-comma.patch index 7219c4c3..2b099c84 100644 --- a/patches/wined3d-CSMT_Main/0024-wined3d-Send-bool-constant-updates-through-the-comma.patch +++ b/patches/wined3d-CSMT_Main/0024-wined3d-Send-bool-constant-updates-through-the-comma.patch @@ -1,16 +1,16 @@ -From e7526c85b4cb8c71e64234c9a3fa932f80261aa4 Mon Sep 17 00:00:00 2001 +From a76d4c29517eed17544b8dcfb9e8194bec6d60e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Tue, 9 Apr 2013 21:50:30 +0200 Subject: wined3d: Send bool constant updates through the command stream --- - dlls/wined3d/cs.c | 72 +++++++++++++++++++++++++++++++++++++++--- + dlls/wined3d/cs.c | 73 +++++++++++++++++++++++++++++++++++++++--- dlls/wined3d/device.c | 8 +++-- dlls/wined3d/wined3d_private.h | 3 ++ - 3 files changed, 76 insertions(+), 7 deletions(-) + 3 files changed, 77 insertions(+), 7 deletions(-) diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c -index d240c33..ff98e30 100644 +index 48c101e..ffec875 100644 --- a/dlls/wined3d/cs.c +++ b/dlls/wined3d/cs.c @@ -66,7 +66,9 @@ enum wined3d_cs_op @@ -60,7 +60,7 @@ index d240c33..ff98e30 100644 memcpy(op->state.ps_consts_i, state->ps_consts_i, sizeof(op->state.ps_consts_i)); /* FIXME: This is not ideal. CS is still running synchronously, so this is ok. -@@ -1164,6 +1170,62 @@ void wined3d_cs_emit_set_render_state(struct wined3d_cs *cs, enum wined3d_render +@@ -1165,6 +1171,63 @@ void wined3d_cs_emit_set_render_state(struct wined3d_cs *cs, enum wined3d_render op->value = value; cs->ops->submit(cs); @@ -109,7 +109,8 @@ index d240c33..ff98e30 100644 + case WINED3D_SHADER_TYPE_GEOMETRY: + case WINED3D_SHADER_TYPE_DOMAIN: + case WINED3D_SHADER_TYPE_HULL: -+ FIXME("Invalid for geometry shaders\n"); ++ case WINED3D_SHADER_TYPE_COMPUTE: ++ FIXME("Invalid for geometry/compute shaders\n"); + return; + + case WINED3D_SHADER_TYPE_COUNT: @@ -123,7 +124,7 @@ index d240c33..ff98e30 100644 } static UINT wined3d_cs_exec_set_texture_state(struct wined3d_cs *cs, const void *data) -@@ -1514,7 +1576,9 @@ static UINT (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void +@@ -1515,7 +1578,9 @@ static UINT (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void /* WINED3D_CS_OP_DESTROY_OBJECT */ wined3d_cs_exec_destroy_object, /* WINED3D_CS_OP_STATEBLOCK */ wined3d_cs_exec_transfer_stateblock, /* WINED3D_CS_OP_SET_VS_CONSTS_F */ wined3d_cs_exec_set_vs_consts_f, @@ -167,10 +168,10 @@ index 0b8534a..1b2e7e3 100644 return WINED3D_OK; diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 016c5c6..eb91406 100644 +index 8ad91bc..3e09851 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -2416,6 +2416,7 @@ LRESULT device_process_message(struct wined3d_device *device, HWND window, BOOL +@@ -2430,6 +2430,7 @@ LRESULT device_process_message(struct wined3d_device *device, HWND window, BOOL void device_resource_add(struct wined3d_device *device, struct wined3d_resource *resource) DECLSPEC_HIDDEN; void device_resource_released(struct wined3d_device *device, struct wined3d_resource *resource) DECLSPEC_HIDDEN; void device_invalidate_state(const struct wined3d_device *device, DWORD state) DECLSPEC_HIDDEN; @@ -178,7 +179,7 @@ index 016c5c6..eb91406 100644 static inline BOOL isStateDirty(const struct wined3d_context *context, DWORD state) { -@@ -2996,6 +2997,8 @@ void wined3d_cs_emit_set_vertex_declaration(struct wined3d_cs *cs, +@@ -3010,6 +3011,8 @@ void wined3d_cs_emit_set_vertex_declaration(struct wined3d_cs *cs, void wined3d_cs_emit_set_viewport(struct wined3d_cs *cs, const struct wined3d_viewport *viewport) DECLSPEC_HIDDEN; void wined3d_cs_emit_set_consts_f(struct wined3d_cs *cs, unsigned int start_idx, unsigned int count, const struct wined3d_vec4 *constants, enum wined3d_shader_type type) DECLSPEC_HIDDEN; diff --git a/patches/wined3d-CSMT_Main/0025-wined3d-Send-int-constant-updates-through-the-comman.patch b/patches/wined3d-CSMT_Main/0025-wined3d-Send-int-constant-updates-through-the-comman.patch index 0c3c1283..cb9eba08 100644 --- a/patches/wined3d-CSMT_Main/0025-wined3d-Send-int-constant-updates-through-the-comman.patch +++ b/patches/wined3d-CSMT_Main/0025-wined3d-Send-int-constant-updates-through-the-comman.patch @@ -1,19 +1,19 @@ -From 707777525757c44e81b04ef97cf88015a2a7fa7d Mon Sep 17 00:00:00 2001 +From 53a64b6c48b846b82a5ca1c48465572bcc059c4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Wed, 10 Apr 2013 14:20:47 +0200 Subject: wined3d: Send int constant updates through the command stream --- - dlls/wined3d/cs.c | 74 ++++++++++++++++++++++++++++++++++++++---- + dlls/wined3d/cs.c | 75 ++++++++++++++++++++++++++++++++++++++---- dlls/wined3d/device.c | 6 ++-- dlls/wined3d/wined3d_private.h | 2 ++ - 3 files changed, 74 insertions(+), 8 deletions(-) + 3 files changed, 75 insertions(+), 8 deletions(-) diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c -index 4c9e11e..03bed96 100644 +index ffec875..de5767e 100644 --- a/dlls/wined3d/cs.c +++ b/dlls/wined3d/cs.c -@@ -66,8 +66,10 @@ enum wined3d_cs_op +@@ -67,8 +67,10 @@ enum wined3d_cs_op WINED3D_CS_OP_STATEBLOCK, WINED3D_CS_OP_SET_VS_CONSTS_F, WINED3D_CS_OP_SET_VS_CONSTS_B, @@ -24,7 +24,7 @@ index 4c9e11e..03bed96 100644 WINED3D_CS_OP_GLFINISH, WINED3D_CS_OP_SET_BASE_VERTEX_INDEX, WINED3D_CS_OP_SET_PRIMITIVE_TYPE, -@@ -303,6 +305,14 @@ struct wined3d_cs_set_consts_b +@@ -313,6 +315,14 @@ struct wined3d_cs_set_consts_b BOOL constants[1]; }; @@ -39,7 +39,7 @@ index 4c9e11e..03bed96 100644 struct wined3d_cs_finish { enum wined3d_cs_op opcode; -@@ -971,9 +981,6 @@ static UINT wined3d_cs_exec_transfer_stateblock(struct wined3d_cs *cs, const voi +@@ -992,9 +1002,6 @@ static UINT wined3d_cs_exec_transfer_stateblock(struct wined3d_cs *cs, const voi /* Don't memcpy the entire struct, we'll remove single items as we add dedicated * ops for setting states */ @@ -49,7 +49,7 @@ index 4c9e11e..03bed96 100644 memcpy(cs->state.lights, op->state.lights, sizeof(cs->state.lights)); -@@ -989,9 +996,6 @@ void wined3d_cs_emit_transfer_stateblock(struct wined3d_cs *cs, const struct win +@@ -1010,9 +1017,6 @@ void wined3d_cs_emit_transfer_stateblock(struct wined3d_cs *cs, const struct win /* Don't memcpy the entire struct, we'll remove single items as we add dedicated * ops for setting states */ @@ -59,7 +59,7 @@ index 4c9e11e..03bed96 100644 /* FIXME: This is not ideal. CS is still running synchronously, so this is ok. * It will go away soon anyway. */ -@@ -1207,6 +1211,62 @@ void wined3d_cs_emit_set_consts_b(struct wined3d_cs *cs, unsigned int start_idx, +@@ -1230,6 +1234,63 @@ void wined3d_cs_emit_set_consts_b(struct wined3d_cs *cs, unsigned int start_idx, cs->ops->submit(cs); } @@ -106,7 +106,8 @@ index 4c9e11e..03bed96 100644 + case WINED3D_SHADER_TYPE_GEOMETRY: + case WINED3D_SHADER_TYPE_DOMAIN: + case WINED3D_SHADER_TYPE_HULL: -+ ERR("Invalid for geometry shaders\n"); ++ case WINED3D_SHADER_TYPE_COMPUTE: ++ FIXME("Invalid for geometry/compute shaders\n"); + return; + + case WINED3D_SHADER_TYPE_COUNT: @@ -122,7 +123,7 @@ index 4c9e11e..03bed96 100644 static UINT wined3d_cs_exec_set_texture_state(struct wined3d_cs *cs, const void *data) { const struct wined3d_cs_set_texture_state *op = data; -@@ -1534,8 +1594,10 @@ static UINT (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void +@@ -1579,8 +1640,10 @@ static UINT (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void /* WINED3D_CS_OP_STATEBLOCK */ wined3d_cs_exec_transfer_stateblock, /* WINED3D_CS_OP_SET_VS_CONSTS_F */ wined3d_cs_exec_set_vs_consts_f, /* WINED3D_CS_OP_SET_VS_CONSTS_B */ wined3d_cs_exec_set_vs_consts_b, @@ -134,10 +135,10 @@ index 4c9e11e..03bed96 100644 /* WINED3D_CS_OP_SET_BASE_VERTEX_INDEX */ wined3d_cs_exec_set_base_vertex_index, /* WINED3D_CS_OP_SET_PRIMITIVE_TYPE */ wined3d_cs_exec_set_primitive_type, diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c -index dfb4ceb..c9828b1 100644 +index 1b2e7e3..766e393 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c -@@ -2440,7 +2440,8 @@ HRESULT CDECL wined3d_device_set_vs_consts_i(struct wined3d_device *device, +@@ -2457,7 +2457,8 @@ HRESULT CDECL wined3d_device_set_vs_consts_i(struct wined3d_device *device, } else { @@ -147,7 +148,7 @@ index dfb4ceb..c9828b1 100644 } return WINED3D_OK; -@@ -2675,7 +2676,8 @@ HRESULT CDECL wined3d_device_set_ps_consts_i(struct wined3d_device *device, +@@ -2692,7 +2693,8 @@ HRESULT CDECL wined3d_device_set_ps_consts_i(struct wined3d_device *device, } else { @@ -158,10 +159,10 @@ index dfb4ceb..c9828b1 100644 return WINED3D_OK; diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 4fd446e..2a31939 100644 +index 3e09851..b783c7e 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -2952,6 +2952,8 @@ void wined3d_cs_emit_set_consts_f(struct wined3d_cs *cs, unsigned int start_idx, +@@ -3013,6 +3013,8 @@ void wined3d_cs_emit_set_consts_f(struct wined3d_cs *cs, unsigned int start_idx, unsigned int count, const struct wined3d_vec4 *constants, enum wined3d_shader_type type) DECLSPEC_HIDDEN; void wined3d_cs_emit_set_consts_b(struct wined3d_cs *cs, unsigned int start_idx, unsigned int count, const BOOL *constants, enum wined3d_shader_type type) DECLSPEC_HIDDEN; diff --git a/patches/wined3d-CSMT_Main/9998-wined3d-Enable-CSMT-by-default-print-a-winediag-mess.patch b/patches/wined3d-CSMT_Main/9998-wined3d-Enable-CSMT-by-default-print-a-winediag-mess.patch index 5cb74b6a..a7a61b51 100644 --- a/patches/wined3d-CSMT_Main/9998-wined3d-Enable-CSMT-by-default-print-a-winediag-mess.patch +++ b/patches/wined3d-CSMT_Main/9998-wined3d-Enable-CSMT-by-default-print-a-winediag-mess.patch @@ -1,4 +1,4 @@ -From 15743cdf9ab5a5587fd431349f0c91e65072f52b Mon Sep 17 00:00:00 2001 +From 72c0664f2c271e1c34ad08b9916307dd9345efb7 Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Sun, 14 Dec 2014 20:15:44 +0100 Subject: wined3d: Enable CSMT by default, print a winediag message informing @@ -9,19 +9,19 @@ Subject: wined3d: Enable CSMT by default, print a winediag message informing 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c -index 3fac0cf..c1156bd 100644 +index ec6a63d..3c7e6f1 100644 --- a/dlls/wined3d/wined3d_main.c +++ b/dlls/wined3d/wined3d_main.c -@@ -90,7 +90,7 @@ struct wined3d_settings wined3d_settings = - ~0U, /* No GS shader model limit by default. */ +@@ -91,7 +91,7 @@ struct wined3d_settings wined3d_settings = ~0U, /* No PS shader model limit by default. */ + ~0u, /* No CS shader model limit by default. */ FALSE, /* 3D support enabled by default. */ - FALSE, /* No multithreaded CS by default. */ + TRUE, /* Multithreaded CS by default. */ }; struct wined3d * CDECL wined3d_create(DWORD flags) -@@ -333,13 +333,16 @@ static BOOL wined3d_dll_init(HINSTANCE hInstDLL) +@@ -336,13 +336,16 @@ static BOOL wined3d_dll_init(HINSTANCE hInstDLL) wined3d_settings.no_3d = TRUE; } if (!get_config_key(hkey, appkey, "CSMT", buffer, size) diff --git a/patches/wined3d-CSMT_Main/9999-IfDefined.patch b/patches/wined3d-CSMT_Main/9999-IfDefined.patch index 698d31b4..f0e06a26 100644 --- a/patches/wined3d-CSMT_Main/9999-IfDefined.patch +++ b/patches/wined3d-CSMT_Main/9999-IfDefined.patch @@ -100,7 +100,7 @@ diff --git a/dlls/wined3d/arb_program_shader.c b/dlls/wined3d/arb_program_shader shader_arb_ps_local_constants(compiled, context, state, rt_height); } -@@ -8012,11 +8024,16 @@ +@@ -8015,11 +8027,16 @@ /* Leave the opengl state valid for blitting */ arbfp_blit_unset(context->gl_info); @@ -546,7 +546,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c /* Initialize the texture unit mapping to a 1:1 mapping */ for (s = 0; s < MAX_COMBINED_SAMPLERS; ++s) { -@@ -2008,7 +2010,9 @@ +@@ -2009,7 +2011,9 @@ if (hdc) wined3d_release_dc(swapchain->win_handle, hdc); device->shader_backend->shader_free_context_data(ret); device->adapter->fragment_pipe->free_context_data(ret); @@ -556,7 +556,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c HeapFree(GetProcessHeap(), 0, ret->free_event_queries); HeapFree(GetProcessHeap(), 0, ret->free_occlusion_queries); HeapFree(GetProcessHeap(), 0, ret->free_timestamp_queries); -@@ -2045,7 +2049,9 @@ +@@ -2046,7 +2050,9 @@ device->shader_backend->shader_free_context_data(context); device->adapter->fragment_pipe->free_context_data(context); HeapFree(GetProcessHeap(), 0, context->fbo_key); @@ -566,7 +566,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c HeapFree(GetProcessHeap(), 0, context->draw_buffers); HeapFree(GetProcessHeap(), 0, context->blit_targets); device_context_remove(device, context); -@@ -2461,6 +2467,9 @@ +@@ -2462,6 +2468,9 @@ { /* Onscreen surfaces are always in a swapchain */ struct wined3d_swapchain *swapchain = context->current_rt.texture->swapchain; @@ -576,7 +576,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c if (context->render_offscreen || !depth_stencil) return; if (match_depth_stencil_format(swapchain->ds_format, depth_stencil->format)) return; -@@ -2471,8 +2480,13 @@ +@@ -2472,8 +2481,13 @@ WARN("Depth stencil format is not supported by WGL, rendering the backbuffer in an FBO\n"); /* The currently active context is the necessary context to access the swapchain's onscreen buffers */ @@ -590,7 +590,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c swapchain->render_to_fbo = TRUE; swapchain_update_draw_bindings(swapchain); context_set_render_offscreen(context, TRUE); -@@ -2573,7 +2587,11 @@ +@@ -2574,7 +2588,11 @@ } /* Context activation is done by the caller. */ @@ -602,7 +602,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c UINT rt_count, const struct wined3d_fb_state *fb) { struct wined3d_rendertarget_view **rts = fb->render_targets; -@@ -2582,7 +2600,11 @@ +@@ -2583,7 +2601,11 @@ DWORD rt_mask = 0, *cur_mask; UINT i; @@ -614,7 +614,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c || rt_count != gl_info->limits.buffers) { if (!context_validate_rt_config(rt_count, rts, dsv)) -@@ -2627,8 +2649,10 @@ +@@ -2628,8 +2650,10 @@ rt_mask = context_generate_rt_mask_no_fbo(context, rt_count ? wined3d_rendertarget_view_get_surface(rts[0])->container : NULL); } @@ -625,7 +625,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c } else if (wined3d_settings.offscreen_rendering_mode == ORM_FBO && (!rt_count || wined3d_resource_is_offscreen(rts[0]->resource))) -@@ -2669,8 +2693,12 @@ +@@ -2670,8 +2694,12 @@ gl_info->gl_ops.gl.p_glEnable(GL_SCISSOR_TEST); if (rt_count && gl_info->supported[ARB_FRAMEBUFFER_SRGB]) { @@ -638,7 +638,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c gl_info->gl_ops.gl.p_glEnable(GL_FRAMEBUFFER_SRGB); else gl_info->gl_ops.gl.p_glDisable(GL_FRAMEBUFFER_SRGB); -@@ -2687,7 +2715,11 @@ +@@ -2688,7 +2716,11 @@ static DWORD find_draw_buffers_mask(const struct wined3d_context *context, const struct wined3d_state *state) { @@ -650,7 +650,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c struct wined3d_shader *ps = state->shader[WINED3D_SHADER_TYPE_PIXEL]; DWORD rt_mask, rt_mask_bits; unsigned int i; -@@ -2717,7 +2749,11 @@ +@@ -2718,7 +2750,11 @@ void context_state_fb(struct wined3d_context *context, const struct wined3d_state *state, DWORD state_id) { DWORD rt_mask = find_draw_buffers_mask(context, state); @@ -662,7 +662,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c DWORD *cur_mask; if (wined3d_settings.offscreen_rendering_mode == ORM_FBO) -@@ -2748,8 +2784,10 @@ +@@ -2749,8 +2785,10 @@ context_apply_draw_buffers(context, rt_mask); *cur_mask = rt_mask; } @@ -673,7 +673,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c } static void context_map_stage(struct wined3d_context *context, DWORD stage, DWORD unit) -@@ -3381,7 +3419,11 @@ +@@ -3382,7 +3420,11 @@ const struct wined3d_device *device, const struct wined3d_state *state) { const struct StateEntry *state_table = context->state_table; @@ -685,7 +685,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c unsigned int i; WORD map; -@@ -3414,12 +3456,17 @@ +@@ -3415,12 +3457,17 @@ for (i = 0, map = context->stream_info.use_map; map; map >>= 1, ++i) { if (map & 1) @@ -703,7 +703,7 @@ diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c } if (state->index_buffer) { -@@ -3538,9 +3585,11 @@ +@@ -3539,9 +3586,11 @@ TRACE("device %p, target %p.\n", device, target); @@ -1326,7 +1326,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1384,6 +1635,17 @@ +@@ -1385,6 +1636,17 @@ device_invalidate_state(cs->device, STATE_RENDER(op->state)); return sizeof(*op); @@ -1344,7 +1344,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_set_render_state(struct wined3d_cs *cs, enum wined3d_render_state state, DWORD value) -@@ -1395,6 +1657,7 @@ +@@ -1396,6 +1658,7 @@ op->state = state; op->value = value; @@ -1352,7 +1352,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1520,6 +1783,17 @@ +@@ -1523,6 +1786,17 @@ device_invalidate_state(cs->device, STATE_TEXTURESTAGE(op->stage, op->state)); return sizeof(*op); @@ -1370,7 +1370,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_set_texture_state(struct wined3d_cs *cs, UINT stage, -@@ -1533,6 +1807,7 @@ +@@ -1536,6 +1810,7 @@ op->state = state; op->value = value; @@ -1378,7 +1378,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1544,6 +1819,17 @@ +@@ -1547,6 +1822,17 @@ device_invalidate_state(cs->device, STATE_SAMPLER(op->sampler_idx)); return sizeof(*op); @@ -1396,7 +1396,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_set_sampler_state(struct wined3d_cs *cs, UINT sampler_idx, -@@ -1557,6 +1843,7 @@ +@@ -1560,6 +1846,7 @@ op->state = state; op->value = value; @@ -1404,7 +1404,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1569,6 +1856,18 @@ +@@ -1572,6 +1859,18 @@ device_invalidate_state(cs->device, STATE_TRANSFORM(op->state)); return sizeof(*op); @@ -1423,7 +1423,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform_state state, -@@ -1581,6 +1880,7 @@ +@@ -1584,6 +1883,7 @@ op->state = state; op->matrix = *matrix; @@ -1431,7 +1431,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1592,6 +1892,17 @@ +@@ -1595,6 +1895,17 @@ device_invalidate_state(cs->device, STATE_CLIPPLANE(op->plane_idx)); return sizeof(*op); @@ -1449,7 +1449,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_set_clip_plane(struct wined3d_cs *cs, UINT plane_idx, const struct wined3d_vec4 *plane) -@@ -1603,10 +1914,17 @@ +@@ -1606,10 +1917,17 @@ op->plane_idx = plane_idx; op->plane = *plane; @@ -1467,7 +1467,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c { const struct wined3d_cs_set_color_key *op = data; struct wined3d_texture *texture = op->texture; -@@ -1667,8 +1985,10 @@ +@@ -1670,8 +1988,10 @@ break; } } @@ -1478,7 +1478,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_set_color_key(struct wined3d_cs *cs, struct wined3d_texture *texture, -@@ -1688,6 +2008,7 @@ +@@ -1691,6 +2011,7 @@ else op->set = 0; @@ -1486,7 +1486,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1699,6 +2020,17 @@ +@@ -1702,6 +2023,17 @@ device_invalidate_state(cs->device, STATE_MATERIAL); return sizeof(*op); @@ -1504,7 +1504,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_set_material(struct wined3d_cs *cs, const struct wined3d_material *material) -@@ -1709,6 +2041,7 @@ +@@ -1712,6 +2044,7 @@ op->opcode = WINED3D_CS_OP_SET_MATERIAL; op->material = *material; @@ -1512,7 +1512,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1724,6 +2057,19 @@ +@@ -1727,6 +2060,19 @@ ERR("Failed to initialize CS state, hr %#x.\n", hr); return sizeof(struct wined3d_cs_reset_state); @@ -1532,7 +1532,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_reset_state(struct wined3d_cs *cs) -@@ -1733,6 +2079,7 @@ +@@ -1736,6 +2082,7 @@ op = cs->ops->require_space(cs, sizeof(*op)); op->opcode = WINED3D_CS_OP_RESET_STATE; @@ -1540,7 +1540,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -1743,6 +2090,16 @@ +@@ -1746,6 +2093,16 @@ op->callback(op->object); return sizeof(*op); @@ -1557,7 +1557,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c } void wined3d_cs_emit_destroy_object(struct wined3d_cs *cs, void (*callback)(void *object), void *object) -@@ -1754,6 +2111,7 @@ +@@ -1757,6 +2114,7 @@ op->callback = callback; op->object = object; @@ -1565,7 +1565,7 @@ diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c cs->ops->submit(cs, sizeof(*op)); } -@@ -3055,5 +3413,152 @@ +@@ -3058,5 +3416,152 @@ ERR("Closing event failed.\n"); } @@ -3172,7 +3172,7 @@ diff --git a/dlls/wined3d/drawprim.c b/dlls/wined3d/drawprim.c diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c --- a/dlls/wined3d/glsl_shader.c +++ b/dlls/wined3d/glsl_shader.c -@@ -1470,7 +1470,11 @@ +@@ -1474,7 +1474,11 @@ const struct wined3d_vec4 correction_params = { /* Position is relative to the framebuffer, not the viewport. */ @@ -3184,7 +3184,7 @@ diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c context->render_offscreen ? 1.0f : -1.0f, 0.0f, 0.0f, -@@ -1576,11 +1580,13 @@ +@@ -1580,11 +1584,13 @@ { update_heap_entry(heap, i, priv->next_constant_version); } @@ -3198,7 +3198,7 @@ diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c } static void shader_glsl_update_float_pixel_constants(struct wined3d_device *device, UINT start, UINT count) -@@ -1593,11 +1599,13 @@ +@@ -1597,11 +1603,13 @@ { update_heap_entry(heap, i, priv->next_constant_version); } @@ -3967,7 +3967,7 @@ diff --git a/dlls/wined3d/sampler.c b/dlls/wined3d/sampler.c diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c --- a/dlls/wined3d/shader.c +++ b/dlls/wined3d/shader.c -@@ -2612,6 +2612,7 @@ +@@ -2650,6 +2650,7 @@ return refcount; } @@ -3975,7 +3975,7 @@ diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c static void wined3d_shader_destroy_object(void *object) { struct wined3d_shader *shader = object; -@@ -2620,6 +2621,7 @@ +@@ -2658,6 +2659,7 @@ HeapFree(GetProcessHeap(), 0, shader); } @@ -3983,7 +3983,7 @@ diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c ULONG CDECL wined3d_shader_decref(struct wined3d_shader *shader) { ULONG refcount = InterlockedDecrement(&shader->ref); -@@ -2628,10 +2630,16 @@ +@@ -2666,10 +2668,16 @@ if (!refcount) { @@ -4000,7 +4000,7 @@ diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c } return refcount; -@@ -2952,7 +2960,11 @@ +@@ -2990,7 +2998,11 @@ UINT i; memset(args, 0, sizeof(*args)); /* FIXME: Make sure all bits are set. */ @@ -6588,7 +6588,7 @@ diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c diff --git a/dlls/wined3d/utils.c b/dlls/wined3d/utils.c --- a/dlls/wined3d/utils.c +++ b/dlls/wined3d/utils.c -@@ -4465,7 +4465,11 @@ +@@ -4466,7 +4466,11 @@ float y_offset = context->render_offscreen ? (center_offset - (2.0f * y) - h) / h : (center_offset - (2.0f * y) - h) / -h; @@ -6600,7 +6600,7 @@ diff --git a/dlls/wined3d/utils.c b/dlls/wined3d/utils.c state->render_states[WINED3D_RS_ZENABLE] : WINED3D_ZB_FALSE; float z_scale = zenable ? 2.0f : 0.0f; float z_offset = zenable ? -1.0f : 0.0f; -@@ -5262,7 +5266,11 @@ +@@ -5263,7 +5267,11 @@ break; } } @@ -6762,9 +6762,9 @@ diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c --- a/dlls/wined3d/wined3d_main.c +++ b/dlls/wined3d/wined3d_main.c -@@ -90,7 +90,9 @@ - ~0U, /* No GS shader model limit by default. */ +@@ -91,7 +91,9 @@ ~0U, /* No PS shader model limit by default. */ + ~0u, /* No CS shader model limit by default. */ FALSE, /* 3D support enabled by default. */ +#if defined(STAGING_CSMT) TRUE, /* Multithreaded CS by default. */ @@ -6772,7 +6772,7 @@ diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c }; struct wined3d * CDECL wined3d_create(DWORD flags) -@@ -332,6 +334,7 @@ +@@ -335,6 +337,7 @@ TRACE("Disabling 3D support.\n"); wined3d_settings.no_3d = TRUE; } @@ -6780,7 +6780,7 @@ diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c if (!get_config_key(hkey, appkey, "CSMT", buffer, size) && !strcmp(buffer,"disabled")) { -@@ -342,6 +345,9 @@ +@@ -345,6 +348,9 @@ FIXME_(winediag)("Experimental wined3d CSMT feature is currently %s.\n", wined3d_settings.cs_multithreaded ? "enabled" : "disabled"); @@ -6803,9 +6803,9 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h #include #include #include -@@ -310,7 +312,9 @@ - unsigned int max_sm_gs; +@@ -311,7 +313,9 @@ unsigned int max_sm_ps; + unsigned int max_sm_cs; BOOL no_3d; +#if defined(STAGING_CSMT) BOOL cs_multithreaded; @@ -6813,7 +6813,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h }; extern struct wined3d_settings wined3d_settings DECLSPEC_HIDDEN; -@@ -1316,8 +1320,10 @@ +@@ -1330,8 +1334,10 @@ struct list entry; GLuint id; struct wined3d_context *context; @@ -6824,7 +6824,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h }; union wined3d_gl_query_object -@@ -1353,6 +1359,7 @@ +@@ -1367,6 +1373,7 @@ struct list entry; GLuint id; struct wined3d_context *context; @@ -6832,7 +6832,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h UINT64 timestamp; }; -@@ -1388,6 +1395,12 @@ +@@ -1402,6 +1409,12 @@ for (i = 0; i < min(dst->rt_size, src->rt_size); i++) dst->render_targets[i] = src->render_targets[i]; } @@ -6845,7 +6845,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_context { -@@ -1403,7 +1416,9 @@ +@@ -1417,7 +1430,9 @@ DWORD dirtyArray[STATE_HIGHEST + 1]; /* Won't get bigger than that, a state is never marked dirty 2 times */ DWORD numDirtyEntries; DWORD isStateDirty[STATE_HIGHEST / (sizeof(DWORD) * CHAR_BIT) + 1]; /* Bitmap to find out quickly if a state is dirty */ @@ -6855,7 +6855,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_swapchain *swapchain; struct -@@ -1511,6 +1526,14 @@ +@@ -1525,6 +1540,14 @@ GLuint dummy_arbfp_prog; }; @@ -6870,7 +6870,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h typedef void (*APPLYSTATEFUNC)(struct wined3d_context *ctx, const struct wined3d_state *state, DWORD state_id); struct StateEntry -@@ -1649,7 +1672,11 @@ +@@ -1663,7 +1686,11 @@ void context_alloc_occlusion_query(struct wined3d_context *context, struct wined3d_occlusion_query *query) DECLSPEC_HIDDEN; void context_apply_blit_state(struct wined3d_context *context, const struct wined3d_device *device) DECLSPEC_HIDDEN; @@ -6882,7 +6882,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h UINT rt_count, const struct wined3d_fb_state *fb) DECLSPEC_HIDDEN; BOOL context_apply_draw_state(struct wined3d_context *context, const struct wined3d_device *device, const struct wined3d_state *state) DECLSPEC_HIDDEN; -@@ -2269,7 +2296,11 @@ +@@ -2283,7 +2310,11 @@ struct wined3d_state { DWORD flags; @@ -6894,7 +6894,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_vertex_declaration *vertex_declaration; struct wined3d_stream_output stream_output[MAX_STREAM_OUT]; -@@ -2315,6 +2346,7 @@ +@@ -2329,6 +2360,7 @@ DWORD render_states[WINEHIGHEST_RENDER_STATE + 1]; }; @@ -6902,7 +6902,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_gl_bo { GLuint name; -@@ -2323,6 +2355,7 @@ +@@ -2337,6 +2369,7 @@ UINT size; }; @@ -6910,7 +6910,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h #define WINED3D_UNMAPPED_STAGE ~0U /* Multithreaded flag. Removed from the public header to signal that -@@ -2375,11 +2408,23 @@ +@@ -2389,11 +2422,23 @@ struct wined3d_rendertarget_view *back_buffer_view; struct wined3d_swapchain **swapchains; UINT swapchain_count; @@ -6934,7 +6934,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h /* For rendering to a texture using glCopyTexImage */ GLuint depth_blt_texture; -@@ -2427,6 +2472,7 @@ +@@ -2441,6 +2486,7 @@ UINT message, WPARAM wparam, LPARAM lparam, WNDPROC proc) DECLSPEC_HIDDEN; void device_resource_add(struct wined3d_device *device, struct wined3d_resource *resource) DECLSPEC_HIDDEN; void device_resource_released(struct wined3d_device *device, struct wined3d_resource *resource) DECLSPEC_HIDDEN; @@ -6942,7 +6942,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void device_invalidate_state(const struct wined3d_device *device, DWORD state) DECLSPEC_HIDDEN; void device_invalidate_shader_constants(const struct wined3d_device *device, DWORD mask) DECLSPEC_HIDDEN; void device_exec_update_texture(struct wined3d_context *context, struct wined3d_texture *src_texture, -@@ -2438,6 +2484,11 @@ +@@ -2452,6 +2498,11 @@ void device_create_dummy_textures(struct wined3d_device *device, struct wined3d_context *context) DECLSPEC_HIDDEN; void device_delete_opengl_contexts_cs(struct wined3d_device *device, struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN; @@ -6954,7 +6954,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h static inline BOOL isStateDirty(const struct wined3d_context *context, DWORD state) { -@@ -2481,9 +2532,14 @@ +@@ -2495,9 +2546,14 @@ UINT depth; UINT size; DWORD priority; @@ -6969,7 +6969,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void *parent; const struct wined3d_parent_ops *parent_ops; -@@ -2509,7 +2565,9 @@ +@@ -2523,7 +2579,9 @@ const struct wined3d_resource_ops *resource_ops) DECLSPEC_HIDDEN; void resource_unload(struct wined3d_resource *resource) DECLSPEC_HIDDEN; BOOL wined3d_resource_allocate_sysmem(struct wined3d_resource *resource) DECLSPEC_HIDDEN; @@ -6979,7 +6979,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void wined3d_resource_free_sysmem(struct wined3d_resource *resource) DECLSPEC_HIDDEN; GLbitfield wined3d_resource_gl_map_flags(DWORD d3d_flags) DECLSPEC_HIDDEN; GLenum wined3d_resource_gl_legacy_map_flags(DWORD d3d_flags) DECLSPEC_HIDDEN; -@@ -2517,6 +2575,7 @@ +@@ -2531,6 +2589,7 @@ DWORD wined3d_resource_sanitize_map_flags(const struct wined3d_resource *resource, DWORD flags) DECLSPEC_HIDDEN; void wined3d_resource_update_draw_binding(struct wined3d_resource *resource) DECLSPEC_HIDDEN; @@ -6987,7 +6987,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h static inline void wined3d_resource_inc_fence(struct wined3d_resource *resource) { InterlockedIncrement(&resource->access_fence); -@@ -2532,6 +2591,7 @@ +@@ -2546,6 +2605,7 @@ while(InterlockedCompareExchange(&resource->access_fence, 0, 0)); } @@ -6995,7 +6995,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h /* Tests show that the start address of resources is 32 byte aligned */ #define RESOURCE_ALIGNMENT 16 -@@ -2589,7 +2649,9 @@ +@@ -2603,7 +2663,9 @@ DWORD flags; GLenum target; DWORD update_map_binding; @@ -7005,7 +7005,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h GLuint rb_multisample; GLuint rb_resolved; -@@ -2627,8 +2689,12 @@ +@@ -2641,8 +2703,12 @@ unsigned int map_count; DWORD locations; @@ -7018,7 +7018,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h } sub_resources[1]; }; -@@ -2679,6 +2745,7 @@ +@@ -2693,6 +2759,7 @@ struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; void wined3d_texture_bind_and_dirtify(struct wined3d_texture *texture, struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; @@ -7026,7 +7026,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void wined3d_texture_changed(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_gl_bo *swap_buffer, void *swap_heap_memory) DECLSPEC_HIDDEN; -@@ -2688,6 +2755,13 @@ +@@ -2702,6 +2769,13 @@ GLenum wined3d_texture_get_gl_buffer(const struct wined3d_texture *texture) DECLSPEC_HIDDEN; void wined3d_texture_get_memory(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_bo_address *data, DWORD locations, BOOL map) DECLSPEC_HIDDEN; @@ -7040,7 +7040,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_texture_sub_resource *wined3d_texture_get_sub_resource(struct wined3d_texture *texture, unsigned int sub_resource_idx) DECLSPEC_HIDDEN; void wined3d_texture_invalidate_location(struct wined3d_texture *texture, -@@ -2698,6 +2772,7 @@ +@@ -2712,6 +2786,7 @@ const struct wined3d_gl_info *gl_info, GLenum binding, DWORD flags) DECLSPEC_HIDDEN; BOOL wined3d_texture_prepare_location(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_context *context, DWORD location) DECLSPEC_HIDDEN; @@ -7048,7 +7048,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h BOOL wined3d_texture_load_location(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_context *context, DWORD location); void *wined3d_texture_map_internal(struct wined3d_texture *texture, unsigned int sub_resource_idx, -@@ -2713,6 +2788,15 @@ +@@ -2727,6 +2802,15 @@ const struct wined3d_gl_info *gl_info, GLenum binding) DECLSPEC_HIDDEN; void wined3d_texture_unmap_internal(struct wined3d_texture *texture, unsigned int sub_resource_idx) DECLSPEC_HIDDEN; @@ -7064,7 +7064,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void wined3d_texture_validate_location(struct wined3d_texture *texture, unsigned int sub_resource_idx, DWORD location) DECLSPEC_HIDDEN; -@@ -2830,7 +2914,11 @@ +@@ -2844,7 +2928,11 @@ unsigned int *width, unsigned int *height) DECLSPEC_HIDDEN; void surface_load_fb_texture(struct wined3d_surface *surface, BOOL srgb, struct wined3d_context *context) DECLSPEC_HIDDEN; @@ -7076,7 +7076,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_context *context, DWORD location) DECLSPEC_HIDDEN; void surface_modify_ds_location(struct wined3d_surface *surface, DWORD location, UINT w, UINT h) DECLSPEC_HIDDEN; void surface_set_compatible_renderbuffer(struct wined3d_surface *surface, -@@ -2841,9 +2929,11 @@ +@@ -2855,9 +2943,11 @@ void wined3d_surface_upload_data(struct wined3d_surface *surface, const struct wined3d_gl_info *gl_info, const struct wined3d_format *format, const RECT *src_rect, UINT src_pitch, const POINT *dst_point, BOOL srgb, const struct wined3d_const_bo_address *data) DECLSPEC_HIDDEN; @@ -7088,7 +7088,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void draw_textured_quad(const struct wined3d_surface *src_surface, struct wined3d_context *context, const RECT *src_rect, const RECT *dst_rect, enum wined3d_texture_filter_type filter) DECLSPEC_HIDDEN; -@@ -2858,10 +2948,12 @@ +@@ -2872,10 +2962,12 @@ GLuint name; }; @@ -7101,7 +7101,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_vertex_declaration_element { const struct wined3d_format *format; -@@ -2957,6 +3049,7 @@ +@@ -2971,6 +3063,7 @@ void stateblock_init_contained_states(struct wined3d_stateblock *stateblock) DECLSPEC_HIDDEN; void state_cleanup(struct wined3d_state *state) DECLSPEC_HIDDEN; @@ -7109,7 +7109,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h HRESULT state_init(struct wined3d_state *state, const struct wined3d_gl_info *gl_info, const struct wined3d_d3d_info *d3d_info, DWORD flags) DECLSPEC_HIDDEN; void state_unbind_resources(struct wined3d_state *state) DECLSPEC_HIDDEN; -@@ -3007,6 +3100,44 @@ +@@ -3021,6 +3114,44 @@ void wined3d_cs_destroy(struct wined3d_cs *cs) DECLSPEC_HIDDEN; void wined3d_cs_switch_onscreen_ds(struct wined3d_cs *cs, struct wined3d_context *context, struct wined3d_surface *depth_stencil) DECLSPEC_HIDDEN; @@ -7154,7 +7154,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void wined3d_cs_emit_clear(struct wined3d_cs *cs, DWORD rect_count, const RECT *rects, DWORD flags, const struct wined3d_color *color, float depth, DWORD stencil) DECLSPEC_HIDDEN; -@@ -3057,6 +3188,7 @@ +@@ -3071,6 +3202,7 @@ void wined3d_cs_emit_set_vertex_declaration(struct wined3d_cs *cs, struct wined3d_vertex_declaration *declaration) DECLSPEC_HIDDEN; void wined3d_cs_emit_set_viewport(struct wined3d_cs *cs, const struct wined3d_viewport *viewport) DECLSPEC_HIDDEN; @@ -7162,7 +7162,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void wined3d_cs_emit_set_consts_f(struct wined3d_cs *cs, unsigned int start_idx, unsigned int count, const struct wined3d_vec4 *constants, enum wined3d_shader_type type) DECLSPEC_HIDDEN; void wined3d_cs_emit_set_consts_b(struct wined3d_cs *cs, unsigned int start_idx, -@@ -3115,6 +3247,14 @@ +@@ -3129,6 +3261,14 @@ void wined3d_cs_emit_delete_opengl_contexts(struct wined3d_cs *cs, struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN; void wined3d_cs_emit_update_swap_interval(struct wined3d_cs *cs, struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN; @@ -7177,7 +7177,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h /* Direct3D terminology with little modifications. We do not have an issued state * because only the driver knows about it, but we have a created state because d3d -@@ -3129,8 +3269,12 @@ +@@ -3143,8 +3283,12 @@ struct wined3d_query_ops { HRESULT (*query_get_data)(struct wined3d_query *query, void *data, DWORD data_size, DWORD flags); @@ -7190,7 +7190,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h }; struct wined3d_query -@@ -3144,12 +3288,16 @@ +@@ -3158,12 +3302,16 @@ enum wined3d_query_type type; DWORD data_size; void *extendedData; @@ -7207,7 +7207,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h /* TODO: Add tests and support for FLOAT16_4 POSITIONT, D3DCOLOR position, other * fixed function semantics as D3DCOLOR or FLOAT16 */ -@@ -3176,7 +3324,9 @@ +@@ -3190,7 +3338,9 @@ GLenum buffer_object_usage; GLenum buffer_type_hint; DWORD flags; @@ -7217,7 +7217,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void *map_ptr; struct wined3d_map_range *maps; -@@ -3201,6 +3351,7 @@ +@@ -3215,6 +3365,7 @@ BYTE *buffer_get_sysmem(struct wined3d_buffer *buffer, struct wined3d_context *context) DECLSPEC_HIDDEN; void buffer_internal_preload(struct wined3d_buffer *buffer, struct wined3d_context *context, const struct wined3d_state *state) DECLSPEC_HIDDEN; @@ -7225,7 +7225,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h HRESULT wined3d_buffer_copy(struct wined3d_buffer *dst_buffer, unsigned int dst_offset, struct wined3d_buffer *src_buffer, unsigned int src_offset, unsigned int size) DECLSPEC_HIDDEN; HRESULT wined3d_buffer_upload_data(struct wined3d_buffer *buffer, -@@ -3209,6 +3360,13 @@ +@@ -3223,6 +3374,13 @@ void buffer_swap_mem(struct wined3d_buffer *buffer, BYTE *mem) DECLSPEC_HIDDEN; void buffer_create_buffer_object(struct wined3d_buffer *This, struct wined3d_context *context) DECLSPEC_HIDDEN; @@ -7239,7 +7239,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_rendertarget_view { -@@ -3259,8 +3417,12 @@ +@@ -3273,8 +3431,12 @@ struct wined3d_swapchain_ops { void (*swapchain_present)(struct wined3d_swapchain *swapchain, @@ -7252,7 +7252,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void (*swapchain_frontbuffer_updated)(struct wined3d_swapchain *swapchain); }; -@@ -3296,8 +3458,10 @@ +@@ -3310,8 +3472,10 @@ void wined3d_swapchain_activate(struct wined3d_swapchain *swapchain, BOOL activate) DECLSPEC_HIDDEN; struct wined3d_context *swapchain_get_context(struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN;