From 54cf96ed9738c2dd7403330e20f4913ac6dfe3a9 Mon Sep 17 00:00:00 2001 From: gloriouseggroll Date: Sun, 18 Feb 2018 02:52:26 -0500 Subject: [PATCH] wined3d-buffer_create: remove, mainlined, handled by desc->access: https://github.com/wine-mirror/wine/commit/916c13c6c132edbcfc4558a779813a263d0c4e77 --- patches/patchinstall.sh | 16 ------- ...001-wined3d-Do-not-pin-large-buffers.patch | 47 ------------------- 2 files changed, 63 deletions(-) delete mode 100644 patches/wined3d-buffer_create/0001-wined3d-Do-not-pin-large-buffers.patch diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index c1fc644e..db0312e1 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -452,7 +452,6 @@ patch_enable_all () enable_wined3d_Viewports="$1" enable_wined3d_WINED3DFMT_R32G32_UINT="$1" enable_wined3d_WINED3D_RS_COLORWRITEENABLE="$1" - enable_wined3d_buffer_create="$1" enable_wined3d_dxgi_swapchain_Present="$1" enable_wined3d_sample_c_lz="$1" enable_wined3d_wined3d_guess_gl_vendor="$1" @@ -1615,9 +1614,6 @@ patch_enable () wined3d-WINED3D_RS_COLORWRITEENABLE) enable_wined3d_WINED3D_RS_COLORWRITEENABLE="$2" ;; - wined3d-buffer_create) - enable_wined3d_buffer_create="$2" - ;; wined3d-dxgi_swapchain_Present) enable_wined3d_dxgi_swapchain_Present="$2" ;; @@ -9555,18 +9551,6 @@ if test "$enable_wined3d_WINED3DFMT_R32G32_UINT" -eq 1; then ) >> "$patchlist" fi -# Patchset wined3d-buffer_create -# | -# | Modified files: -# | * dlls/wined3d/buffer.c -# | -if test "$enable_wined3d_buffer_create" -eq 1; then - patch_apply wined3d-buffer_create/0001-wined3d-Do-not-pin-large-buffers.patch - ( - printf '%s\n' '+ { "Michael Müller", "wined3d: Do not pin large buffers.", 1 },'; - ) >> "$patchlist" -fi - # Patchset wined3d-dxgi_swapchain_Present # | # | This patchset has the following (direct or indirect) dependencies: diff --git a/patches/wined3d-buffer_create/0001-wined3d-Do-not-pin-large-buffers.patch b/patches/wined3d-buffer_create/0001-wined3d-Do-not-pin-large-buffers.patch deleted file mode 100644 index e2de4ec5..00000000 --- a/patches/wined3d-buffer_create/0001-wined3d-Do-not-pin-large-buffers.patch +++ /dev/null @@ -1,47 +0,0 @@ -From d9725ddf519112095da4ac55c484681d839d86b0 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Michael=20M=C3=BCller?= -Date: Mon, 6 Mar 2017 17:40:49 +0100 -Subject: wined3d: Do not pin large buffers. - ---- - dlls/wined3d/buffer.c | 16 +++++++++++++++- - 1 file changed, 15 insertions(+), 1 deletion(-) - -diff --git a/dlls/wined3d/buffer.c b/dlls/wined3d/buffer.c -index c584147717b..4b53c42dbfe 100644 ---- a/dlls/wined3d/buffer.c -+++ b/dlls/wined3d/buffer.c -@@ -1455,6 +1455,7 @@ HRESULT CDECL wined3d_buffer_create(struct wined3d_device *device, const struct - struct wined3d_buffer **buffer) - { - struct wined3d_buffer *object; -+ enum wined3d_pool pool; - HRESULT hr; - - TRACE("device %p, desc %p, data %p, parent %p, parent_ops %p, buffer %p.\n", -@@ -1465,8 +1466,21 @@ HRESULT CDECL wined3d_buffer_create(struct wined3d_device *device, const struct - - FIXME("Ignoring access flags (pool).\n"); - -+ /* Some applications map the whole buffer even if they -+ * only update a small portion of it. If we pin such a -+ * buffer into system memory things get very slow as -+ * we upload the whole buffer even though just parts of -+ * it changed. Most drivers can handle this case more -+ * efficient using the OpenGL map functions. Applications -+ * affected by this problem are Banished and Witcher 3. -+ */ -+ if (desc->byte_width > 0x10000) -+ pool = WINED3D_POOL_DEFAULT; -+ else -+ pool = WINED3D_POOL_MANAGED; -+ - if (FAILED(hr = buffer_init(object, device, desc->byte_width, desc->usage, WINED3DFMT_UNKNOWN, -- WINED3D_POOL_MANAGED, desc->bind_flags, data, parent, parent_ops))) -+ pool, desc->bind_flags, data, parent, parent_ops))) - { - WARN("Failed to initialize buffer, hr %#x.\n", hr); - HeapFree(GetProcessHeap(), 0, object); --- -2.11.0 -