From 1ab89ae9bccfdccdfd6fdf90f580fd9fdc6540c4 Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Thu, 8 Oct 2015 18:43:39 +0200 Subject: [PATCH] Rebase against 8dd86823fdd9a5e631cf3173727b6f667ef1b611. --- ...US_INVALID_DEVICE_REQUEST-when-tryi.patch} | 0 ...tests-for-calling-NtReadFile-NtWrite.patch | 74 ------------------- patches/patchinstall.sh | 6 +- ...ve-invalidate_location-to-resource.c.patch | 36 ++++----- ...e-helper-functions-for-mapping-volum.patch | 14 ++-- ...ume-PBO-infrastructure-into-the-reso.patch | 16 ++-- ...ve-buffer-creation-into-the-resource.patch | 24 +++--- ...ove-most-of-volume_map-to-resource.c.patch | 12 +-- ...d3d-Use-resource_map-for-surface_map.patch | 8 +- ...-volume-resource-data-through-the-CS.patch | 14 ++-- .../wined3d-CSMT_Main/9999-IfDefined.patch | 47 ++++++------ ...DXTn-support-and-export-conversion-f.patch | 24 +++--- 12 files changed, 102 insertions(+), 173 deletions(-) rename patches/ntdll-Status_Mapping/{0002-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch => 0001-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch} (100%) delete mode 100644 patches/ntdll-Status_Mapping/0001-ntdll-tests-Add-tests-for-calling-NtReadFile-NtWrite.patch diff --git a/patches/ntdll-Status_Mapping/0002-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch b/patches/ntdll-Status_Mapping/0001-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch similarity index 100% rename from patches/ntdll-Status_Mapping/0002-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch rename to patches/ntdll-Status_Mapping/0001-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch diff --git a/patches/ntdll-Status_Mapping/0001-ntdll-tests-Add-tests-for-calling-NtReadFile-NtWrite.patch b/patches/ntdll-Status_Mapping/0001-ntdll-tests-Add-tests-for-calling-NtReadFile-NtWrite.patch deleted file mode 100644 index 79b18dcd..00000000 --- a/patches/ntdll-Status_Mapping/0001-ntdll-tests-Add-tests-for-calling-NtReadFile-NtWrite.patch +++ /dev/null @@ -1,74 +0,0 @@ -From 42d6405bc17730a5e281f7461891acca7803a8cd Mon Sep 17 00:00:00 2001 -From: Sebastian Lackner -Date: Thu, 24 Sep 2015 01:56:24 +0200 -Subject: ntdll/tests: Add tests for calling NtReadFile/NtWriteFile on - directory. - ---- - dlls/ntdll/tests/file.c | 35 +++++++++++++++++++++++++++++++++-- - 1 file changed, 33 insertions(+), 2 deletions(-) - -diff --git a/dlls/ntdll/tests/file.c b/dlls/ntdll/tests/file.c -index 1afb9c8..b8f1847 100644 ---- a/dlls/ntdll/tests/file.c -+++ b/dlls/ntdll/tests/file.c -@@ -177,6 +177,7 @@ static void create_file_test(void) - static const WCHAR pathInvalidNtW[] = {'\\','\\','?','\\',0}; - static const WCHAR pathInvalidNt2W[] = {'\\','?','?','\\',0}; - static const WCHAR pathInvalidDosW[] = {'\\','D','o','s','D','e','v','i','c','e','s','\\',0}; -+ static const char testdata[] = "Hello World"; - FILE_NETWORK_OPEN_INFORMATION info; - NTSTATUS status; - HANDLE dir, file; -@@ -184,6 +185,9 @@ static void create_file_test(void) - OBJECT_ATTRIBUTES attr; - IO_STATUS_BLOCK io; - UNICODE_STRING nameW; -+ LARGE_INTEGER offset; -+ char buf[32]; -+ DWORD ret; - - GetCurrentDirectoryW( MAX_PATH, path ); - pRtlDosPathNameToNtPathName_U( path, &nameW, NULL, NULL ); -@@ -195,9 +199,36 @@ static void create_file_test(void) - attr.SecurityQualityOfService = NULL; - - /* try various open modes and options on directories */ -- status = pNtCreateFile( &dir, GENERIC_READ, &attr, &io, NULL, 0, FILE_SHARE_READ|FILE_SHARE_WRITE, -- FILE_OPEN, FILE_DIRECTORY_FILE, NULL, 0 ); -+ status = pNtCreateFile( &dir, GENERIC_READ|GENERIC_WRITE, &attr, &io, NULL, 0, -+ FILE_SHARE_READ|FILE_SHARE_WRITE, FILE_OPEN, FILE_DIRECTORY_FILE, NULL, 0 ); - ok( !status, "open %s failed %x\n", wine_dbgstr_w(nameW.Buffer), status ); -+ -+ U(io).Status = 0xdeadbeef; -+ offset.QuadPart = 0; -+ status = pNtReadFile( dir, NULL, NULL, NULL, &io, buf, sizeof(buf), &offset, NULL ); -+ todo_wine -+ ok( status == STATUS_INVALID_DEVICE_REQUEST || status == STATUS_PENDING, "NtReadFile error %08x\n", status ); -+ if (status == STATUS_PENDING) -+ { -+ ret = WaitForSingleObject( dir, 1000 ); -+ ok( ret == WAIT_OBJECT_0, "WaitForSingleObject error %u\n", ret ); -+ ok( U(io).Status == STATUS_INVALID_DEVICE_REQUEST, -+ "expected STATUS_INVALID_DEVICE_REQUEST, got %08x\n", U(io).Status ); -+ } -+ -+ U(io).Status = 0xdeadbeef; -+ offset.QuadPart = 0; -+ status = pNtWriteFile( dir, NULL, NULL, NULL, &io, testdata, sizeof(testdata), &offset, NULL); -+ todo_wine -+ ok( status == STATUS_INVALID_DEVICE_REQUEST || status == STATUS_PENDING, "NtWriteFile error %08x\n", status ); -+ if (status == STATUS_PENDING) -+ { -+ ret = WaitForSingleObject( dir, 1000 ); -+ ok( ret == WAIT_OBJECT_0, "WaitForSingleObject error %u\n", ret ); -+ ok( U(io).Status == STATUS_INVALID_DEVICE_REQUEST, -+ "expected STATUS_INVALID_DEVICE_REQUEST, got %08x\n", U(io).Status ); -+ } -+ - CloseHandle( dir ); - - status = pNtCreateFile( &dir, GENERIC_READ, &attr, &io, NULL, 0, FILE_SHARE_READ|FILE_SHARE_WRITE, --- -2.6.0 - diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index 59acb331..0d3d3744 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -52,7 +52,7 @@ usage() # Get the upstream commit sha upstream_commit() { - echo "20ff3352eb19292d47eaa8f3aecc61523ac1f1d9" + echo "8dd86823fdd9a5e631cf3173727b6f667ef1b611" } # Show version information @@ -4238,10 +4238,8 @@ fi # | * dlls/ntdll/file.c, dlls/ntdll/tests/file.c # | if test "$enable_ntdll_Status_Mapping" -eq 1; then - patch_apply ntdll-Status_Mapping/0001-ntdll-tests-Add-tests-for-calling-NtReadFile-NtWrite.patch - patch_apply ntdll-Status_Mapping/0002-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch + patch_apply ntdll-Status_Mapping/0001-ntdll-Return-STATUS_INVALID_DEVICE_REQUEST-when-tryi.patch ( - echo '+ { "Sebastian Lackner", "ntdll/tests: Add tests for calling NtReadFile/NtWriteFile on directory.", 1 },'; echo '+ { "Sebastian Lackner", "ntdll: Return STATUS_INVALID_DEVICE_REQUEST when trying to call NtReadFile on directory.", 1 },'; ) >> "$patchlist" fi diff --git a/patches/wined3d-CSMT_Main/0014-wined3d-Move-invalidate_location-to-resource.c.patch b/patches/wined3d-CSMT_Main/0014-wined3d-Move-invalidate_location-to-resource.c.patch index 82931c59..261f875f 100644 --- a/patches/wined3d-CSMT_Main/0014-wined3d-Move-invalidate_location-to-resource.c.patch +++ b/patches/wined3d-CSMT_Main/0014-wined3d-Move-invalidate_location-to-resource.c.patch @@ -1,4 +1,4 @@ -From 025d8d22909fa65d7315f97042cc12efa5809657 Mon Sep 17 00:00:00 2001 +From ef5abde1da424f2e4879fedb4c631806c8495bca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Thu, 3 Oct 2013 12:36:46 +0200 Subject: wined3d: Move invalidate_location to resource.c. @@ -12,10 +12,10 @@ Subject: wined3d: Move invalidate_location to resource.c. 5 files changed, 17 insertions(+), 20 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c -index 99f4e96..bde37b1 100644 +index 955a19d..3499a26 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c -@@ -3487,7 +3487,7 @@ static HRESULT device_update_volume(struct wined3d_device *device, +@@ -3510,7 +3510,7 @@ static HRESULT device_update_volume(struct wined3d_device *device, data.buffer_object = 0; data.addr = src.data; wined3d_volume_upload_data(dst_volume, context, &data); @@ -25,10 +25,10 @@ index 99f4e96..bde37b1 100644 context_release(context); diff --git a/dlls/wined3d/resource.c b/dlls/wined3d/resource.c -index 2731f27..89865ef 100644 +index 5039d50..e54781f 100644 --- a/dlls/wined3d/resource.c +++ b/dlls/wined3d/resource.c -@@ -369,3 +369,10 @@ void wined3d_resource_validate_location(struct wined3d_resource *resource, DWORD +@@ -452,3 +452,10 @@ void wined3d_resource_validate_location(struct wined3d_resource *resource, DWORD resource->locations |= location; TRACE("new location flags are %s.\n", wined3d_debug_location(resource->locations)); } @@ -40,10 +40,10 @@ index 2731f27..89865ef 100644 + TRACE("new location flags are %s.\n", wined3d_debug_location(resource->locations)); +} diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c -index 6692118..522ffd6 100644 +index a1d0283..bd1bdd7 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c -@@ -1322,9 +1322,7 @@ static void texture3d_sub_resource_cleanup(struct wined3d_resource *sub_resource +@@ -1237,9 +1237,7 @@ static void texture3d_sub_resource_cleanup(struct wined3d_resource *sub_resource static void texture3d_sub_resource_invalidate_location(struct wined3d_resource *sub_resource, DWORD location) { @@ -55,7 +55,7 @@ index 6692118..522ffd6 100644 static void texture3d_sub_resource_validate_location(struct wined3d_resource *sub_resource, DWORD location) diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c -index e1fa454..722f92e 100644 +index ab6aa61..77aa7b1 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c @@ -99,13 +99,6 @@ void wined3d_volume_upload_data(struct wined3d_volume *volume, const struct wine @@ -90,7 +90,7 @@ index e1fa454..722f92e 100644 } else if (volume->resource.locations & WINED3D_LOCATION_SYSMEM) { -@@ -278,7 +271,7 @@ static void wined3d_volume_load_location(struct wined3d_volume *volume, +@@ -282,7 +275,7 @@ static void wined3d_volume_load_location(struct wined3d_volume *volume, if (volume->resource.locations & WINED3D_LOCATION_DISCARDED) { TRACE("Volume previously discarded, nothing to do.\n"); @@ -99,7 +99,7 @@ index e1fa454..722f92e 100644 } else if (volume->resource.locations & (WINED3D_LOCATION_TEXTURE_RGB | WINED3D_LOCATION_TEXTURE_SRGB)) { -@@ -308,7 +301,7 @@ static void wined3d_volume_load_location(struct wined3d_volume *volume, +@@ -312,7 +305,7 @@ static void wined3d_volume_load_location(struct wined3d_volume *volume, if (volume->resource.locations & WINED3D_LOCATION_DISCARDED) { TRACE("Volume previously discarded, nothing to do.\n"); @@ -108,7 +108,7 @@ index e1fa454..722f92e 100644 } else if (volume->resource.locations & (WINED3D_LOCATION_TEXTURE_RGB | WINED3D_LOCATION_TEXTURE_SRGB)) { -@@ -401,13 +394,13 @@ static void volume_unload(struct wined3d_resource *resource) +@@ -405,13 +398,13 @@ static void volume_unload(struct wined3d_resource *resource) context = context_acquire(device, NULL); wined3d_volume_load_location(volume, context, WINED3D_LOCATION_SYSMEM); context_release(context); @@ -124,7 +124,7 @@ index e1fa454..722f92e 100644 } if (volume->pbo) -@@ -641,7 +634,7 @@ HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, +@@ -634,7 +627,7 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, if (!(flags & (WINED3D_MAP_NO_DIRTY_UPDATE | WINED3D_MAP_READONLY))) { wined3d_texture_set_dirty(volume->container); @@ -134,10 +134,10 @@ index e1fa454..722f92e 100644 volume->resource.map_count++; diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 3e13ae8..fd82ec3 100644 +index 3ea15e4..c317b96 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -2126,6 +2126,7 @@ BOOL wined3d_resource_is_offscreen(struct wined3d_resource *resource) DECLSPEC_H +@@ -2207,6 +2207,7 @@ BOOL wined3d_resource_is_offscreen(struct wined3d_resource *resource) DECLSPEC_H 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; void wined3d_resource_validate_location(struct wined3d_resource *resource, DWORD location) DECLSPEC_HIDDEN; @@ -145,15 +145,17 @@ index 3e13ae8..fd82ec3 100644 /* Tests show that the start address of resources is 32 byte aligned */ #define RESOURCE_ALIGNMENT 16 -@@ -2269,8 +2270,6 @@ HRESULT wined3d_volume_create(struct wined3d_texture *container, const struct wi +@@ -2344,10 +2345,8 @@ HRESULT wined3d_volume_create(struct wined3d_texture *container, const struct wi void wined3d_volume_destroy(struct wined3d_volume *volume) DECLSPEC_HIDDEN; void wined3d_volume_load(struct wined3d_volume *volume, struct wined3d_context *context, BOOL srgb_mode) DECLSPEC_HIDDEN; -void wined3d_volume_invalidate_location(struct wined3d_volume *volume, DWORD location) DECLSPEC_HIDDEN; + HRESULT wined3d_volume_map(struct wined3d_volume *volume, + struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags) DECLSPEC_HIDDEN; -void wined3d_volume_validate_location(struct wined3d_volume *volume, DWORD location) DECLSPEC_HIDDEN; + HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) DECLSPEC_HIDDEN; void wined3d_volume_upload_data(struct wined3d_volume *volume, const struct wined3d_context *context, const struct wined3d_const_bo_address *data) DECLSPEC_HIDDEN; - -- -2.2.1 +2.6.0 diff --git a/patches/wined3d-CSMT_Main/0020-wined3d-Introduce-helper-functions-for-mapping-volum.patch b/patches/wined3d-CSMT_Main/0020-wined3d-Introduce-helper-functions-for-mapping-volum.patch index facd707b..8b9c52d5 100644 --- a/patches/wined3d-CSMT_Main/0020-wined3d-Introduce-helper-functions-for-mapping-volum.patch +++ b/patches/wined3d-CSMT_Main/0020-wined3d-Introduce-helper-functions-for-mapping-volum.patch @@ -1,4 +1,4 @@ -From e45dcebaee1ba3235293c0f84550effd5b445d94 Mon Sep 17 00:00:00 2001 +From 867205199c207d54cbbf54234f305c9b76c8671c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Wed, 18 Sep 2013 22:30:57 +0200 Subject: wined3d: Introduce helper functions for mapping volumes. @@ -8,7 +8,7 @@ Subject: wined3d: Introduce helper functions for mapping volumes. 1 file changed, 96 insertions(+), 61 deletions(-) diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c -index 5d32043..b86b227 100644 +index 42453ea..af3f055 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c @@ -468,12 +468,67 @@ static BOOL wined3d_volume_check_box_dimensions(const struct wined3d_volume *vol @@ -71,7 +71,7 @@ index 5d32043..b86b227 100644 + } +} + - HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, + HRESULT wined3d_volume_map(struct wined3d_volume *volume, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags) { struct wined3d_device *device = volume->resource.device; @@ -80,7 +80,7 @@ index 5d32043..b86b227 100644 BYTE *base_memory; const struct wined3d_format *format = volume->resource.format; const unsigned int fmt_flags = volume->container->resource.format_flags; -@@ -506,58 +561,22 @@ HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, +@@ -506,58 +561,22 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, flags = wined3d_resource_sanitize_map_flags(&volume->resource, flags); @@ -150,7 +150,7 @@ index 5d32043..b86b227 100644 TRACE("Base memory pointer %p.\n", base_memory); -@@ -610,8 +629,34 @@ HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, +@@ -610,8 +629,34 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, return WINED3D_OK; } @@ -178,14 +178,14 @@ index 5d32043..b86b227 100644 + } +} + - HRESULT CDECL wined3d_volume_unmap(struct wined3d_volume *volume) + HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) { + struct wined3d_device *device = volume->resource.device; + struct wined3d_context *context; TRACE("volume %p.\n", volume); if (!volume->resource.map_count) -@@ -620,19 +665,9 @@ HRESULT CDECL wined3d_volume_unmap(struct wined3d_volume *volume) +@@ -620,19 +665,9 @@ HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) return WINED3DERR_INVALIDCALL; } diff --git a/patches/wined3d-CSMT_Main/0021-wined3d-Move-volume-PBO-infrastructure-into-the-reso.patch b/patches/wined3d-CSMT_Main/0021-wined3d-Move-volume-PBO-infrastructure-into-the-reso.patch index 44b1de07..1a4aebd7 100644 --- a/patches/wined3d-CSMT_Main/0021-wined3d-Move-volume-PBO-infrastructure-into-the-reso.patch +++ b/patches/wined3d-CSMT_Main/0021-wined3d-Move-volume-PBO-infrastructure-into-the-reso.patch @@ -1,4 +1,4 @@ -From 512672b57e21aab944955cf738f8285d91369604 Mon Sep 17 00:00:00 2001 +From 5b00654bc918a13d1c702d102de41bdaaf0dc360 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Thu, 16 Jan 2014 22:07:17 +0100 Subject: wined3d: Move volume PBO infrastructure into the resource. @@ -89,7 +89,7 @@ index 39df397..5f0a98e 100644 + } +} diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c -index b86b227..d196b0e 100644 +index af3f055..084e0e6 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c @@ -218,7 +218,7 @@ static void wined3d_volume_load_location(struct wined3d_resource *resource, @@ -215,10 +215,10 @@ index b86b227..d196b0e 100644 - } -} - - HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, + HRESULT wined3d_volume_map(struct wined3d_volume *volume, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags) { -@@ -575,7 +537,7 @@ HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, +@@ -575,7 +537,7 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, else wined3d_resource_load_location(&volume->resource, context, volume->resource.map_binding); @@ -227,7 +227,7 @@ index b86b227..d196b0e 100644 context_release(context); TRACE("Base memory pointer %p.\n", base_memory); -@@ -629,30 +591,6 @@ HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, +@@ -629,30 +591,6 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, return WINED3D_OK; } @@ -255,10 +255,10 @@ index b86b227..d196b0e 100644 - } -} - - HRESULT CDECL wined3d_volume_unmap(struct wined3d_volume *volume) + HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) { struct wined3d_device *device = volume->resource.device; -@@ -666,7 +604,7 @@ HRESULT CDECL wined3d_volume_unmap(struct wined3d_volume *volume) +@@ -666,7 +604,7 @@ HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) } context = context_acquire(device, NULL); @@ -268,7 +268,7 @@ index b86b227..d196b0e 100644 volume->resource.map_count--; diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index eeed387..efd865b 100644 +index 394ea0e..2a113e0 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -2174,6 +2174,7 @@ struct wined3d_resource diff --git a/patches/wined3d-CSMT_Main/0024-wined3d-Move-buffer-creation-into-the-resource.patch b/patches/wined3d-CSMT_Main/0024-wined3d-Move-buffer-creation-into-the-resource.patch index 58b3d897..e70c071f 100644 --- a/patches/wined3d-CSMT_Main/0024-wined3d-Move-buffer-creation-into-the-resource.patch +++ b/patches/wined3d-CSMT_Main/0024-wined3d-Move-buffer-creation-into-the-resource.patch @@ -1,4 +1,4 @@ -From 2bec3781b41cc3f0b809a5cd8782b11f93fcc6d3 Mon Sep 17 00:00:00 2001 +From e6f030ca36c31b52f7dce040eb03552a2a73b2e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Wed, 18 Sep 2013 22:49:34 +0200 Subject: wined3d: Move buffer creation into the resource. @@ -15,7 +15,7 @@ surface_load_location will write a lot of ERRs. 4 files changed, 72 insertions(+), 63 deletions(-) diff --git a/dlls/wined3d/resource.c b/dlls/wined3d/resource.c -index 40cbbb2..5ad3201 100644 +index dda77f0..e20f353 100644 --- a/dlls/wined3d/resource.c +++ b/dlls/wined3d/resource.c @@ -223,6 +223,18 @@ HRESULT resource_init(struct wined3d_resource *resource, struct wined3d_device * @@ -110,10 +110,10 @@ index 40cbbb2..5ad3201 100644 + } +} diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c -index a6fc6ba..d5d00e7 100644 +index 0241309..abd2d8a 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c -@@ -1276,7 +1276,7 @@ static void texture3d_prepare_texture(struct wined3d_texture *texture, struct wi +@@ -1289,7 +1289,7 @@ static void texture3d_prepare_texture(struct wined3d_texture *texture, struct wi void *mem = NULL; if (gl_info->supported[APPLE_CLIENT_STORAGE] && !format->convert @@ -123,7 +123,7 @@ index a6fc6ba..d5d00e7 100644 TRACE("Enabling GL_UNPACK_CLIENT_STORAGE_APPLE for volume %p\n", volume); gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE); diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c -index ea54b97..ecdaa40 100644 +index 084e0e6..d823ebd 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c @@ -316,42 +316,10 @@ void wined3d_volume_load(struct wined3d_volume *volume, struct wined3d_context * @@ -194,7 +194,7 @@ index ea54b97..ecdaa40 100644 /* The texture name is managed by the container. */ volume->flags &= ~WINED3D_VFLAG_CLIENT_STORAGE; -@@ -480,24 +439,6 @@ static BOOL wined3d_volume_check_box_dimensions(const struct wined3d_volume *vol +@@ -468,24 +427,6 @@ static BOOL wined3d_volume_check_box_dimensions(const struct wined3d_volume *vol return TRUE; } @@ -216,10 +216,10 @@ index ea54b97..ecdaa40 100644 - } -} - - HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, + HRESULT wined3d_volume_map(struct wined3d_volume *volume, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags) { -@@ -536,7 +477,7 @@ HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, +@@ -524,7 +465,7 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, flags = wined3d_resource_sanitize_map_flags(&volume->resource, flags); context = context_acquire(device, NULL); @@ -229,10 +229,10 @@ index ea54b97..ecdaa40 100644 WARN("Out of memory.\n"); map_desc->data = NULL; diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 523b98f..d005e61 100644 +index 828f9a7..67c1de2 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -2207,6 +2207,9 @@ void wined3d_resource_invalidate_location(struct wined3d_resource *resource, DWO +@@ -2213,6 +2213,9 @@ void wined3d_resource_invalidate_location(struct wined3d_resource *resource, DWO BOOL wined3d_resource_is_offscreen(struct wined3d_resource *resource) DECLSPEC_HIDDEN; void wined3d_resource_load_location(struct wined3d_resource *resource, struct wined3d_context *context, DWORD location) DECLSPEC_HIDDEN; @@ -242,7 +242,7 @@ index 523b98f..d005e61 100644 void wined3d_resource_release_map_ptr(const struct wined3d_resource *resource, const struct wined3d_context *context) DECLSPEC_HIDDEN; DWORD wined3d_resource_sanitize_map_flags(const struct wined3d_resource *resource, DWORD flags) DECLSPEC_HIDDEN; -@@ -2339,7 +2342,6 @@ static inline struct wined3d_volume *volume_from_resource(struct wined3d_resourc +@@ -2348,7 +2351,6 @@ static inline struct wined3d_volume *volume_from_resource(struct wined3d_resourc return CONTAINING_RECORD(resource, struct wined3d_volume, resource); } @@ -251,5 +251,5 @@ index 523b98f..d005e61 100644 unsigned int level, struct wined3d_volume **volume) DECLSPEC_HIDDEN; void wined3d_volume_destroy(struct wined3d_volume *volume) DECLSPEC_HIDDEN; -- -2.5.1 +2.6.0 diff --git a/patches/wined3d-CSMT_Main/0039-wined3d-Move-most-of-volume_map-to-resource.c.patch b/patches/wined3d-CSMT_Main/0039-wined3d-Move-most-of-volume_map-to-resource.c.patch index 85a96254..c28a5dab 100644 --- a/patches/wined3d-CSMT_Main/0039-wined3d-Move-most-of-volume_map-to-resource.c.patch +++ b/patches/wined3d-CSMT_Main/0039-wined3d-Move-most-of-volume_map-to-resource.c.patch @@ -1,4 +1,4 @@ -From 2faccff39a75dfddd6aa22f3211d6ca12a4b3555 Mon Sep 17 00:00:00 2001 +From fe66d6b8129533d88849527339ca52a19e343509 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Thu, 19 Sep 2013 17:51:38 +0200 Subject: wined3d: Move most of volume_map to resource.c @@ -136,11 +136,11 @@ index 2e06f21..e5af445 100644 + return WINED3D_OK; +} diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c -index 0827c74..0a1df4b 100644 +index 38fe516..08dbecb 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c @@ -392,26 +392,16 @@ static BOOL wined3d_volume_check_box_dimensions(const struct wined3d_volume *vol - HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, + HRESULT wined3d_volume_map(struct wined3d_volume *volume, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags) { - struct wined3d_device *device = volume->resource.device; @@ -167,7 +167,7 @@ index 0827c74..0a1df4b 100644 if (!wined3d_volume_check_box_dimensions(volume, box)) { WARN("Map box is invalid.\n"); -@@ -424,95 +414,16 @@ HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, +@@ -424,95 +414,16 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, return WINED3DERR_INVALIDCALL; } @@ -245,7 +245,7 @@ index 0827c74..0a1df4b 100644 + return hr; } - HRESULT CDECL wined3d_volume_unmap(struct wined3d_volume *volume) + HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) { - struct wined3d_device *device = volume->resource.device; - struct wined3d_context *context; @@ -269,7 +269,7 @@ index 0827c74..0a1df4b 100644 static ULONG volume_resource_incref(struct wined3d_resource *resource) diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 91e6db8..c230cb5 100644 +index 949b27b..ac6cd4e 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -2218,12 +2218,15 @@ void wined3d_resource_invalidate_location(struct wined3d_resource *resource, DWO diff --git a/patches/wined3d-CSMT_Main/0040-wined3d-Use-resource_map-for-surface_map.patch b/patches/wined3d-CSMT_Main/0040-wined3d-Use-resource_map-for-surface_map.patch index 870245e8..78951753 100644 --- a/patches/wined3d-CSMT_Main/0040-wined3d-Use-resource_map-for-surface_map.patch +++ b/patches/wined3d-CSMT_Main/0040-wined3d-Use-resource_map-for-surface_map.patch @@ -1,4 +1,4 @@ -From 3e4b3bec2fbb475be058afeb846adebf3af1d575 Mon Sep 17 00:00:00 2001 +From f37230817cf62ee3f7e6d805107bcf1f455d0d9a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Thu, 19 Sep 2013 18:00:23 +0200 Subject: wined3d: Use resource_map for surface_map. @@ -171,12 +171,12 @@ index 37f9b40..1d77682 100644 HRESULT CDECL wined3d_surface_getdc(struct wined3d_surface *surface, HDC *dc) diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c -index 966ff6c..1d98275 100644 +index 85894d1..43c9092 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c -@@ -428,7 +428,12 @@ struct wined3d_volume * CDECL wined3d_volume_from_resource(struct wined3d_resour +@@ -423,7 +423,12 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, - HRESULT CDECL wined3d_volume_unmap(struct wined3d_volume *volume) + HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) { - return wined3d_resource_unmap(&volume->resource); + HRESULT hr; diff --git a/patches/wined3d-CSMT_Main/0137-wined3d-Clean-up-volume-resource-data-through-the-CS.patch b/patches/wined3d-CSMT_Main/0137-wined3d-Clean-up-volume-resource-data-through-the-CS.patch index 1b35f06c..98dd7b75 100644 --- a/patches/wined3d-CSMT_Main/0137-wined3d-Clean-up-volume-resource-data-through-the-CS.patch +++ b/patches/wined3d-CSMT_Main/0137-wined3d-Clean-up-volume-resource-data-through-the-CS.patch @@ -1,4 +1,4 @@ -From e092a5748fac188f5b214467cdb33b4df9a7163c Mon Sep 17 00:00:00 2001 +From 59e33f230ca7b23bd372522e155377b2b66ec66e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Wed, 2 Oct 2013 22:54:57 +0200 Subject: wined3d: Clean up volume resource data through the CS. @@ -70,7 +70,7 @@ index 54b6d1a..18b556d 100644 static inline void *_wined3d_cs_mt_require_space(struct wined3d_cs *cs, size_t size, BOOL prio) diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c -index 7913a13..36dd640 100644 +index cb91d28..088762b 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c @@ -313,10 +313,8 @@ void wined3d_volume_destroy(struct wined3d_volume *volume) @@ -98,18 +98,18 @@ index 7913a13..36dd640 100644 { TRACE("Forwarding to container %p.\n", volume->container); diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 0933ae6..088bf72 100644 +index f4cc159..04a403a 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -2423,6 +2423,7 @@ void wined3d_volume_load(struct wined3d_volume *volume, struct wined3d_context * - BOOL srgb_mode) DECLSPEC_HIDDEN; +@@ -2435,6 +2435,7 @@ HRESULT wined3d_volume_map(struct wined3d_volume *volume, + HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) DECLSPEC_HIDDEN; void wined3d_volume_upload_data(struct wined3d_volume *volume, const struct wined3d_context *context, const struct wined3d_const_bo_address *data) DECLSPEC_HIDDEN; +void wined3d_volume_cleanup_cs(struct wined3d_volume *volume) DECLSPEC_HIDDEN; struct wined3d_surface_dib { -@@ -2797,6 +2798,7 @@ void wined3d_cs_emit_create_vbo(struct wined3d_cs *cs, struct wined3d_buffer *bu +@@ -2809,6 +2810,7 @@ void wined3d_cs_emit_create_vbo(struct wined3d_cs *cs, struct wined3d_buffer *bu void wined3d_cs_emit_resource_cleanup(struct wined3d_cs *cs, struct wined3d_resource *resource) DECLSPEC_HIDDEN; void wined3d_cs_emit_buffer_cleanup(struct wined3d_cs *cs, struct wined3d_buffer *buffer) DECLSPEC_HIDDEN; @@ -118,5 +118,5 @@ index 0933ae6..088bf72 100644 /* 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 -- -2.5.1 +2.6.0 diff --git a/patches/wined3d-CSMT_Main/9999-IfDefined.patch b/patches/wined3d-CSMT_Main/9999-IfDefined.patch index 4e2a01cd..bf132cc4 100644 --- a/patches/wined3d-CSMT_Main/9999-IfDefined.patch +++ b/patches/wined3d-CSMT_Main/9999-IfDefined.patch @@ -869,7 +869,7 @@ diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c const struct wined3d_box *box) { @@ -399,6 +673,7 @@ - HRESULT CDECL wined3d_volume_map(struct wined3d_volume *volume, + HRESULT wined3d_volume_map(struct wined3d_volume *volume, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags) { +#if defined(STAGING_CSMT) @@ -1023,7 +1023,7 @@ diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c + return WINED3D_OK; +} + -+HRESULT CDECL wined3d_volume_unmap(struct wined3d_volume *volume) ++HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) +{ + TRACE("volume %p.\n", volume); + @@ -2032,7 +2032,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h HRESULT wined3d_volume_create(struct wined3d_texture *container, const struct wined3d_resource_desc *desc, unsigned int level, struct wined3d_volume **volume) DECLSPEC_HIDDEN; void wined3d_volume_destroy(struct wined3d_volume *volume) DECLSPEC_HIDDEN; -@@ -2439,6 +2552,24 @@ +@@ -2442,6 +2555,27 @@ struct wined3d_surface_dib { HBITMAP DIBsection; @@ -2045,7 +2045,10 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h +void wined3d_volume_load(struct wined3d_volume *volume, struct wined3d_context *context, + BOOL srgb_mode) DECLSPEC_HIDDEN; +void wined3d_volume_invalidate_location(struct wined3d_volume *volume, DWORD location) DECLSPEC_HIDDEN; ++HRESULT wined3d_volume_map(struct wined3d_volume *volume, ++ struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags) DECLSPEC_HIDDEN; +void wined3d_volume_validate_location(struct wined3d_volume *volume, DWORD location) DECLSPEC_HIDDEN; ++HRESULT wined3d_volume_unmap(struct wined3d_volume *volume) DECLSPEC_HIDDEN; +void wined3d_volume_upload_data(struct wined3d_volume *volume, const struct wined3d_context *context, + const struct wined3d_const_bo_address *data) DECLSPEC_HIDDEN; + @@ -2057,7 +2060,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h UINT bitmap_size; }; -@@ -2464,7 +2595,11 @@ +@@ -2467,7 +2601,11 @@ struct wined3d_surface_ops { HRESULT (*surface_private_setup)(struct wined3d_surface *surface); @@ -2069,7 +2072,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h }; struct wined3d_surface -@@ -2472,12 +2607,26 @@ +@@ -2475,12 +2613,26 @@ struct wined3d_resource resource; const struct wined3d_surface_ops *surface_ops; struct wined3d_texture *container; @@ -2096,7 +2099,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h GLuint rb_multisample; GLuint rb_resolved; GLenum texture_target; -@@ -2521,10 +2670,19 @@ +@@ -2524,10 +2676,19 @@ GLenum surface_get_gl_buffer(const struct wined3d_surface *surface) DECLSPEC_HIDDEN; void surface_get_drawable_size(const struct wined3d_surface *surface, const struct wined3d_context *context, unsigned int *width, unsigned int *height) DECLSPEC_HIDDEN; @@ -2116,7 +2119,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void surface_modify_ds_location(struct wined3d_surface *surface, DWORD location, UINT w, UINT h) DECLSPEC_HIDDEN; void surface_prepare_rb(struct wined3d_surface *surface, const struct wined3d_gl_info *gl_info, BOOL multisample) DECLSPEC_HIDDEN; -@@ -2536,6 +2694,7 @@ +@@ -2539,6 +2700,7 @@ const struct wined3d_gl_info *gl_info, void *mem, unsigned int pitch) DECLSPEC_HIDDEN; HRESULT surface_upload_from_surface(struct wined3d_surface *dst_surface, const POINT *dst_point, struct wined3d_surface *src_surface, const RECT *src_rect) DECLSPEC_HIDDEN; @@ -2124,7 +2127,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h HRESULT wined3d_surface_create(struct wined3d_texture *container, const struct wined3d_resource_desc *desc, GLenum target, unsigned int level, unsigned int layer, DWORD flags, struct wined3d_surface **surface) DECLSPEC_HIDDEN; -@@ -2550,6 +2709,17 @@ +@@ -2553,6 +2715,17 @@ void wined3d_surface_cleanup_cs(struct wined3d_surface *surface) DECLSPEC_HIDDEN; void wined3d_surface_getdc_cs(struct wined3d_surface *surface) DECLSPEC_HIDDEN; void wined3d_surface_releasedc_cs(struct wined3d_surface *surface) DECLSPEC_HIDDEN; @@ -2142,7 +2145,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; -@@ -2572,8 +2742,10 @@ +@@ -2575,8 +2748,10 @@ GLuint name; }; @@ -2153,7 +2156,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; -@@ -2602,8 +2774,10 @@ +@@ -2605,8 +2780,10 @@ BOOL half_float_conv_needed; }; @@ -2164,7 +2167,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_saved_states { DWORD transform[(HIGHEST_TRANSFORMSTATE >> 5) + 1]; -@@ -2671,6 +2845,7 @@ +@@ -2674,6 +2851,7 @@ void stateblock_init_contained_states(struct wined3d_stateblock *stateblock) DECLSPEC_HIDDEN; void state_cleanup(struct wined3d_state *state) DECLSPEC_HIDDEN; @@ -2172,7 +2175,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; -@@ -2721,6 +2896,32 @@ +@@ -2724,6 +2902,32 @@ 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; @@ -2205,7 +2208,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; -@@ -2770,6 +2971,7 @@ +@@ -2773,6 +2977,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; @@ -2213,7 +2216,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, UINT start_register, const float *constants, UINT vector4f_count, enum wined3d_shader_type type) DECLSPEC_HIDDEN; void wined3d_cs_emit_set_consts_b(struct wined3d_cs *cs, UINT start_register, -@@ -2833,6 +3035,7 @@ +@@ -2836,6 +3041,7 @@ void wined3d_cs_emit_update_sub_resource(struct wined3d_cs *cs, struct wined3d_resource *resource, unsigned int sub_resource_idx, const struct wined3d_box *box, const void *data, unsigned int row_pitch, unsigned int depth_pitch) DECLSPEC_HIDDEN; @@ -2221,7 +2224,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 -@@ -2847,8 +3050,12 @@ +@@ -2850,8 +3056,12 @@ struct wined3d_query_ops { HRESULT (*query_get_data)(struct wined3d_query *query, void *data, DWORD data_size, DWORD flags); @@ -2234,7 +2237,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h }; struct wined3d_query -@@ -2862,12 +3069,16 @@ +@@ -2865,12 +3075,16 @@ enum wined3d_query_type type; DWORD data_size; void *extendedData; @@ -2251,7 +2254,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 */ -@@ -2894,7 +3105,9 @@ +@@ -2897,7 +3111,9 @@ GLenum buffer_object_usage; GLenum buffer_type_hint; DWORD flags; @@ -2261,7 +2264,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h void *map_ptr; struct wined3d_map_range *maps; -@@ -2919,11 +3132,15 @@ +@@ -2922,11 +3138,15 @@ BYTE *buffer_get_sysmem(struct wined3d_buffer *This, 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; @@ -2277,7 +2280,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_rendertarget_view { -@@ -2962,8 +3179,10 @@ +@@ -2965,8 +3185,10 @@ return surface_from_resource(resource); } @@ -2288,7 +2291,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h struct wined3d_shader_resource_view { LONG refcount; -@@ -2976,8 +3195,12 @@ +@@ -2979,8 +3201,12 @@ struct wined3d_swapchain_ops { void (*swapchain_present)(struct wined3d_swapchain *swapchain, const RECT *src_rect, @@ -2301,7 +2304,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h }; struct wined3d_swapchain -@@ -3016,8 +3239,10 @@ +@@ -3019,8 +3245,10 @@ void swapchain_destroy_contexts(struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN; HDC swapchain_get_backup_dc(struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN; void swapchain_update_draw_bindings(struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN; @@ -2312,7 +2315,7 @@ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h /***************************************************************************** * Utility function prototypes -@@ -3221,7 +3446,9 @@ +@@ -3224,7 +3452,9 @@ void shader_generate_main(const struct wined3d_shader *shader, struct wined3d_string_buffer *buffer, const struct wined3d_shader_reg_maps *reg_maps, const DWORD *byte_code, void *backend_ctx) DECLSPEC_HIDDEN; BOOL shader_match_semantic(const char *semantic_name, enum wined3d_decl_usage usage) DECLSPEC_HIDDEN; diff --git a/patches/wined3d-DXTn/0002-wined3d-Improve-DXTn-support-and-export-conversion-f.patch b/patches/wined3d-DXTn/0002-wined3d-Improve-DXTn-support-and-export-conversion-f.patch index 6850d792..8337acfc 100644 --- a/patches/wined3d-DXTn/0002-wined3d-Improve-DXTn-support-and-export-conversion-f.patch +++ b/patches/wined3d-DXTn/0002-wined3d-Improve-DXTn-support-and-export-conversion-f.patch @@ -1,4 +1,4 @@ -From 5a9fbe80d7b3c6c5c9b6395f730c9ff6b08b0d57 Mon Sep 17 00:00:00 2001 +From 19f7f6dca9ea99ec2bef50ff38f57d23d7a8691a Mon Sep 17 00:00:00 2001 From: Christian Costa Date: Tue, 4 Nov 2014 22:41:45 +0100 Subject: wined3d: Improve DXTn support and export conversion functions for @@ -153,10 +153,10 @@ index ce98949..77f7d55 100644 #undef LOAD_FUNCPTR diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c -index 603a6194..3530414 100644 +index 140b411..0a9f68d 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c -@@ -2303,6 +2303,30 @@ static void convert_dxt1_x8r8g8b8(const BYTE *src, BYTE *dst, +@@ -2310,6 +2310,30 @@ static void convert_dxt1_x8r8g8b8(const BYTE *src, BYTE *dst, wined3d_dxt1_decode(src, dst, pitch_in, pitch_out, WINED3DFMT_B8G8R8X8_UNORM, w, h); } @@ -187,7 +187,7 @@ index 603a6194..3530414 100644 static void convert_a8r8g8b8_dxt1(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h) { -@@ -2369,8 +2393,15 @@ static const struct d3dfmt_converter_desc converters[] = +@@ -2376,8 +2400,15 @@ static const struct d3dfmt_converter_desc converters[] = static const struct d3dfmt_converter_desc dxtn_converters[] = { @@ -204,13 +204,13 @@ index 603a6194..3530414 100644 {WINED3DFMT_B8G8R8X8_UNORM, WINED3DFMT_DXT1, convert_x8r8g8b8_dxt1}, {WINED3DFMT_B5G5R5A1_UNORM, WINED3DFMT_DXT1, convert_a1r5g5b5_dxt1}, diff --git a/dlls/wined3d/wined3d.spec b/dlls/wined3d/wined3d.spec -index 9531dd3..845d36b 100644 +index 0efa91c..5b8b153 100644 --- a/dlls/wined3d/wined3d.spec +++ b/dlls/wined3d/wined3d.spec -@@ -285,3 +285,11 @@ +@@ -284,3 +284,11 @@ + @ cdecl wined3d_vertex_declaration_incref(ptr) + @ cdecl wined3d_volume_get_resource(ptr) - @ cdecl wined3d_volume_map(ptr ptr ptr long) - @ cdecl wined3d_volume_unmap(ptr) + +@ cdecl wined3d_dxtn_supported() +@ cdecl wined3d_dxt1_decode(ptr ptr long long long long long) @@ -220,10 +220,10 @@ index 9531dd3..845d36b 100644 +@ cdecl wined3d_dxt5_decode(ptr ptr long long long long long) +@ cdecl wined3d_dxt5_encode(ptr ptr long long long long long) diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h -index 01ea83c..e561137 100644 +index f6dd1a2..182e4d6 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h -@@ -3251,17 +3251,7 @@ static inline void context_apply_state(struct wined3d_context *context, +@@ -3263,17 +3263,7 @@ static inline void context_apply_state(struct wined3d_context *context, state_table[rep].apply(context, state, rep); } @@ -242,7 +242,7 @@ index 01ea83c..e561137 100644 /* The WNDCLASS-Name for the fake window which we use to retrieve the GL capabilities */ diff --git a/include/wine/wined3d.h b/include/wine/wined3d.h -index ac1e59e..4878b06 100644 +index 7422545..cb85da4 100644 --- a/include/wine/wined3d.h +++ b/include/wine/wined3d.h @@ -2601,4 +2601,18 @@ static inline unsigned int wined3d_log2i(unsigned int x) @@ -265,5 +265,5 @@ index ac1e59e..4878b06 100644 + #endif /* __WINE_WINED3D_H */ -- -2.5.1 +2.6.0