From: Matteo Bruni Subject: [PATCH 01/11] wined3d: Set default texture units mapping for vertex shader samplers when possible. Message-Id: <1447366010-5918-2-git-send-email-mbruni@codeweavers.com> Date: Thu, 12 Nov 2015 23:06:40 +0100 In-Reply-To: <1447366010-5918-1-git-send-email-mbruni@codeweavers.com> References: <1447366010-5918-1-git-send-email-mbruni@codeweavers.com> Signed-off-by: Matteo Bruni --- This should fix the low water bug in World of Warships (bug 39347) for drivers that support at least 20 combined texture units (e.g. D3D10+ GPUs on Linux). v2: Simplified, we probably aren't going to change MAX_COMBINED_SAMPLERS in the future. dlls/wined3d/context.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c index 1692d0d..ff2ff4e 100644 --- a/dlls/wined3d/context.c +++ b/dlls/wined3d/context.c @@ -1509,7 +1509,7 @@ struct wined3d_context *context_create(struct wined3d_swapchain *swapchain, /* Initialize the texture unit mapping to a 1:1 mapping */ for (s = 0; s < MAX_COMBINED_SAMPLERS; ++s) { - if (s < gl_info->limits.fragment_samplers) + if (s < gl_info->limits.combined_samplers) { ret->tex_unit_map[s] = s; ret->rev_tex_unit_map[s] = s; -- 2.4.10