Compare commits

..

45 Commits

Author SHA1 Message Date
Alistair Leslie-Hughes
5f19a81589 Release v6.17 2021-09-11 08:54:34 +10:00
Alistair Leslie-Hughes
1033d3990b Rebase against a8583acae9548e6340d8400ec7710136cd061ab2. 2021-09-11 08:22:10 +10:00
Alistair Leslie-Hughes
a896148be0 Rebase against 0b7f8373e3593ca8e5261d4486f1d04092a15653. 2021-09-10 08:12:17 +10:00
Zebediah Figura
ef11bb63ce Rebase against 63737942a06183f6b2e7fa8f95a07c918c9bf29b. 2021-09-07 21:47:35 -05:00
Alistair Leslie-Hughes
f3b03ce5a1 Rebase against 8b9f1e12841298591387e2b7590191610a37986e. 2021-09-04 08:24:36 +10:00
Paul Gofman
4b48df5032 Updated wined3d-zero-inf-shaders patchset.
Fix by Matteo Bruni <mbruni@codeweavers.com>.
2021-08-31 22:57:55 +03:00
Zebediah Figura
24319dc308 Rebase against 21c4a25437969696cbf5ffecee191ba8302bb2dd. 2021-08-30 22:26:36 -05:00
Alistair Leslie-Hughes
931daeffec Release v6.16 2021-08-28 09:33:12 +10:00
Alistair Leslie-Hughes
d923cf9418 Rebase against 8e2df64cf8979334618a3e2672d19cb9b891fa3f. 2021-08-28 09:23:30 +10:00
Paul Gofman
66c0fdc159 Update and reenable ntdll-Syscall_Emulation patchset. 2021-08-27 14:05:49 +03:00
Alistair Leslie-Hughes
6f3825b11f Rebase against 07ecdf6ce27590edbcf4c6787abef28c1ccc2768. 2021-08-27 09:26:57 +10:00
Alistair Leslie-Hughes
8d34769ef1 Rebase against 4a18232e455d82c9334c71ebea833dfb5b50b19e. 2021-08-26 08:55:28 +10:00
Alistair Leslie-Hughes
5a5c5a5743 Rebase against a87bafc5b92c9f2deaa399e32a8ec42d28f7ea45. 2021-08-25 09:53:24 +10:00
Alistair Leslie-Hughes
5c01355ada Added d3dx11_43-D3DX11CreateTextureFromMemory patchset 2021-08-24 08:47:18 +10:00
Alistair Leslie-Hughes
270f893aea Rebase against f33bf35d9a395a17e83b4bf512c5434368a8218e. 2021-08-24 08:01:24 +10:00
Zebediah Figura
dc0aa10ad7 Rebase against 17ba916c564236c9940ad736ff15a87fc5d1b12f. 2021-08-19 16:41:22 -05:00
Alistair Leslie-Hughes
d7b8304e38 Rebase against 60a3e0106246cb91d598a815d4fadf2791011142. 2021-08-18 08:34:28 +10:00
Zebediah Figura
b09fe464be server-default_integrity: Use "path" instead of ImagePathName to read the manifest.
Also, while we're at it, don't depend on the path being null-terminated.
2021-08-14 17:35:45 -05:00
Alistair Leslie-Hughes
4b6879f30f Release v6.15 2021-08-14 17:18:31 +10:00
Alistair Leslie-Hughes
94337e021c Rebase against 7f144646ffac6f3632d0c39b217dbd433c1154a0. 2021-08-14 15:52:01 +10:00
Alistair Leslie-Hughes
05c42b1df2 Rebase against 6b58d34a625ffaad181a7316009398f3c6444181. 2021-08-13 08:52:12 +10:00
Zebediah Figura
1bc4da9d59 Rebase against 91494ae6f2e47254d15a47e292ff569f3b400be6. 2021-08-11 22:25:44 -05:00
Alistair Leslie-Hughes
16476ce303 Updated mfplat-streaming-support patchset
Added a patch again to disable Function MFCreateDXGIDeviceManager.

This causes videos to render as a black screen.
Until support for the internal rendering flag SOURCE_READER_HAS_DEVICE_MANAGER is
better support through mf*, this patch will be here to stay.

Games affected.
Power Ranger: Battle for the Grid (Steam).
Oddworld: Soulstorm (Epic).
2021-08-11 09:37:19 +10:00
Alistair Leslie-Hughes
bdb9f49c3e Rebase against f63ecaedc72f3580e7016ba71a480025e4d86e99. 2021-08-11 09:04:37 +10:00
Alistair Leslie-Hughes
82118b0d67 Rebase against 3f2850aeaa159270384764843cdb1dc3cbe902c6. 2021-08-06 09:55:38 +10:00
Alistair Leslie-Hughes
00985bf311 Removed patchset ntdll-aarch-TEB
As request on bug.
2021-08-04 09:53:18 +10:00
Alistair Leslie-Hughes
3c8c7910e7 Rebase against ccbb0eef7bcaae672e9f7f69d3a9cdce62574177. 2021-08-04 09:18:47 +10:00
Alistair Leslie-Hughes
069adfd1b0 Release v6.14 2021-07-31 12:05:20 +10:00
Zebediah Figura
c91c63a5da ntdll-Junction_Points: Updates from Erich E. Hoover.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=50770
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51438
2021-07-30 18:44:16 -05:00
Alistair Leslie-Hughes
f7c80250ec Rebase against 10fb33026f2a55209dea0fb00caa279610027a0f. 2021-07-30 09:10:58 +10:00
Alistair Leslie-Hughes
b059114710 Updated nvcuda-CUDA_Support patchset 2021-07-29 09:46:04 +10:00
Alistair Leslie-Hughes
f27610e7e7 Rebase against 5dffe2263de41e76100ba0acd7c717267dc4c878. 2021-07-29 09:00:26 +10:00
Alistair Leslie-Hughes
9da0fe04d3 Rebase against 04d52eb83fa5c37cfe1100f435e36c2f78918338. 2021-07-28 08:40:53 +10:00
Alistair Leslie-Hughes
dc38777093 Rebase against a5f787ac445a682ea7ced5dd78c3516d4b8b9311. 2021-07-24 10:32:46 +10:00
Alistair Leslie-Hughes
b57bf86ec0 Updated mfplat-streaming-support patchset 2021-07-23 12:30:40 +10:00
Zebediah Figura
4e99d1b2a8 Rebase against c518a5362b925379b1a79e8323d60e19863effc1. 2021-07-22 17:41:21 -05:00
Alistair Leslie-Hughes
8ad669e434 Rebase against 384fc71a480b48443a6a899cbf3470dbf4fe2214. 2021-07-22 09:17:36 +10:00
Alistair Leslie-Hughes
52dd338148 Release v6.13 2021-07-21 09:59:17 +10:00
Alistair Leslie-Hughes
f841424edd Rebase against feb088b2247e1722b848ac0d67483596d33758ba. 2021-07-21 08:53:44 +10:00
Alistair Leslie-Hughes
5e8fbbf200 Rebase against d60c450c7be196c2072f74e34f7760d39e3bad32. 2021-07-20 11:27:20 +10:00
Alistair Leslie-Hughes
183fd3e089 Updated winepulse-PulseAudio_Support patchset 2021-07-18 11:55:05 +10:00
Alistair Leslie-Hughes
092f3b1ed1 Rebase against 49cde0995827b24aa9c1ef1b6a0372797f4166e0. 2021-07-10 17:14:03 +10:00
Alistair Leslie-Hughes
e59eb7639a Rebase against 6763ed84cf0629dd7d1495263e1e3ea9aaf3d663. 2021-07-08 11:16:34 +10:00
Alistair Leslie-Hughes
a0716c9cfe Rebase against adffa11609093c3c21cf43970bbecda1b2c43eb1. 2021-07-07 12:21:45 +10:00
Alistair Leslie-Hughes
fcf7b80107 Rebase against 14f03e84d46dbd94ae2e3711687420f816dc784f. 2021-07-06 09:05:43 +10:00
153 changed files with 2139 additions and 2143 deletions

View File

@@ -1,15 +1,15 @@
From e51b05c3a9d03e4dd84a107a30841d95f8a519c3 Mon Sep 17 00:00:00 2001
From 916189d1cdf149f16867870121171e20f129da9f Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Thu, 2 Oct 2014 19:44:31 +0200
Subject: [PATCH] ntdll: Print a warning message specifying the wine-staging
branch name and version.
---
dlls/ntdll/loader.c | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
dlls/ntdll/loader.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c
index ee453700e51..c2d4b3c2f86 100644
index 3339596944a..1d435f88755 100644
--- a/dlls/ntdll/loader.c
+++ b/dlls/ntdll/loader.c
@@ -44,6 +44,7 @@ WINE_DECLARE_DEBUG_CHANNEL(relay);
@@ -20,7 +20,7 @@ index ee453700e51..c2d4b3c2f86 100644
#ifdef _WIN64
#define DEFAULT_SECURITY_COOKIE_64 (((ULONGLONG)0x00002b99 << 32) | 0x2ddfa232)
@@ -3307,6 +3308,7 @@ void WINAPI LdrShutdownProcess(void)
@@ -3373,6 +3374,7 @@ void WINAPI LdrShutdownProcess(void)
process_detach();
}
@@ -28,7 +28,7 @@ index ee453700e51..c2d4b3c2f86 100644
/******************************************************************
* RtlExitUserProcess (NTDLL.@)
@@ -3673,6 +3675,9 @@ static void init_wow64(void)
@@ -3783,6 +3785,9 @@ static void init_wow64( CONTEXT *context )
*/
void WINAPI LdrInitializeThunk( CONTEXT *context, ULONG_PTR unknown2, ULONG_PTR unknown3, ULONG_PTR unknown4 )
{
@@ -38,9 +38,9 @@ index ee453700e51..c2d4b3c2f86 100644
static int attach_done;
int i;
NTSTATUS status;
@@ -3753,6 +3758,17 @@ void WINAPI LdrInitializeThunk( CONTEXT *context, ULONG_PTR unknown2, ULONG_PTR
}
else wm = get_modref( NtCurrentTeb()->Peb->ImageBaseAddress );
@@ -3869,6 +3874,16 @@ void WINAPI LdrInitializeThunk( CONTEXT *context, ULONG_PTR unknown2, ULONG_PTR
if (NtCurrentTeb()->WowTebOffset) init_wow64( context );
#endif
+ RtlInitUnicodeString( &staging_event_string, L"\\__wine_staging_warn_event" );
+ InitializeObjectAttributes( &staging_event_attr, &staging_event_string, OBJ_OPENIF, NULL, NULL );
@@ -51,7 +51,6 @@ index ee453700e51..c2d4b3c2f86 100644
+ }
+ else
+ WARN_(winediag)("wine-staging %s is a testing version containing experimental patches.\n", wine_get_version());
+
+
RtlAcquirePebLock();
InsertHeadList( &tls_links, &NtCurrentTeb()->TlsLinks );

View File

@@ -0,0 +1,254 @@
From 95708c8fdfcb45cfe667cc9a68ea774c2be52169 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Fri, 30 Jul 2021 15:57:29 +1000
Subject: [PATCH] d3dx11_43: Implement D3DX11GetImageInfoFromMemory
Wine-bug: https://bugs.winehq.org/show_bug.cgi?id=50210
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/d3dx11_42/Makefile.in | 1 +
dlls/d3dx11_43/Makefile.in | 1 +
dlls/d3dx11_43/main.c | 9 --
dlls/d3dx11_43/texture.c | 176 +++++++++++++++++++++++++++++++++++++
4 files changed, 178 insertions(+), 9 deletions(-)
diff --git a/dlls/d3dx11_42/Makefile.in b/dlls/d3dx11_42/Makefile.in
index c34f53a930c..9e1379937a7 100644
--- a/dlls/d3dx11_42/Makefile.in
+++ b/dlls/d3dx11_42/Makefile.in
@@ -2,6 +2,7 @@ EXTRADEFS = -DD3DX11_SDK_VERSION=42
MODULE = d3dx11_42.dll
IMPORTLIB = d3dx11_42
IMPORTS = d3dcompiler
+DELAYIMPORTS = windowscodecs
PARENTSRC = ../d3dx11_43
EXTRADLLFLAGS = -mno-cygwin -Wb,--prefer-native
diff --git a/dlls/d3dx11_43/Makefile.in b/dlls/d3dx11_43/Makefile.in
index b69f3f1ce02..ed23958a671 100644
--- a/dlls/d3dx11_43/Makefile.in
+++ b/dlls/d3dx11_43/Makefile.in
@@ -2,6 +2,7 @@ EXTRADEFS = -DD3DX11_SDK_VERSION=43
MODULE = d3dx11_43.dll
IMPORTLIB = d3dx11
IMPORTS = d3dcompiler
+DELAYIMPORTS = windowscodecs
EXTRADLLFLAGS = -mno-cygwin -Wb,--prefer-native
diff --git a/dlls/d3dx11_43/main.c b/dlls/d3dx11_43/main.c
index 950f6d76f5c..00c1db35e42 100644
--- a/dlls/d3dx11_43/main.c
+++ b/dlls/d3dx11_43/main.c
@@ -66,12 +66,3 @@ HRESULT WINAPI D3DX11GetImageInfoFromFileW(const WCHAR *filename, ID3DX11ThreadP
return E_NOTIMPL;
}
-
-HRESULT WINAPI D3DX11GetImageInfoFromMemory(const void *src_data, SIZE_T src_data_size, ID3DX11ThreadPump *pump,
- D3DX11_IMAGE_INFO *img_info, HRESULT *hresult)
-{
- FIXME("src_data %p, src_data_size %lu, pump %p, img_info %p, hresult %p stub!\n",
- src_data, src_data_size, pump, img_info, hresult);
-
- return E_NOTIMPL;
-}
diff --git a/dlls/d3dx11_43/texture.c b/dlls/d3dx11_43/texture.c
index ee6808d76d6..8addf4f84d3 100644
--- a/dlls/d3dx11_43/texture.c
+++ b/dlls/d3dx11_43/texture.c
@@ -15,14 +15,190 @@
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
+#define COBJMACROS
#include "d3dx11.h"
#include "d3dcompiler.h"
+#include "wincodec.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL(d3dx);
+HRESULT WINAPI WICCreateImagingFactory_Proxy(UINT sdk_version, IWICImagingFactory **imaging_factory);
+
+static const struct
+{
+ const GUID *wic_container_guid;
+ D3DX11_IMAGE_FILE_FORMAT d3dx_file_format;
+}
+file_formats[] =
+{
+ { &GUID_ContainerFormatBmp, D3DX11_IFF_BMP },
+ { &GUID_ContainerFormatJpeg, D3DX11_IFF_JPG },
+ { &GUID_ContainerFormatPng, D3DX11_IFF_PNG },
+ { &GUID_ContainerFormatDds, D3DX11_IFF_DDS },
+ { &GUID_ContainerFormatTiff, D3DX11_IFF_TIFF },
+ { &GUID_ContainerFormatGif, D3DX11_IFF_GIF },
+ { &GUID_ContainerFormatWmp, D3DX11_IFF_WMP },
+};
+
+static D3DX11_IMAGE_FILE_FORMAT wic_container_guid_to_file_format(GUID *container_format)
+{
+ unsigned int i;
+
+ for (i = 0; i < ARRAY_SIZE(file_formats); ++i)
+ {
+ if (IsEqualGUID(file_formats[i].wic_container_guid, container_format))
+ return file_formats[i].d3dx_file_format;
+ }
+ return D3DX11_IFF_FORCE_DWORD;
+}
+
+static D3D11_RESOURCE_DIMENSION wic_dimension_to_d3dx11_dimension(WICDdsDimension wic_dimension)
+{
+ switch (wic_dimension)
+ {
+ case WICDdsTexture1D:
+ return D3D11_RESOURCE_DIMENSION_TEXTURE1D;
+ case WICDdsTexture2D:
+ case WICDdsTextureCube:
+ return D3D11_RESOURCE_DIMENSION_TEXTURE2D;
+ case WICDdsTexture3D:
+ return D3D11_RESOURCE_DIMENSION_TEXTURE3D;
+ default:
+ return D3D11_RESOURCE_DIMENSION_UNKNOWN;
+ }
+}
+
+static const DXGI_FORMAT to_be_converted_format[] =
+{
+ DXGI_FORMAT_UNKNOWN,
+ DXGI_FORMAT_R8_UNORM,
+ DXGI_FORMAT_R8G8_UNORM,
+ DXGI_FORMAT_B5G6R5_UNORM,
+ DXGI_FORMAT_B4G4R4A4_UNORM,
+ DXGI_FORMAT_B5G5R5A1_UNORM,
+ DXGI_FORMAT_B8G8R8X8_UNORM,
+ DXGI_FORMAT_B8G8R8A8_UNORM
+};
+
+static DXGI_FORMAT get_d3dx11_dds_format(DXGI_FORMAT format)
+{
+ unsigned int i;
+
+ for (i = 0; i < ARRAY_SIZE(to_be_converted_format); ++i)
+ {
+ if (format == to_be_converted_format[i])
+ return DXGI_FORMAT_R8G8B8A8_UNORM;
+ }
+ return format;
+}
+
+HRESULT WINAPI D3DX11GetImageInfoFromMemory(const void *src_data, SIZE_T src_data_size, ID3DX11ThreadPump *pump,
+ D3DX11_IMAGE_INFO *img_info, HRESULT *hresult)
+{
+ IWICBitmapFrameDecode *frame = NULL;
+ IWICImagingFactory *factory = NULL;
+ IWICDdsDecoder *dds_decoder = NULL;
+ IWICBitmapDecoder *decoder = NULL;
+ WICDdsParameters dds_params;
+ IWICStream *stream = NULL;
+ unsigned int frame_count;
+ GUID container_format;
+ HRESULT hr;
+
+ TRACE("src_data %p, src_data_size %lu, pump %p, img_info %p, hresult %p.\n",
+ src_data, src_data_size, pump, img_info, hresult);
+
+ if (!src_data || !src_data_size || !img_info)
+ return E_FAIL;
+ if (pump)
+ FIXME("Thread pump is not supported yet.\n");
+
+ WICCreateImagingFactory_Proxy(WINCODEC_SDK_VERSION, &factory);
+ IWICImagingFactory_CreateStream(factory, &stream);
+ hr = IWICStream_InitializeFromMemory(stream, (BYTE *)src_data, src_data_size);
+ if (FAILED(hr))
+ {
+ WARN("Failed to initialize stream.\n");
+ goto end;
+ }
+ hr = IWICImagingFactory_CreateDecoderFromStream(factory, (IStream *)stream, NULL, 0, &decoder);
+ if (FAILED(hr))
+ goto end;
+
+ hr = IWICBitmapDecoder_GetContainerFormat(decoder, &container_format);
+ if (FAILED(hr))
+ goto end;
+ img_info->ImageFileFormat = wic_container_guid_to_file_format(&container_format);
+ if (img_info->ImageFileFormat == D3DX11_IFF_FORCE_DWORD)
+ {
+ hr = E_FAIL;
+ WARN("Unsupported image file format %s.\n", debugstr_guid(&container_format));
+ goto end;
+ }
+
+ hr = IWICBitmapDecoder_GetFrameCount(decoder, &frame_count);
+ if (FAILED(hr) || !frame_count)
+ goto end;
+ hr = IWICBitmapDecoder_GetFrame(decoder, 0, &frame);
+ if (FAILED(hr))
+ goto end;
+ hr = IWICBitmapFrameDecode_GetSize(frame, &img_info->Width, &img_info->Height);
+ if (FAILED(hr))
+ goto end;
+
+ if (img_info->ImageFileFormat == D3DX11_IFF_DDS)
+ {
+ hr = IWICBitmapDecoder_QueryInterface(decoder, &IID_IWICDdsDecoder, (void **)&dds_decoder);
+ if (FAILED(hr))
+ goto end;
+ hr = IWICDdsDecoder_GetParameters(dds_decoder, &dds_params);
+ if (FAILED(hr))
+ goto end;
+ img_info->ArraySize = dds_params.ArraySize;
+ img_info->Depth = dds_params.Depth;
+ img_info->MipLevels = dds_params.MipLevels;
+ img_info->ResourceDimension = wic_dimension_to_d3dx11_dimension(dds_params.Dimension);
+ img_info->Format = get_d3dx11_dds_format(dds_params.DxgiFormat);
+ img_info->MiscFlags = 0;
+ if (dds_params.Dimension == WICDdsTextureCube)
+ {
+ img_info->MiscFlags = D3D11_RESOURCE_MISC_TEXTURECUBE;
+ img_info->ArraySize *= 6;
+ }
+ }
+ else
+ {
+ img_info->ArraySize = 1;
+ img_info->Depth = 1;
+ img_info->MipLevels = 1;
+ img_info->ResourceDimension = D3D11_RESOURCE_DIMENSION_TEXTURE2D;
+ img_info->Format = DXGI_FORMAT_R8G8B8A8_UNORM;
+ img_info->MiscFlags = 0;
+ }
+
+end:
+ if (dds_decoder)
+ IWICDdsDecoder_Release(dds_decoder);
+ if (frame)
+ IWICBitmapFrameDecode_Release(frame);
+ if (decoder)
+ IWICBitmapDecoder_Release(decoder);
+ if (stream)
+ IWICStream_Release(stream);
+ if (factory)
+ IWICImagingFactory_Release(factory);
+
+ if (hr != S_OK)
+ {
+ WARN("Invalid or unsupported image file.\n");
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
HRESULT WINAPI D3DX11CreateShaderResourceViewFromMemory(ID3D11Device *device, const void *data,
SIZE_T data_size, D3DX11_IMAGE_LOAD_INFO *load_info, ID3DX11ThreadPump *pump,
ID3D11ShaderResourceView **view, HRESULT *hresult)
--
2.32.0

View File

@@ -0,0 +1,395 @@
From 2f65959901f62bfc6a48c683e6eaa5d6ed5f7416 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Tue, 3 Aug 2021 11:13:18 +1000
Subject: [PATCH] d3dx11_42: Implement D3DX11CreateTextureFromMemory
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/d3dx11_43/texture.c | 347 ++++++++++++++++++++++++++++++++++++++-
1 file changed, 342 insertions(+), 5 deletions(-)
diff --git a/dlls/d3dx11_43/texture.c b/dlls/d3dx11_43/texture.c
index 8addf4f84d3..f47b8583c6c 100644
--- a/dlls/d3dx11_43/texture.c
+++ b/dlls/d3dx11_43/texture.c
@@ -22,6 +22,7 @@
#include "wincodec.h"
#include "wine/debug.h"
+#include "wine/heap.h"
WINE_DEFAULT_DEBUG_CHANNEL(d3dx);
@@ -43,6 +44,32 @@ file_formats[] =
{ &GUID_ContainerFormatWmp, D3DX11_IFF_WMP },
};
+static const struct
+{
+ const GUID *wic_guid;
+ DXGI_FORMAT dxgi_format;
+}
+wic_pixel_formats[] =
+{
+ { &GUID_WICPixelFormatBlackWhite, DXGI_FORMAT_R1_UNORM },
+ { &GUID_WICPixelFormat8bppAlpha, DXGI_FORMAT_A8_UNORM },
+ { &GUID_WICPixelFormat8bppGray, DXGI_FORMAT_R8_UNORM },
+ { &GUID_WICPixelFormat16bppGray, DXGI_FORMAT_R16_UNORM },
+ { &GUID_WICPixelFormat16bppGrayHalf, DXGI_FORMAT_R16_FLOAT },
+ { &GUID_WICPixelFormat32bppGrayFloat, DXGI_FORMAT_R32_FLOAT },
+ { &GUID_WICPixelFormat16bppBGR565, DXGI_FORMAT_B5G6R5_UNORM },
+ { &GUID_WICPixelFormat16bppBGRA5551, DXGI_FORMAT_B5G5R5A1_UNORM },
+ { &GUID_WICPixelFormat32bppBGR, DXGI_FORMAT_B8G8R8X8_UNORM },
+ { &GUID_WICPixelFormat32bppBGRA, DXGI_FORMAT_B8G8R8A8_UNORM },
+ { &GUID_WICPixelFormat32bppRGBA, DXGI_FORMAT_R8G8B8A8_UNORM },
+ { &GUID_WICPixelFormat32bppRGBA1010102, DXGI_FORMAT_R10G10B10A2_UNORM },
+ { &GUID_WICPixelFormat32bppRGBA1010102XR, DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM },
+ { &GUID_WICPixelFormat64bppRGBA, DXGI_FORMAT_R16G16B16A16_UNORM },
+ { &GUID_WICPixelFormat64bppRGBAHalf, DXGI_FORMAT_R16G16B16A16_FLOAT },
+ { &GUID_WICPixelFormat96bppRGBFloat, DXGI_FORMAT_R32G32B32_FLOAT },
+ { &GUID_WICPixelFormat128bppRGBAFloat, DXGI_FORMAT_R32G32B32A32_FLOAT }
+};
+
static D3DX11_IMAGE_FILE_FORMAT wic_container_guid_to_file_format(GUID *container_format)
{
unsigned int i;
@@ -95,6 +122,175 @@ static DXGI_FORMAT get_d3dx11_dds_format(DXGI_FORMAT format)
return format;
}
+static const DXGI_FORMAT block_compressed_formats[] =
+{
+ DXGI_FORMAT_BC1_TYPELESS, DXGI_FORMAT_BC1_UNORM, DXGI_FORMAT_BC1_UNORM_SRGB,
+ DXGI_FORMAT_BC2_TYPELESS, DXGI_FORMAT_BC2_UNORM, DXGI_FORMAT_BC2_UNORM_SRGB,
+ DXGI_FORMAT_BC3_TYPELESS, DXGI_FORMAT_BC3_UNORM, DXGI_FORMAT_BC3_UNORM_SRGB,
+ DXGI_FORMAT_BC4_TYPELESS, DXGI_FORMAT_BC4_UNORM, DXGI_FORMAT_BC4_SNORM,
+ DXGI_FORMAT_BC5_TYPELESS, DXGI_FORMAT_BC5_UNORM, DXGI_FORMAT_BC5_SNORM,
+ DXGI_FORMAT_BC6H_TYPELESS, DXGI_FORMAT_BC6H_UF16, DXGI_FORMAT_BC6H_SF16,
+ DXGI_FORMAT_BC7_TYPELESS, DXGI_FORMAT_BC7_UNORM, DXGI_FORMAT_BC7_UNORM_SRGB
+};
+
+static BOOL is_block_compressed(DXGI_FORMAT format)
+{
+ unsigned int i;
+
+ for (i = 0; i < ARRAY_SIZE(block_compressed_formats); ++i)
+ if (format == block_compressed_formats[i])
+ return TRUE;
+
+ return FALSE;
+}
+
+static unsigned int get_bpp_from_format(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_R32G32B32A32_TYPELESS:
+ case DXGI_FORMAT_R32G32B32A32_FLOAT:
+ case DXGI_FORMAT_R32G32B32A32_UINT:
+ case DXGI_FORMAT_R32G32B32A32_SINT:
+ return 128;
+ case DXGI_FORMAT_R32G32B32_TYPELESS:
+ case DXGI_FORMAT_R32G32B32_FLOAT:
+ case DXGI_FORMAT_R32G32B32_UINT:
+ case DXGI_FORMAT_R32G32B32_SINT:
+ return 96;
+ case DXGI_FORMAT_R16G16B16A16_TYPELESS:
+ case DXGI_FORMAT_R16G16B16A16_FLOAT:
+ case DXGI_FORMAT_R16G16B16A16_UNORM:
+ case DXGI_FORMAT_R16G16B16A16_UINT:
+ case DXGI_FORMAT_R16G16B16A16_SNORM:
+ case DXGI_FORMAT_R16G16B16A16_SINT:
+ case DXGI_FORMAT_R32G32_TYPELESS:
+ case DXGI_FORMAT_R32G32_FLOAT:
+ case DXGI_FORMAT_R32G32_UINT:
+ case DXGI_FORMAT_R32G32_SINT:
+ case DXGI_FORMAT_R32G8X24_TYPELESS:
+ case DXGI_FORMAT_D32_FLOAT_S8X24_UINT:
+ case DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS:
+ case DXGI_FORMAT_X32_TYPELESS_G8X24_UINT:
+ case DXGI_FORMAT_Y416:
+ case DXGI_FORMAT_Y210:
+ case DXGI_FORMAT_Y216:
+ return 64;
+ case DXGI_FORMAT_R10G10B10A2_TYPELESS:
+ case DXGI_FORMAT_R10G10B10A2_UNORM:
+ case DXGI_FORMAT_R10G10B10A2_UINT:
+ case DXGI_FORMAT_R11G11B10_FLOAT:
+ case DXGI_FORMAT_R8G8B8A8_TYPELESS:
+ case DXGI_FORMAT_R8G8B8A8_UNORM:
+ case DXGI_FORMAT_R8G8B8A8_UNORM_SRGB:
+ case DXGI_FORMAT_R8G8B8A8_UINT:
+ case DXGI_FORMAT_R8G8B8A8_SNORM:
+ case DXGI_FORMAT_R8G8B8A8_SINT:
+ case DXGI_FORMAT_R16G16_TYPELESS:
+ case DXGI_FORMAT_R16G16_FLOAT:
+ case DXGI_FORMAT_R16G16_UNORM:
+ case DXGI_FORMAT_R16G16_UINT:
+ case DXGI_FORMAT_R16G16_SNORM:
+ case DXGI_FORMAT_R16G16_SINT:
+ case DXGI_FORMAT_R32_TYPELESS:
+ case DXGI_FORMAT_D32_FLOAT:
+ case DXGI_FORMAT_R32_FLOAT:
+ case DXGI_FORMAT_R32_UINT:
+ case DXGI_FORMAT_R32_SINT:
+ case DXGI_FORMAT_R24G8_TYPELESS:
+ case DXGI_FORMAT_D24_UNORM_S8_UINT:
+ case DXGI_FORMAT_R24_UNORM_X8_TYPELESS:
+ case DXGI_FORMAT_X24_TYPELESS_G8_UINT:
+ case DXGI_FORMAT_R9G9B9E5_SHAREDEXP:
+ case DXGI_FORMAT_R8G8_B8G8_UNORM:
+ case DXGI_FORMAT_G8R8_G8B8_UNORM:
+ case DXGI_FORMAT_B8G8R8A8_UNORM:
+ case DXGI_FORMAT_B8G8R8X8_UNORM:
+ case DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM:
+ case DXGI_FORMAT_B8G8R8A8_TYPELESS:
+ case DXGI_FORMAT_B8G8R8A8_UNORM_SRGB:
+ case DXGI_FORMAT_B8G8R8X8_TYPELESS:
+ case DXGI_FORMAT_B8G8R8X8_UNORM_SRGB:
+ case DXGI_FORMAT_AYUV:
+ case DXGI_FORMAT_Y410:
+ case DXGI_FORMAT_YUY2:
+ return 32;
+ case DXGI_FORMAT_P010:
+ case DXGI_FORMAT_P016:
+ return 24;
+ case DXGI_FORMAT_R8G8_TYPELESS:
+ case DXGI_FORMAT_R8G8_UNORM:
+ case DXGI_FORMAT_R8G8_UINT:
+ case DXGI_FORMAT_R8G8_SNORM:
+ case DXGI_FORMAT_R8G8_SINT:
+ case DXGI_FORMAT_R16_TYPELESS:
+ case DXGI_FORMAT_R16_FLOAT:
+ case DXGI_FORMAT_D16_UNORM:
+ case DXGI_FORMAT_R16_UNORM:
+ case DXGI_FORMAT_R16_UINT:
+ case DXGI_FORMAT_R16_SNORM:
+ case DXGI_FORMAT_R16_SINT:
+ case DXGI_FORMAT_B5G6R5_UNORM:
+ case DXGI_FORMAT_B5G5R5A1_UNORM:
+ case DXGI_FORMAT_A8P8:
+ case DXGI_FORMAT_B4G4R4A4_UNORM:
+ return 16;
+ case DXGI_FORMAT_NV12:
+ case DXGI_FORMAT_420_OPAQUE:
+ case DXGI_FORMAT_NV11:
+ return 12;
+ case DXGI_FORMAT_R8_TYPELESS:
+ case DXGI_FORMAT_R8_UNORM:
+ case DXGI_FORMAT_R8_UINT:
+ case DXGI_FORMAT_R8_SNORM:
+ case DXGI_FORMAT_R8_SINT:
+ case DXGI_FORMAT_A8_UNORM:
+ case DXGI_FORMAT_AI44:
+ case DXGI_FORMAT_IA44:
+ case DXGI_FORMAT_P8:
+ case DXGI_FORMAT_BC2_TYPELESS:
+ case DXGI_FORMAT_BC2_UNORM:
+ case DXGI_FORMAT_BC2_UNORM_SRGB:
+ case DXGI_FORMAT_BC3_TYPELESS:
+ case DXGI_FORMAT_BC3_UNORM:
+ case DXGI_FORMAT_BC3_UNORM_SRGB:
+ case DXGI_FORMAT_BC5_TYPELESS:
+ case DXGI_FORMAT_BC5_UNORM:
+ case DXGI_FORMAT_BC5_SNORM:
+ case DXGI_FORMAT_BC6H_TYPELESS:
+ case DXGI_FORMAT_BC6H_UF16:
+ case DXGI_FORMAT_BC6H_SF16:
+ case DXGI_FORMAT_BC7_TYPELESS:
+ case DXGI_FORMAT_BC7_UNORM:
+ case DXGI_FORMAT_BC7_UNORM_SRGB:
+ return 8;
+ case DXGI_FORMAT_BC1_TYPELESS:
+ case DXGI_FORMAT_BC1_UNORM:
+ case DXGI_FORMAT_BC1_UNORM_SRGB:
+ case DXGI_FORMAT_BC4_TYPELESS:
+ case DXGI_FORMAT_BC4_UNORM:
+ case DXGI_FORMAT_BC4_SNORM:
+ return 4;
+ case DXGI_FORMAT_R1_UNORM:
+ return 1;
+ default:
+ return 0;
+ }
+}
+
+static const GUID *dxgi_format_to_wic_guid(DXGI_FORMAT format)
+{
+ unsigned int i;
+
+ for (i = 0; i < ARRAY_SIZE(wic_pixel_formats); ++i)
+ {
+ if (wic_pixel_formats[i].dxgi_format == format)
+ return wic_pixel_formats[i].wic_guid;
+ }
+
+ return NULL;
+}
+
HRESULT WINAPI D3DX11GetImageInfoFromMemory(const void *src_data, SIZE_T src_data_size, ID3DX11ThreadPump *pump,
D3DX11_IMAGE_INFO *img_info, HRESULT *hresult)
{
@@ -229,14 +425,155 @@ HRESULT WINAPI D3DX11CreateTextureFromFileW(ID3D11Device *device, const WCHAR *f
return E_NOTIMPL;
}
-HRESULT WINAPI D3DX11CreateTextureFromMemory(ID3D11Device *device, const void *data,
- SIZE_T data_size, D3DX11_IMAGE_LOAD_INFO *load_info, ID3DX11ThreadPump *pump,
+HRESULT WINAPI D3DX11CreateTextureFromMemory(ID3D11Device *device, const void *src_data,
+ SIZE_T src_data_size, D3DX11_IMAGE_LOAD_INFO *load_info, ID3DX11ThreadPump *pump,
ID3D11Resource **texture, HRESULT *hresult)
{
- FIXME("device %p, data %p, data_size %lu, load_info %p, pump %p, texture %p, hresult %p stub.\n",
- device, data, data_size, load_info, pump, texture, hresult);
+ unsigned int frame_count, width, height, stride, frame_size;
+ IWICFormatConverter *converter = NULL;
+ IWICDdsFrameDecode *dds_frame = NULL;
+ D3D11_TEXTURE2D_DESC texture_2d_desc;
+ D3D11_SUBRESOURCE_DATA resource_data;
+ IWICBitmapFrameDecode *frame = NULL;
+ IWICImagingFactory *factory = NULL;
+ IWICBitmapDecoder *decoder = NULL;
+ ID3D11Texture2D *texture_2d;
+ D3DX11_IMAGE_INFO img_info;
+ IWICStream *stream = NULL;
+ const GUID *dst_format;
+ BYTE *buffer = NULL;
+ BOOL can_convert;
+ GUID src_format;
+ HRESULT hr;
- return E_NOTIMPL;
+ TRACE("device %p, src_data %p, src_data_size %lu, load_info %p, pump %p, texture %p, hresult %p.\n",
+ device, src_data, src_data_size, load_info, pump, texture, hresult);
+
+ if (!src_data || !src_data_size || !texture)
+ return E_FAIL;
+ if (load_info)
+ FIXME("load_info is ignored.\n");
+ if (pump)
+ FIXME("Thread pump is not supported yet.\n");
+
+ if (FAILED(D3DX11GetImageInfoFromMemory(src_data, src_data_size, NULL, &img_info, NULL)))
+ return E_FAIL;
+ if (img_info.MiscFlags & D3D11_RESOURCE_MISC_TEXTURECUBE)
+ {
+ FIXME("Cube map is not supported.\n");
+ return E_FAIL;
+ }
+
+ if (FAILED(hr = WICCreateImagingFactory_Proxy(WINCODEC_SDK_VERSION, &factory)))
+ goto end;
+ if (FAILED(hr = IWICImagingFactory_CreateStream(factory, &stream)))
+ goto end;
+ if (FAILED(hr = IWICStream_InitializeFromMemory(stream, (BYTE *)src_data, src_data_size)))
+ goto end;
+ if (FAILED(hr = IWICImagingFactory_CreateDecoderFromStream(factory, (IStream *)stream, NULL, 0, &decoder)))
+ goto end;
+ if (FAILED(hr = IWICBitmapDecoder_GetFrameCount(decoder, &frame_count)) || !frame_count)
+ goto end;
+ if (FAILED(hr = IWICBitmapDecoder_GetFrame(decoder, 0, &frame)))
+ goto end;
+ if (FAILED(hr = IWICBitmapFrameDecode_GetPixelFormat(frame, &src_format)))
+ goto end;
+
+ width = img_info.Width;
+ height = img_info.Height;
+ if (is_block_compressed(img_info.Format))
+ {
+ width = (width + 3) & ~3;
+ height = (height + 3) & ~3;
+ }
+ stride = (width * get_bpp_from_format(img_info.Format) + 7) / 8;
+ frame_size = stride * height;
+
+ if (!(buffer = heap_alloc(frame_size)))
+ {
+ hr = E_FAIL;
+ goto end;
+ }
+
+ if (is_block_compressed(img_info.Format))
+ {
+ if (FAILED(hr = IWICBitmapFrameDecode_QueryInterface(frame, &IID_IWICDdsFrameDecode, (void **)&dds_frame)))
+ goto end;
+ if (FAILED(hr = IWICDdsFrameDecode_CopyBlocks(dds_frame, NULL, stride * 4, frame_size, buffer)))
+ goto end;
+ }
+ else
+ {
+ if (!(dst_format = dxgi_format_to_wic_guid(img_info.Format)))
+ {
+ hr = E_FAIL;
+ FIXME("Unsupported DXGI format %#x.\n", img_info.Format);
+ goto end;
+ }
+
+ if (IsEqualGUID(&src_format, dst_format))
+ {
+ if (FAILED(hr = IWICBitmapFrameDecode_CopyPixels(frame, NULL, stride, frame_size, buffer)))
+ goto end;
+ }
+ else
+ {
+ if (FAILED(hr = IWICImagingFactory_CreateFormatConverter(factory, &converter)))
+ goto end;
+ if (FAILED(hr = IWICFormatConverter_CanConvert(converter, &src_format, dst_format, &can_convert)))
+ goto end;
+ if (!can_convert)
+ {
+ WARN("Format converting %s to %s is not supported by WIC.\n",
+ debugstr_guid(&src_format), debugstr_guid(dst_format));
+ goto end;
+ }
+ if (FAILED(hr = IWICFormatConverter_Initialize(converter, (IWICBitmapSource *)frame, dst_format,
+ WICBitmapDitherTypeErrorDiffusion, 0, 0, WICBitmapPaletteTypeCustom)))
+ goto end;
+ if (FAILED(hr = IWICFormatConverter_CopyPixels(converter, NULL, stride, frame_size, buffer)))
+ goto end;
+ }
+ }
+
+ memset(&texture_2d_desc, 0, sizeof(texture_2d_desc));
+ texture_2d_desc.Width = width;
+ texture_2d_desc.Height = height;
+ texture_2d_desc.MipLevels = 1;
+ texture_2d_desc.ArraySize = img_info.ArraySize;
+ texture_2d_desc.Format = img_info.Format;
+ texture_2d_desc.SampleDesc.Count = 1;
+ texture_2d_desc.Usage = D3D11_USAGE_DEFAULT;
+ texture_2d_desc.BindFlags = D3D11_BIND_SHADER_RESOURCE;
+ texture_2d_desc.MiscFlags = img_info.MiscFlags;
+
+ resource_data.pSysMem = buffer;
+ resource_data.SysMemPitch = stride;
+ resource_data.SysMemSlicePitch = frame_size;
+
+ if (FAILED(hr = ID3D11Device_CreateTexture2D(device, &texture_2d_desc, &resource_data, &texture_2d)))
+ goto end;
+
+ *texture = (ID3D11Resource *)texture_2d;
+ hr = S_OK;
+
+end:
+ if (converter)
+ IWICFormatConverter_Release(converter);
+ if (dds_frame)
+ IWICDdsFrameDecode_Release(dds_frame);
+ if (buffer)
+ heap_free(buffer);
+ if (frame)
+ IWICBitmapFrameDecode_Release(frame);
+ if (decoder)
+ IWICBitmapDecoder_Release(decoder);
+ if (stream)
+ IWICStream_Release(stream);
+ if (factory)
+ IWICImagingFactory_Release(factory);
+
+ return hr;
}
HRESULT WINAPI D3DX11SaveTextureToFileW(ID3D11DeviceContext *context, ID3D11Resource *texture,
--
2.30.2

View File

@@ -0,0 +1,4 @@
Fixes: [50210] - Implement D3DX11GetImageInfoFromMemory
Fixes: [45533] - Implement D3DX11CreateTextureFromMemory
# This patchset will need to wait until the new wined3dx dll implemented.

View File

@@ -1,4 +1,4 @@
From 27517cacf7df657e32e7ca7068c3e86723cb4a3c Mon Sep 17 00:00:00 2001
From 6c3aa646aff81104eb7783138a71d4bb8cf192a7 Mon Sep 17 00:00:00 2001
From: Christian Costa <titan.costa@gmail.com>
Date: Sat, 13 Feb 2016 15:29:37 +0100
Subject: [PATCH] d3dx9_36: Implement D3DXDisassembleShader. (v2)
@@ -6,11 +6,11 @@ Subject: [PATCH] d3dx9_36: Implement D3DXDisassembleShader. (v2)
Changes in v2 (by Christian Costa):
* More generic code for D3DXDisassembleShader.
---
dlls/d3dx9_36/shader.c | 331 ++++++++++++++++++++++++++++++++++++++++-
1 file changed, 328 insertions(+), 3 deletions(-)
dlls/d3dx9_36/shader.c | 332 ++++++++++++++++++++++++++++++++++++++++-
1 file changed, 327 insertions(+), 5 deletions(-)
diff --git a/dlls/d3dx9_36/shader.c b/dlls/d3dx9_36/shader.c
index c59fc791e..79d47b95c 100644
index fe0f99180ac..54d0b158568 100644
--- a/dlls/d3dx9_36/shader.c
+++ b/dlls/d3dx9_36/shader.c
@@ -1,6 +1,7 @@
@@ -30,11 +30,10 @@ index c59fc791e..79d47b95c 100644
#include "d3dx9_private.h"
#include "d3dcommon.h"
#include "d3dcompiler.h"
@@ -2138,10 +2139,334 @@ HRESULT WINAPI D3DXGetShaderSamplers(const DWORD *byte_code, const char **sample
@@ -2336,13 +2337,334 @@ HRESULT WINAPI D3DXGetShaderSamplers(const DWORD *byte_code, const char **sample
return D3D_OK;
}
+
+static const char *decl_usage[] = { "position", "blendweight", "blendindices", "normal", "psize", "texcoord",
+ "tangent", "binormal", "tessfactor", "positiont", "color" };
+
@@ -299,10 +298,11 @@ index c59fc791e..79d47b95c 100644
+ { D3DSIO_COMMENT, "", 0, instr_comment, 0x0100, 0xFFFF }
+};
+
HRESULT WINAPI D3DXDisassembleShader(const DWORD *shader, BOOL colorcode, const char *comments, ID3DXBuffer **disassembly)
HRESULT WINAPI D3DXDisassembleShader(const DWORD *shader, BOOL colorcode, const char *comments,
- ID3DXBuffer **buffer)
+ ID3DXBuffer **disassembly)
{
- FIXME("%p %d %s %p: stub\n", shader, colorcode, debugstr_a(comments), disassembly);
- return E_OUTOFMEMORY;
- TRACE("shader %p, colorcode %d, comments %s, buffer %p.\n", shader, colorcode, debugstr_a(comments), buffer);
+ DWORD *ptr = (DWORD *)shader;
+ char *buffer, *buf;
+ UINT capacity = 4096;
@@ -314,7 +314,9 @@ index c59fc791e..79d47b95c 100644
+
+ if (!shader || !disassembly)
+ return D3DERR_INVALIDCALL;
+
- return D3DDisassemble(shader, D3DXGetShaderSize(shader), colorcode ? D3D_DISASM_ENABLE_COLOR_CODE : 0,
- comments, (ID3DBlob **)buffer);
+ buf = buffer = HeapAlloc(GetProcessHeap(), 0, capacity);
+ if (!buffer)
+ return E_OUTOFMEMORY;
@@ -331,7 +333,7 @@ index c59fc791e..79d47b95c 100644
+ if ((buf - buffer + 128) > capacity)
+ {
+ UINT count = buf - buffer;
+ char *new_buffer = HeapReAlloc(GetProcessHeap(), 0, buffer, capacity * 2);
+ char *new_buffer = HeapReAlloc(GetProcessHeap(), 0, buffer, capacity * 2);
+ if (!new_buffer)
+ {
+ HeapFree(GetProcessHeap(), 0, buffer);
@@ -368,5 +370,5 @@ index c59fc791e..79d47b95c 100644
struct d3dx9_texture_shader
--
2.21.0
2.32.0

View File

@@ -1,144 +0,0 @@
From cca287da02e2946705ad89f6e8c052b68199ad31 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Tue, 1 Jun 2021 17:15:44 +1000
Subject: [PATCH v3] dpnet: Implement IDirectPlay8Server EnumServiceProviders
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/dpnet/server.c | 14 ++++++-
dlls/dpnet/tests/server.c | 86 +++++++++++++++++++++++++++++++++++++++
2 files changed, 98 insertions(+), 2 deletions(-)
diff --git a/dlls/dpnet/server.c b/dlls/dpnet/server.c
index 977771697ac..26dd76388b1 100644
--- a/dlls/dpnet/server.c
+++ b/dlls/dpnet/server.c
@@ -126,9 +126,19 @@ static HRESULT WINAPI IDirectPlay8ServerImpl_EnumServiceProviders(IDirectPlay8Se
PDWORD pcReturned, DWORD dwFlags)
{
IDirectPlay8ServerImpl *This = impl_from_IDirectPlay8Server(iface);
- FIXME("(%p)->(%s %s %p %p %p %d)\n", This, debugstr_guid(pguidServiceProvider), debugstr_guid(pguidApplication),
+ TRACE("(%p)->(%s %s %p %p %p %d)\n", This, debugstr_guid(pguidServiceProvider), debugstr_guid(pguidApplication),
pSPInfoBuffer, pcbEnumData, pcReturned, dwFlags);
- return E_NOTIMPL;
+
+ if(!This->msghandler)
+ return DPNERR_UNINITIALIZED;
+
+ if(dwFlags)
+ FIXME("Unhandled flags %x\n", dwFlags);
+
+ if(pguidApplication)
+ FIXME("Application guid %s is currently being ignored\n", debugstr_guid(pguidApplication));
+
+ return enum_services_providers(pguidServiceProvider, pSPInfoBuffer, pcbEnumData, pcReturned);
}
static HRESULT WINAPI IDirectPlay8ServerImpl_CancelAsyncOperation(IDirectPlay8Server *iface, DPNHANDLE hAsyncHandle, DWORD dwFlags)
diff --git a/dlls/dpnet/tests/server.c b/dlls/dpnet/tests/server.c
index 74a0e5adfcf..ae7e876522d 100644
--- a/dlls/dpnet/tests/server.c
+++ b/dlls/dpnet/tests/server.c
@@ -184,6 +184,91 @@ static void test_server_info(void)
}
}
+static void test_enum_service_providers(void)
+{
+ DPN_SERVICE_PROVIDER_INFO *serv_prov_info;
+ IDirectPlay8Server *server = NULL;
+ DWORD items, size;
+ DWORD i;
+ HRESULT hr;
+
+ hr = CoCreateInstance( &CLSID_DirectPlay8Server, NULL, CLSCTX_ALL, &IID_IDirectPlay8Server, (LPVOID*)&server);
+ ok(hr == S_OK, "Failed to create IDirectPlay8Server object\n");
+ if (FAILED(hr))
+ return;
+
+ size = 0;
+ items = 0;
+ hr = IDirectPlay8Server_EnumServiceProviders(server, NULL, NULL, serv_prov_info, &size, &items, 0);
+ ok(hr == DPNERR_UNINITIALIZED, "got %x\n", hr);
+
+ hr = IDirectPlay8Server_Initialize(server, NULL, DirectPlayMessageHandler, 0);
+ ok(hr == S_OK, "got 0x%08x\n", hr);
+ if (FAILED(hr))
+ {
+ IDirectPlay8Server_Release(server);
+ return;
+ }
+
+ size = 0;
+ items = 0;
+
+ hr = IDirectPlay8Server_EnumServiceProviders(server, NULL, NULL, NULL, &size, NULL, 0);
+ ok(hr == E_POINTER, "IDirectPlay8Server_EnumServiceProviders failed with %x\n", hr);
+
+ hr = IDirectPlay8Server_EnumServiceProviders(server, NULL, NULL, NULL, NULL, &items, 0);
+ ok(hr == E_POINTER, "IDirectPlay8Server_EnumServiceProviders failed with %x\n", hr);
+
+ hr = IDirectPlay8Server_EnumServiceProviders(server, NULL, NULL, NULL, &size, &items, 0);
+ ok(hr == DPNERR_BUFFERTOOSMALL, "IDirectPlay8Server_EnumServiceProviders failed with %x\n", hr);
+ ok(size != 0, "size is unexpectedly 0\n");
+
+ serv_prov_info = HeapAlloc(GetProcessHeap(), 0, size);
+
+ hr = IDirectPlay8Server_EnumServiceProviders(server, NULL, NULL, serv_prov_info, &size, &items, 0);
+ ok(hr == S_OK, "IDirectPlay8Server_EnumServiceProviders failed with %x\n", hr);
+ ok(items != 0, "Found unexpectedly no service providers\n");
+
+ trace("number of items found: %d\n", items);
+
+ for (i=0;i<items;i++)
+ {
+ trace("Found Service Provider: %s\n", wine_dbgstr_w(serv_prov_info[i].pwszName));
+ trace("Found guid: %s\n", wine_dbgstr_guid(&serv_prov_info[i].guid));
+ }
+
+ ok(HeapFree(GetProcessHeap(), 0, serv_prov_info), "Failed freeing server provider info\n");
+
+ size = 0;
+ items = 0;
+
+ hr = IDirectPlay8Server_EnumServiceProviders(server, &CLSID_DP8SP_TCPIP, NULL, NULL, &size, &items, 0);
+ ok(hr == DPNERR_BUFFERTOOSMALL, "IDirectPlay8Server_EnumServiceProviders failed with %x\n", hr);
+ ok(size != 0, "size is unexpectedly 0\n");
+
+ serv_prov_info = HeapAlloc(GetProcessHeap(), 0, size);
+
+ hr = IDirectPlay8Server_EnumServiceProviders(server, &CLSID_DP8SP_TCPIP, NULL, serv_prov_info, &size, &items, 0);
+ ok(hr == S_OK, "IDirectPlay8Server_EnumServiceProviders failed with %x\n", hr);
+ ok(items != 0, "Found unexpectedly no adapter\n");
+
+
+ for (i=0;i<items;i++)
+ {
+ trace("Found adapter: %s\n", wine_dbgstr_w(serv_prov_info[i].pwszName));
+ trace("Found adapter guid: %s\n", wine_dbgstr_guid(&serv_prov_info[i].guid));
+ }
+
+ /* Invalid GUID */
+ items = 88;
+ hr = IDirectPlay8Server_EnumServiceProviders(server, &appguid, NULL, serv_prov_info, &size, &items, 0);
+ ok(hr == DPNERR_DOESNOTEXIST, "IDirectPlay8Peer_EnumServiceProviders failed with %x\n", hr);
+ ok(items == 88, "Found adapter %d\n", items);
+
+ HeapFree(GetProcessHeap(), 0, serv_prov_info);
+ IDirectPlay8Server_Release(server);
+}
+
BOOL is_process_elevated(void)
{
HANDLE token;
@@ -398,6 +483,7 @@ START_TEST(server)
create_server();
test_server_info();
+ test_enum_service_providers();
CoUninitialize();
--
2.30.2

View File

@@ -1 +0,0 @@
Fixes: [51221] dpnet: Impelment IDirectPlay8Server EnumServiceProviders.

View File

@@ -1,4 +1,4 @@
From 723ccff12d0b9516490e34519e244a6486d11b8b Mon Sep 17 00:00:00 2001
From 33486bf9924ffb152e008ec662e2f9905d67c449 Mon Sep 17 00:00:00 2001
From: Zebediah Figura <z.figura12@gmail.com>
Date: Wed, 13 Jun 2018 10:44:49 -0500
Subject: [PATCH] configure: Check for sys/eventfd.h, ppoll(), and shm_open().
@@ -13,10 +13,10 @@ Although perhaps we shouldn't since the server doesn't do this.
3 files changed, 89 insertions(+)
diff --git a/configure b/configure
index 5672688a0d7..24ae489c3a9 100755
index f2319159834..a3916efab32 100755
--- a/configure
+++ b/configure
@@ -7467,6 +7467,7 @@ for ac_header in \
@@ -7543,6 +7543,7 @@ for ac_header in \
sys/cdio.h \
sys/epoll.h \
sys/event.h \
@@ -24,15 +24,15 @@ index 5672688a0d7..24ae489c3a9 100755
sys/filio.h \
sys/ioctl.h \
sys/ipc.h \
@@ -17815,6 +17816,7 @@ for ac_func in \
pipe2 \
@@ -18009,6 +18010,7 @@ for ac_func in \
poll \
port_create \
posix_fadvise \
+ ppoll \
prctl \
pread \
proc_pidinfo \
@@ -18224,6 +18226,72 @@ fi
readlink \
@@ -18402,6 +18404,72 @@ fi
;;
esac
@@ -106,10 +106,10 @@ index 5672688a0d7..24ae489c3a9 100755
then
if ${LDAP_CFLAGS:+false} :; then :
diff --git a/configure.ac b/configure.ac
index 7a03cbc1cab..bfa64a8d68a 100644
index 73869723bd3..6cab92efd74 100644
--- a/configure.ac
+++ b/configure.ac
@@ -494,6 +494,7 @@ AC_CHECK_HEADERS(\
@@ -510,6 +510,7 @@ AC_CHECK_HEADERS(\
sys/cdio.h \
sys/epoll.h \
sys/event.h \
@@ -117,15 +117,15 @@ index 7a03cbc1cab..bfa64a8d68a 100644
sys/filio.h \
sys/ioctl.h \
sys/ipc.h \
@@ -2207,6 +2208,7 @@ AC_CHECK_FUNCS(\
pipe2 \
@@ -2212,6 +2213,7 @@ AC_CHECK_FUNCS(\
poll \
port_create \
posix_fadvise \
+ ppoll \
prctl \
pread \
proc_pidinfo \
@@ -2271,6 +2273,16 @@ case $host_os in
readlink \
@@ -2262,6 +2264,16 @@ case $host_os in
;;
esac
@@ -143,12 +143,12 @@ index 7a03cbc1cab..bfa64a8d68a 100644
if test "x$with_ldap" != "xno"
then
diff --git a/include/config.h.in b/include/config.h.in
index 4adb6325e14..6f1323311d9 100644
index 9f8e7f34ada..5ecf57cde58 100644
--- a/include/config.h.in
+++ b/include/config.h.in
@@ -687,6 +687,9 @@
/* Define to 1 if you have the <port.h> header file. */
#undef HAVE_PORT_H
@@ -507,6 +507,9 @@
/* Define to 1 if you have the `posix_fadvise' function. */
#undef HAVE_POSIX_FADVISE
+/* Define to 1 if you have the `ppoll' function. */
+#undef HAVE_PPOLL
@@ -156,7 +156,7 @@ index 4adb6325e14..6f1323311d9 100644
/* Define to 1 if you have the `prctl' function. */
#undef HAVE_PRCTL
@@ -804,6 +807,9 @@
@@ -585,6 +588,9 @@
/* Define to 1 if `interface_id' is a member of `sg_io_hdr_t'. */
#undef HAVE_SG_IO_HDR_T_INTERFACE_ID
@@ -166,7 +166,7 @@ index 4adb6325e14..6f1323311d9 100644
/* Define if sigaddset is supported */
#undef HAVE_SIGADDSET
@@ -1004,6 +1010,9 @@
@@ -749,6 +755,9 @@
/* Define to 1 if you have the <sys/epoll.h> header file. */
#undef HAVE_SYS_EPOLL_H
@@ -177,5 +177,5 @@ index 4adb6325e14..6f1323311d9 100644
#undef HAVE_SYS_EVENT_H
--
2.28.0
2.33.0

View File

@@ -1,4 +1,4 @@
From 70c7589e029a19a3b048cdf5c222fb36e489ba69 Mon Sep 17 00:00:00 2001
From 4af235c5bc5797cae39578991b302b47052afcbb Mon Sep 17 00:00:00 2001
From: Zebediah Figura <zfigura@codeweavers.com>
Date: Mon, 6 Jul 2020 14:40:43 -0500
Subject: [PATCH] ntdll, server: Implement NtCreateEvent().
@@ -77,12 +77,12 @@ index 87516e7597a..d9c7df967f8 100644
BOOLEAN alertable, const LARGE_INTEGER *timeout ) DECLSPEC_HIDDEN;
diff --git a/dlls/ntdll/unix/sync.c b/dlls/ntdll/unix/sync.c
index 1abc691811b..de4c75afcea 100644
index f5be91e09d4..b54874b5d3d 100644
--- a/dlls/ntdll/unix/sync.c
+++ b/dlls/ntdll/unix/sync.c
@@ -435,6 +435,10 @@ NTSTATUS WINAPI NtCreateEvent( HANDLE *handle, ACCESS_MASK access, const OBJECT_
struct object_attributes *objattr;
@@ -440,6 +440,10 @@ NTSTATUS WINAPI NtCreateEvent( HANDLE *handle, ACCESS_MASK access, const OBJECT_
*handle = 0;
if (type != NotificationEvent && type != SynchronizationEvent) return STATUS_INVALID_PARAMETER;
+
+ if (do_esync())
@@ -92,7 +92,7 @@ index 1abc691811b..de4c75afcea 100644
SERVER_START_REQ( create_event )
diff --git a/server/esync.c b/server/esync.c
index 226e70cd1ad..b9e0a455629 100644
index e41bbbf9349..f89f29150ea 100644
--- a/server/esync.c
+++ b/server/esync.c
@@ -203,6 +203,13 @@ struct semaphore
@@ -125,5 +125,5 @@ index 226e70cd1ad..b9e0a455629 100644
assert( 0 );
}
--
2.29.2
2.30.2

View File

@@ -1,4 +1,4 @@
From 1ecb2712f80d52480a8204824df6b56a88c062b8 Mon Sep 17 00:00:00 2001
From 57742beb169682bcc0d4de196242ee0528e223df Mon Sep 17 00:00:00 2001
From: Zebediah Figura <z.figura12@gmail.com>
Date: Fri, 8 Jun 2018 18:51:40 -0500
Subject: [PATCH] server: Add an object operation to grab the esync file
@@ -42,7 +42,7 @@ Split off to decrease patch size.
33 files changed, 67 insertions(+)
diff --git a/server/async.c b/server/async.c
index 1ac5117edb9..e52707a4929 100644
index 442d98d8c7a..0645cc5f7bb 100644
--- a/server/async.c
+++ b/server/async.c
@@ -72,6 +72,7 @@ static const struct object_ops async_ops =
@@ -53,7 +53,7 @@ index 1ac5117edb9..e52707a4929 100644
async_satisfied, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -499,6 +500,7 @@ static const struct object_ops iosb_ops =
@@ -489,6 +490,7 @@ static const struct object_ops iosb_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
@@ -74,7 +74,7 @@ index 8d0ffbb05f3..ff0d8b5d87b 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/change.c b/server/change.c
index ff8c3ad1037..30b4c9776e1 100644
index b02a9cd65bf..9ccdec75ed4 100644
--- a/server/change.c
+++ b/server/change.c
@@ -114,6 +114,7 @@ static const struct object_ops dir_ops =
@@ -86,7 +86,7 @@ index ff8c3ad1037..30b4c9776e1 100644
no_signal, /* signal */
dir_get_fd, /* get_fd */
diff --git a/server/clipboard.c b/server/clipboard.c
index 1c4875ff726..e21663b5a94 100644
index eb9bd4f7020..cb4ca0362df 100644
--- a/server/clipboard.c
+++ b/server/clipboard.c
@@ -77,6 +77,7 @@ static const struct object_ops clipboard_ops =
@@ -110,7 +110,7 @@ index eb0d256ad09..5a8bb8fb47f 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/console.c b/server/console.c
index 848ee6e8d98..a7f122adacd 100644
index 1e6f6c0f8a3..4443c322548 100644
--- a/server/console.c
+++ b/server/console.c
@@ -81,6 +81,7 @@ static const struct object_ops console_ops =
@@ -170,7 +170,7 @@ index 848ee6e8d98..a7f122adacd 100644
no_signal, /* signal */
console_connection_get_fd, /* get_fd */
diff --git a/server/debugger.c b/server/debugger.c
index 2a2839f42ee..aee4bebb147 100644
index ca84a88258f..08d78eabe9b 100644
--- a/server/debugger.c
+++ b/server/debugger.c
@@ -87,6 +87,7 @@ static const struct object_ops debug_event_ops =
@@ -190,18 +190,18 @@ index 2a2839f42ee..aee4bebb147 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/device.c b/server/device.c
index 6400751e339..6f8a65c6c41 100644
index b669921a003..6086f134df7 100644
--- a/server/device.c
+++ b/server/device.c
@@ -68,6 +68,7 @@ static const struct object_ops irp_call_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
irp_call_signaled, /* signaled */
@@ -67,6 +67,7 @@ static const struct object_ops irp_call_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
+ NULL, /* get_esync_fd */
no_satisfied, /* satisfied */
NULL, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -108,6 +109,7 @@ static const struct object_ops device_manager_ops =
@@ -107,6 +108,7 @@ static const struct object_ops device_manager_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
device_manager_signaled, /* signaled */
@@ -209,7 +209,7 @@ index 6400751e339..6f8a65c6c41 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -165,6 +167,7 @@ static const struct object_ops device_ops =
@@ -164,6 +166,7 @@ static const struct object_ops device_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
@@ -217,7 +217,7 @@ index 6400751e339..6f8a65c6c41 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -217,6 +220,7 @@ static const struct object_ops device_file_ops =
@@ -216,6 +219,7 @@ static const struct object_ops device_file_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
default_fd_signaled, /* signaled */
@@ -226,7 +226,7 @@ index 6400751e339..6f8a65c6c41 100644
no_signal, /* signal */
device_file_get_fd, /* get_fd */
diff --git a/server/directory.c b/server/directory.c
index 30d69459984..1f2e7d28302 100644
index ec8187b425a..1264551f4e4 100644
--- a/server/directory.c
+++ b/server/directory.c
@@ -70,6 +70,7 @@ static const struct object_ops object_type_ops =
@@ -278,7 +278,7 @@ index ccdd465dd5b..3d869037bf5 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/fd.c b/server/fd.c
index 43c0d36dff9..819cd059547 100644
index 01d6c181f1b..f7187ca2b34 100644
--- a/server/fd.c
+++ b/server/fd.c
@@ -218,6 +218,7 @@ static const struct object_ops fd_ops =
@@ -314,7 +314,7 @@ index 43c0d36dff9..819cd059547 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/file.c b/server/file.c
index ccac535e50f..70aa784fa21 100644
index 53c694177df..e3f52f4ef76 100644
--- a/server/file.c
+++ b/server/file.c
@@ -97,6 +97,7 @@ static const struct object_ops file_ops =
@@ -326,7 +326,7 @@ index ccac535e50f..70aa784fa21 100644
no_signal, /* signal */
file_get_fd, /* get_fd */
diff --git a/server/handle.c b/server/handle.c
index 6e0848eedf0..65176c0be30 100644
index 15da701ee99..c07199109fd 100644
--- a/server/handle.c
+++ b/server/handle.c
@@ -126,6 +126,7 @@ static const struct object_ops handle_table_ops =
@@ -350,7 +350,7 @@ index c048908c295..f5450b5a870 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/mailslot.c b/server/mailslot.c
index 5597a21dd29..eec27a89dfc 100644
index d4b2fd1b562..8cd4e9a741a 100644
--- a/server/mailslot.c
+++ b/server/mailslot.c
@@ -78,6 +78,7 @@ static const struct object_ops mailslot_ops =
@@ -386,7 +386,7 @@ index 5597a21dd29..eec27a89dfc 100644
no_signal, /* signal */
mailslot_device_file_get_fd, /* get_fd */
diff --git a/server/mapping.c b/server/mapping.c
index 3a162eae76b..f182ac10b47 100644
index a814fe8090f..c7541f353f4 100644
--- a/server/mapping.c
+++ b/server/mapping.c
@@ -68,6 +68,7 @@ static const struct object_ops ranges_ops =
@@ -426,7 +426,7 @@ index 75ff5117d3f..681cbc3e759 100644
mutex_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/named_pipe.c b/server/named_pipe.c
index a3ce9d463f1..74348b45dc9 100644
index df8c7e3170c..d756de18db0 100644
--- a/server/named_pipe.c
+++ b/server/named_pipe.c
@@ -119,6 +119,7 @@ static const struct object_ops named_pipe_ops =
@@ -470,7 +470,7 @@ index a3ce9d463f1..74348b45dc9 100644
no_signal, /* signal */
named_pipe_device_file_get_fd, /* get_fd */
diff --git a/server/object.h b/server/object.h
index 1aef43018b2..a4b5523866c 100644
index 039bf4e7d4e..0a09663cfa7 100644
--- a/server/object.h
+++ b/server/object.h
@@ -81,6 +81,8 @@ struct object_ops
@@ -483,7 +483,7 @@ index 1aef43018b2..a4b5523866c 100644
void (*satisfied)(struct object *,struct wait_queue_entry *);
/* signal an object */
diff --git a/server/process.c b/server/process.c
index f65d7abe2af..af7aef0cdac 100644
index 0870de5bb26..0b14f4e6193 100644
--- a/server/process.c
+++ b/server/process.c
@@ -91,6 +91,7 @@ static const struct object_ops process_ops =
@@ -502,7 +502,7 @@ index f65d7abe2af..af7aef0cdac 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -200,6 +202,7 @@ static const struct object_ops job_ops =
@@ -203,6 +205,7 @@ static const struct object_ops job_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
job_signaled, /* signaled */
@@ -511,10 +511,10 @@ index f65d7abe2af..af7aef0cdac 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/queue.c b/server/queue.c
index 2c7ad2de9eb..0bd84fb7223 100644
index 54dcd246d89..2d6d262f09d 100644
--- a/server/queue.c
+++ b/server/queue.c
@@ -172,6 +172,7 @@ static const struct object_ops msg_queue_ops =
@@ -175,6 +175,7 @@ static const struct object_ops msg_queue_ops =
msg_queue_add_queue, /* add_queue */
msg_queue_remove_queue, /* remove_queue */
msg_queue_signaled, /* signaled */
@@ -522,7 +522,7 @@ index 2c7ad2de9eb..0bd84fb7223 100644
msg_queue_satisfied, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -209,6 +210,7 @@ static const struct object_ops thread_input_ops =
@@ -212,6 +213,7 @@ static const struct object_ops thread_input_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
@@ -531,10 +531,10 @@ index 2c7ad2de9eb..0bd84fb7223 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/registry.c b/server/registry.c
index 74da4d1d9a4..e9f7bf761e8 100644
index 427da8a5883..1dd201d5b69 100644
--- a/server/registry.c
+++ b/server/registry.c
@@ -174,6 +174,7 @@ static const struct object_ops key_ops =
@@ -178,6 +178,7 @@ static const struct object_ops key_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
@@ -567,7 +567,7 @@ index 543d5883ec8..9f37e2d8aa6 100644
semaphore_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/serial.c b/server/serial.c
index ba8402c5935..ba5d470704e 100644
index d3ea4cbe420..af1fb49e52b 100644
--- a/server/serial.c
+++ b/server/serial.c
@@ -92,6 +92,7 @@ static const struct object_ops serial_ops =
@@ -591,10 +591,10 @@ index 0c22c157f2b..45d176de46c 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/sock.c b/server/sock.c
index 775ec6edf32..651736a2280 100644
index 50bfc08e145..a7ae0e1c7dc 100644
--- a/server/sock.c
+++ b/server/sock.c
@@ -189,6 +189,7 @@ static const struct object_ops sock_ops =
@@ -247,6 +247,7 @@ static const struct object_ops sock_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
default_fd_signaled, /* signaled */
@@ -602,7 +602,7 @@ index 775ec6edf32..651736a2280 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
sock_get_fd, /* get_fd */
@@ -1526,6 +1527,7 @@ static const struct object_ops ifchange_ops =
@@ -2966,6 +2967,7 @@ static const struct object_ops ifchange_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
@@ -610,7 +610,7 @@ index 775ec6edf32..651736a2280 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
ifchange_get_fd, /* get_fd */
@@ -1746,6 +1748,7 @@ static const struct object_ops socket_device_ops =
@@ -3186,6 +3188,7 @@ static const struct object_ops socket_device_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
@@ -631,10 +631,10 @@ index 3879bb685f7..5ebe35636e1 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/thread.c b/server/thread.c
index b78ffe558de..62f9a3f877a 100644
index 3bd932bad9f..7192faa544a 100644
--- a/server/thread.c
+++ b/server/thread.c
@@ -110,6 +110,7 @@ static const struct object_ops thread_apc_ops =
@@ -97,6 +97,7 @@ static const struct object_ops thread_apc_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
thread_apc_signaled, /* signaled */
@@ -642,7 +642,7 @@ index b78ffe558de..62f9a3f877a 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -147,6 +148,7 @@ static const struct object_ops context_ops =
@@ -142,6 +143,7 @@ static const struct object_ops context_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
context_signaled, /* signaled */
@@ -650,7 +650,7 @@ index b78ffe558de..62f9a3f877a 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
no_get_fd, /* get_fd */
@@ -196,6 +198,7 @@ static const struct object_ops thread_ops =
@@ -191,6 +193,7 @@ static const struct object_ops thread_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
thread_signaled, /* signaled */
@@ -659,7 +659,7 @@ index b78ffe558de..62f9a3f877a 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/timer.c b/server/timer.c
index 49483d9ae13..23d03aa3582 100644
index 5e265d2ddf6..86ecf3cb7a3 100644
--- a/server/timer.c
+++ b/server/timer.c
@@ -77,6 +77,7 @@ static const struct object_ops timer_ops =
@@ -671,10 +671,10 @@ index 49483d9ae13..23d03aa3582 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/token.c b/server/token.c
index 089f1c5c61e..d08539084bd 100644
index 5d2fc9555a2..79beea16ab2 100644
--- a/server/token.c
+++ b/server/token.c
@@ -161,6 +161,7 @@ static const struct object_ops token_ops =
@@ -162,6 +162,7 @@ static const struct object_ops token_ops =
no_add_queue, /* add_queue */
NULL, /* remove_queue */
NULL, /* signaled */
@@ -683,7 +683,7 @@ index 089f1c5c61e..d08539084bd 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
diff --git a/server/winstation.c b/server/winstation.c
index 1c7552f0687..86d82619433 100644
index 61f9f77c73f..a38b2e831c4 100644
--- a/server/winstation.c
+++ b/server/winstation.c
@@ -75,6 +75,7 @@ static const struct object_ops winstation_ops =
@@ -703,5 +703,5 @@ index 1c7552f0687..86d82619433 100644
no_signal, /* signal */
no_get_fd, /* get_fd */
--
2.30.1
2.32.0

View File

@@ -1,4 +1,4 @@
From 8770d44fb2cdaf01cfd74321712b3b63a2906e31 Mon Sep 17 00:00:00 2001
From 1496c3a96452deeb4ca687bc61e2125bc82fff71 Mon Sep 17 00:00:00 2001
From: Zebediah Figura <zfigura@codeweavers.com>
Date: Mon, 6 Jul 2020 16:34:56 -0500
Subject: [PATCH] ntdll, server: Implement NtCreateMutant().
@@ -6,9 +6,9 @@ Subject: [PATCH] ntdll, server: Implement NtCreateMutant().
---
dlls/ntdll/unix/esync.c | 16 ++++++++++++++++
dlls/ntdll/unix/esync.h | 3 +++
dlls/ntdll/unix/sync.c | 3 +++
dlls/ntdll/unix/sync.c | 4 ++++
server/esync.c | 14 ++++++++++++++
4 files changed, 36 insertions(+)
4 files changed, 37 insertions(+)
diff --git a/dlls/ntdll/unix/esync.c b/dlls/ntdll/unix/esync.c
index 88490e08ef9..df9eb2696a1 100644
@@ -59,13 +59,14 @@ index 8480a213b2a..38ebefc9eed 100644
BOOLEAN alertable, const LARGE_INTEGER *timeout ) DECLSPEC_HIDDEN;
diff --git a/dlls/ntdll/unix/sync.c b/dlls/ntdll/unix/sync.c
index 1d2e831964f..56292db271a 100644
index 47ab533d5c7..7e492320cee 100644
--- a/dlls/ntdll/unix/sync.c
+++ b/dlls/ntdll/unix/sync.c
@@ -597,6 +597,9 @@ NTSTATUS WINAPI NtCreateMutant( HANDLE *handle, ACCESS_MASK access, const OBJECT
data_size_t len;
@@ -608,6 +608,10 @@ NTSTATUS WINAPI NtCreateMutant( HANDLE *handle, ACCESS_MASK access, const OBJECT
struct object_attributes *objattr;
*handle = 0;
+
+ if (do_esync())
+ return esync_create_mutex( handle, access, attr, owned );
+
@@ -73,7 +74,7 @@ index 1d2e831964f..56292db271a 100644
SERVER_START_REQ( create_mutex )
diff --git a/server/esync.c b/server/esync.c
index ddee22432e5..12911fccb6a 100644
index ac59779a454..913104e3dd4 100644
--- a/server/esync.c
+++ b/server/esync.c
@@ -204,6 +204,13 @@ struct semaphore
@@ -105,5 +106,5 @@ index ddee22432e5..12911fccb6a 100644
assert( 0 );
}
--
2.28.0
2.30.2

View File

@@ -1,4 +1,4 @@
From a934f314a164256748e2e9764343504f7cf8050b Mon Sep 17 00:00:00 2001
From 7f04be3dd881287f1a74b7fe5829fa5917afa054 Mon Sep 17 00:00:00 2001
From: Zebediah Figura <zfigura@codeweavers.com>
Date: Mon, 6 Jul 2020 16:56:09 -0500
Subject: [PATCH] ntdll: Implement NtOpenSemaphore().
@@ -6,10 +6,10 @@ Subject: [PATCH] ntdll: Implement NtOpenSemaphore().
---
dlls/ntdll/unix/esync.c | 47 +++++++++++++++++++++++++++++++++++++++++
dlls/ntdll/unix/esync.h | 2 ++
dlls/ntdll/unix/sync.c | 3 +++
dlls/ntdll/unix/sync.c | 4 ++++
server/esync.c | 31 +++++++++++++++++++++++++++
server/protocol.def | 12 +++++++++++
5 files changed, 95 insertions(+)
5 files changed, 96 insertions(+)
diff --git a/dlls/ntdll/unix/esync.c b/dlls/ntdll/unix/esync.c
index 6d8653cd107..8e7e50ce777 100644
@@ -90,13 +90,14 @@ index bee08ff857f..2738e8b7f87 100644
extern NTSTATUS esync_create_event( HANDLE *handle, ACCESS_MASK access,
diff --git a/dlls/ntdll/unix/sync.c b/dlls/ntdll/unix/sync.c
index 64f96a32ccf..35f2ac95d36 100644
index a51462abeac..36322f6afb6 100644
--- a/dlls/ntdll/unix/sync.c
+++ b/dlls/ntdll/unix/sync.c
@@ -349,6 +349,9 @@ NTSTATUS WINAPI NtOpenSemaphore( HANDLE *handle, ACCESS_MASK access, const OBJEC
{
@@ -353,6 +353,10 @@ NTSTATUS WINAPI NtOpenSemaphore( HANDLE *handle, ACCESS_MASK access, const OBJEC
NTSTATUS ret;
*handle = 0;
+
+ if (do_esync())
+ return esync_open_semaphore( handle, access, attr );
+
@@ -104,7 +105,7 @@ index 64f96a32ccf..35f2ac95d36 100644
SERVER_START_REQ( open_semaphore )
diff --git a/server/esync.c b/server/esync.c
index 12911fccb6a..1703608263f 100644
index 913104e3dd4..da97c6c140b 100644
--- a/server/esync.c
+++ b/server/esync.c
@@ -412,6 +412,37 @@ DECL_HANDLER(create_esync)
@@ -146,10 +147,10 @@ index 12911fccb6a..1703608263f 100644
* server. The client should only read from (i.e. wait on) this object. */
DECL_HANDLER(get_esync_fd)
diff --git a/server/protocol.def b/server/protocol.def
index 789bc56e7f1..5b8f66ffd80 100644
index 776d3d72dc2..575cf291bb0 100644
--- a/server/protocol.def
+++ b/server/protocol.def
@@ -3690,6 +3690,18 @@ enum esync_type
@@ -3750,6 +3750,18 @@ enum esync_type
unsigned int shm_idx;
@END
@@ -169,5 +170,5 @@ index 789bc56e7f1..5b8f66ffd80 100644
@REQ(get_esync_fd)
obj_handle_t handle; /* handle to the object */
--
2.28.0
2.30.2

View File

@@ -1,4 +1,4 @@
From 9898e1c47bdba4bda336b9c17a20d34d68e66215 Mon Sep 17 00:00:00 2001
From 96393a0cd6acfcb87d11488e726d4e294e646c4f Mon Sep 17 00:00:00 2001
From: Zebediah Figura <zfigura@codeweavers.com>
Date: Mon, 6 Jul 2020 16:58:19 -0500
Subject: [PATCH] ntdll: Implement NtOpenEvent().
@@ -42,11 +42,11 @@ index 2738e8b7f87..da1b72d4413 100644
extern NTSTATUS esync_set_event( HANDLE handle ) DECLSPEC_HIDDEN;
diff --git a/dlls/ntdll/unix/sync.c b/dlls/ntdll/unix/sync.c
index 35f2ac95d36..9296b172f88 100644
index 36322f6afb6..6bc8200f46b 100644
--- a/dlls/ntdll/unix/sync.c
+++ b/dlls/ntdll/unix/sync.c
@@ -467,6 +467,9 @@ NTSTATUS WINAPI NtOpenEvent( HANDLE *handle, ACCESS_MASK access, const OBJECT_AT
@@ -476,6 +476,9 @@ NTSTATUS WINAPI NtOpenEvent( HANDLE *handle, ACCESS_MASK access, const OBJECT_AT
*handle = 0;
if ((ret = validate_open_object_attributes( attr ))) return ret;
+ if (do_esync())
@@ -56,5 +56,5 @@ index 35f2ac95d36..9296b172f88 100644
{
req->access = access;
--
2.28.0
2.30.2

View File

@@ -1,4 +1,4 @@
From 7f91f35e896ffb63409c1d1a619565f35a65ef7f Mon Sep 17 00:00:00 2001
From 995f2ecab37c47bb3112d11ce2313d37711965ca Mon Sep 17 00:00:00 2001
From: Zebediah Figura <zfigura@codeweavers.com>
Date: Mon, 6 Jul 2020 16:59:35 -0500
Subject: [PATCH] ntdll: Implement NtOpenMutant().
@@ -42,11 +42,11 @@ index da1b72d4413..cb48e2cd022 100644
extern NTSTATUS esync_wait_objects( DWORD count, const HANDLE *handles, BOOLEAN wait_any,
diff --git a/dlls/ntdll/unix/sync.c b/dlls/ntdll/unix/sync.c
index 9296b172f88..4a97cdd32fd 100644
index 6bc8200f46b..c1c57caab40 100644
--- a/dlls/ntdll/unix/sync.c
+++ b/dlls/ntdll/unix/sync.c
@@ -632,6 +632,9 @@ NTSTATUS WINAPI NtOpenMutant( HANDLE *handle, ACCESS_MASK access, const OBJECT_A
@@ -646,6 +646,9 @@ NTSTATUS WINAPI NtOpenMutant( HANDLE *handle, ACCESS_MASK access, const OBJECT_A
*handle = 0;
if ((ret = validate_open_object_attributes( attr ))) return ret;
+ if (do_esync())
@@ -56,5 +56,5 @@ index 9296b172f88..4a97cdd32fd 100644
{
req->access = access;
--
2.28.0
2.30.2

View File

@@ -1,4 +1,4 @@
From ab9811ec42c11a8dc6f4e756838886bf55b244bb Mon Sep 17 00:00:00 2001
From a791c331b23e717a5f6c0397e4c290e8e8abd2f2 Mon Sep 17 00:00:00 2001
From: Zebediah Figura <z.figura12@gmail.com>
Date: Sat, 7 Jul 2018 12:57:47 +0200
Subject: [PATCH] server: Create eventfd descriptors for pseudo-fd objects and
@@ -11,7 +11,7 @@ Subject: [PATCH] server: Create eventfd descriptors for pseudo-fd objects and
3 files changed, 25 insertions(+), 2 deletions(-)
diff --git a/server/fd.c b/server/fd.c
index 50f915ed503..36f9770aed3 100644
index 880a5037925..c6db8d13265 100644
--- a/server/fd.c
+++ b/server/fd.c
@@ -102,6 +102,7 @@
@@ -30,7 +30,7 @@ index 50f915ed503..36f9770aed3 100644
};
static void fd_dump( struct object *obj, int verbose );
@@ -1596,6 +1598,9 @@ static void fd_destroy( struct object *obj )
@@ -1606,6 +1608,9 @@ static void fd_destroy( struct object *obj )
free( fd->unlink_name );
free( fd->unix_name );
}
@@ -40,7 +40,7 @@ index 50f915ed503..36f9770aed3 100644
}
/* check if the desired access is possible without violating */
@@ -1713,6 +1718,7 @@ static struct fd *alloc_fd_object(void)
@@ -1723,6 +1728,7 @@ static struct fd *alloc_fd_object(void)
fd->poll_index = -1;
fd->completion = NULL;
fd->comp_flags = 0;
@@ -48,7 +48,7 @@ index 50f915ed503..36f9770aed3 100644
init_async_queue( &fd->read_q );
init_async_queue( &fd->write_q );
init_async_queue( &fd->wait_q );
@@ -1753,11 +1759,15 @@ struct fd *alloc_pseudo_fd( const struct fd_ops *fd_user_ops, struct object *use
@@ -1763,11 +1769,15 @@ struct fd *alloc_pseudo_fd( const struct fd_ops *fd_user_ops, struct object *use
fd->completion = NULL;
fd->comp_flags = 0;
fd->no_fd_status = STATUS_BAD_DEVICE_TYPE;
@@ -64,7 +64,7 @@ index 50f915ed503..36f9770aed3 100644
return fd;
}
@@ -2263,6 +2273,9 @@ void set_fd_signaled( struct fd *fd, int signaled )
@@ -2293,6 +2303,9 @@ void set_fd_signaled( struct fd *fd, int signaled )
if (fd->comp_flags & FILE_SKIP_SET_EVENT_ON_HANDLE) return;
fd->signaled = signaled;
if (signaled) wake_up( fd->user, 0 );
@@ -74,7 +74,7 @@ index 50f915ed503..36f9770aed3 100644
}
/* check if events are pending and if yes return which one(s) */
@@ -2288,6 +2301,15 @@ int default_fd_signaled( struct object *obj, struct wait_queue_entry *entry )
@@ -2318,6 +2331,15 @@ int default_fd_signaled( struct object *obj, struct wait_queue_entry *entry )
return ret;
}
@@ -91,19 +91,19 @@ index 50f915ed503..36f9770aed3 100644
{
int events = 0;
diff --git a/server/file.h b/server/file.h
index 0fa66e5750a..edafb4a1ca7 100644
index 80f2191c050..224048a4292 100644
--- a/server/file.h
+++ b/server/file.h
@@ -103,6 +103,7 @@ extern char *dup_fd_name( struct fd *root, const char *name );
@@ -106,6 +106,7 @@ extern char *dup_fd_name( struct fd *root, const char *name );
extern void get_nt_name( struct fd *fd, struct unicode_str *name );
extern int default_fd_signaled( struct object *obj, struct wait_queue_entry *entry );
+extern int default_fd_get_esync_fd( struct object *obj, enum esync_type *type );
extern int default_fd_get_poll_events( struct fd *fd );
extern void default_poll_event( struct fd *fd, int event );
extern void fd_queue_async( struct fd *fd, struct async *async, int type );
extern void fd_cancel_async( struct fd *fd, struct async *async );
diff --git a/server/named_pipe.c b/server/named_pipe.c
index d756de18db0..3ed9a543fdc 100644
index 6b4401810dc..27f4497bfe2 100644
--- a/server/named_pipe.c
+++ b/server/named_pipe.c
@@ -168,7 +168,7 @@ static const struct object_ops pipe_server_ops =
@@ -115,7 +115,7 @@ index d756de18db0..3ed9a543fdc 100644
no_satisfied, /* satisfied */
no_signal, /* signal */
pipe_end_get_fd, /* get_fd */
@@ -212,7 +212,7 @@ static const struct object_ops pipe_client_ops =
@@ -213,7 +213,7 @@ static const struct object_ops pipe_client_ops =
add_queue, /* add_queue */
remove_queue, /* remove_queue */
default_fd_signaled, /* signaled */
@@ -125,5 +125,5 @@ index d756de18db0..3ed9a543fdc 100644
no_signal, /* signal */
pipe_end_get_fd, /* get_fd */
--
2.30.2
2.33.0

View File

@@ -1,4 +1,4 @@
From 8a91b7a88d96f735f7236afeed90c376a18f0eea Mon Sep 17 00:00:00 2001
From 8204d928d034b627c2c4bc7930f62a352d609ad0 Mon Sep 17 00:00:00 2001
From: Daniel Wendt <daniel.wendt@linux.com>
Date: Fri, 15 Nov 2013 12:52:37 +0100
Subject: [PATCH] gdi32: fix for rotated Arc, ArcTo, Chord and Pie drawing
@@ -6,15 +6,15 @@ Subject: [PATCH] gdi32: fix for rotated Arc, ArcTo, Chord and Pie drawing
Wine-Bug: http://bugs.winehq.org/show_bug.cgi?id=34579
---
dlls/gdi32/dibdrv/graphics.c | 80 ++++++++++++++++++++++++++++++++++++++++++++
dlls/gdi32/dibdrv/graphics.c | 80 ++++++++++++++++++++++++++++++++++++
dlls/gdi32/gdi_private.h | 3 ++
2 files changed, 83 insertions(+)
diff --git a/dlls/gdi32/dibdrv/graphics.c b/dlls/gdi32/dibdrv/graphics.c
index 7d71fbb..d269cc1 100644
index 9bd6dc557a5..da9144f0862 100644
--- a/dlls/gdi32/dibdrv/graphics.c
+++ b/dlls/gdi32/dibdrv/graphics.c
@@ -313,6 +313,60 @@ static int get_arc_points( int arc_dir, const RECT *rect, POINT start, POINT end
@@ -312,6 +312,60 @@ static int get_arc_points( int arc_dir, const RECT *rect, POINT start, POINT end
return pos - count;
}
@@ -75,7 +75,7 @@ index 7d71fbb..d269cc1 100644
/* backend for arc functions; extra_lines is -1 for ArcTo, 0 for Arc, 1 for Chord, 2 for Pie */
static BOOL draw_arc( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
INT start_x, INT start_y, INT end_x, INT end_y, INT extra_lines )
@@ -325,6 +379,22 @@ static BOOL draw_arc( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
@@ -324,6 +378,22 @@ static BOOL draw_arc( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
BOOL ret = TRUE;
HRGN outline = 0, interior = 0;
@@ -98,7 +98,7 @@ index 7d71fbb..d269cc1 100644
if (!get_pen_device_rect( dc, pdev, &rect, left, top, right, bottom )) return TRUE;
width = rect.right - rect.left;
@@ -358,6 +428,16 @@ static BOOL draw_arc( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
@@ -357,6 +427,16 @@ static BOOL draw_arc( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
points[count].y = rect.top + height / 2;
count++;
}
@@ -116,17 +116,17 @@ index 7d71fbb..d269cc1 100644
{
HeapFree( GetProcessHeap(), 0, points );
diff --git a/dlls/gdi32/gdi_private.h b/dlls/gdi32/gdi_private.h
index 920cd1e..4949187 100644
index 2dddf361d5b..e7d0090a52b 100644
--- a/dlls/gdi32/gdi_private.h
+++ b/dlls/gdi32/gdi_private.h
@@ -608,4 +608,7 @@ extern void free_heap_bits( struct gdi_image_bits *bits ) DECLSPEC_HIDDEN;
extern HMODULE gdi32_module DECLSPEC_HIDDEN;
@@ -289,4 +289,7 @@ static inline int get_dib_info_size( const BITMAPINFO *info, UINT coloruse )
return FIELD_OFFSET( BITMAPINFO, bmiColors[info->bmiHeader.biClrUsed] );
}
+BOOL xform_has_rotate_and_uniform_scale_and_shear( const XFORM *xform ) DECLSPEC_HIDDEN;
+BOOL xform_decompose_rotation_and_translation( XFORM *xform, XFORM *rotation_and_translation ) DECLSPEC_HIDDEN;
+
#endif /* __WINE_GDI_PRIVATE_H */
--
1.9.1
2.33.0

View File

@@ -1,18 +1,18 @@
From b278711b2c76680e6e26a114f74d7f7c26ff6328 Mon Sep 17 00:00:00 2001
From 017514cff847b53d409bf5c8735c30d26474ed8f Mon Sep 17 00:00:00 2001
From: Daniel Wendt <daniel.wendt@linux.com>
Date: Tue, 10 Dec 2013 14:55:32 +0100
Subject: [PATCH] gdi32: fix for rotated ellipse
Bug: http://bugs.winehq.org/show_bug.cgi?id=35331
---
dlls/gdi32/dibdrv/graphics.c | 60 +++++++++++++++++++++++++++++++-------------
dlls/gdi32/dibdrv/graphics.c | 60 +++++++++++++++++++++++++-----------
1 file changed, 42 insertions(+), 18 deletions(-)
diff --git a/dlls/gdi32/dibdrv/graphics.c b/dlls/gdi32/dibdrv/graphics.c
index d269cc1..447aab5 100644
index da9144f0862..6a0519644f4 100644
--- a/dlls/gdi32/dibdrv/graphics.c
+++ b/dlls/gdi32/dibdrv/graphics.c
@@ -1555,6 +1555,23 @@ BOOL dibdrv_RoundRect( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
@@ -1535,6 +1535,23 @@ BOOL CDECL dibdrv_RoundRect( PHYSDEV dev, INT left, INT top, INT right, INT bott
BOOL ret = TRUE;
HRGN outline = 0, interior = 0;
@@ -36,16 +36,16 @@ index d269cc1..447aab5 100644
if (!get_pen_device_rect( dc, pdev, &rect, left, top, right, bottom )) return TRUE;
pt[0].x = pt[0].y = 0;
@@ -1575,23 +1592,6 @@ BOOL dibdrv_RoundRect( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
@@ -1555,23 +1572,6 @@ BOOL CDECL dibdrv_RoundRect( PHYSDEV dev, INT left, INT top, INT right, INT bott
return FALSE;
}
- if (pdev->brush.style != BS_NULL &&
- !(interior = CreateRoundRectRgn( rect.left, rect.top, rect.right + 1, rect.bottom + 1,
- ellipse_width, ellipse_height )))
- !(interior = NtGdiCreateRoundRectRgn( rect.left, rect.top, rect.right + 1, rect.bottom + 1,
- ellipse_width, ellipse_height )))
- {
- HeapFree( GetProcessHeap(), 0, points );
- if (outline) DeleteObject( outline );
- if (outline) NtGdiDeleteObjectApp( outline );
- return FALSE;
- }
-
@@ -53,14 +53,14 @@ index d269cc1..447aab5 100644
- if (interior && !outline)
- {
- ret = brush_region( pdev, interior );
- DeleteObject( interior );
- NtGdiDeleteObjectApp( interior );
- interior = 0;
- }
-
count = ellipse_first_quadrant( ellipse_width, ellipse_height, points );
if (dc->ArcDirection == AD_CLOCKWISE)
@@ -1635,13 +1635,37 @@ BOOL dibdrv_RoundRect( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
if (dc->attr->arc_direction == AD_CLOCKWISE)
@@ -1615,13 +1615,37 @@ BOOL CDECL dibdrv_RoundRect( PHYSDEV dev, INT left, INT top, INT right, INT bott
}
count = end + 1;
@@ -77,7 +77,7 @@ index d269cc1..447aab5 100644
+ !(interior = CreatePolygonRgn(points, count, ALTERNATE)))
+ {
+ HeapFree( GetProcessHeap(), 0, points );
+ if (outline) DeleteObject( outline );
+ if (outline) NtGdiDeleteObjectApp( outline );
+ return FALSE;
+ }
+
@@ -85,7 +85,7 @@ index d269cc1..447aab5 100644
+ if (interior && !outline)
+ {
+ ret = brush_region( pdev, interior );
+ DeleteObject( interior );
+ NtGdiDeleteObjectApp( interior );
+ interior = 0;
+ }
+
@@ -95,10 +95,10 @@ index d269cc1..447aab5 100644
if (interior)
{
- CombineRgn( interior, interior, outline, RGN_DIFF );
- NtGdiCombineRgn( interior, interior, outline, RGN_DIFF );
ret = brush_region( pdev, interior );
DeleteObject( interior );
NtGdiDeleteObjectApp( interior );
}
--
1.9.1
2.33.0

View File

@@ -1,4 +1,4 @@
From 798934ff91c9ed7b445af4b8c7e6442fede713fb Mon Sep 17 00:00:00 2001
From e5140396b7787d48d39f0b47876022c64fc1c2c7 Mon Sep 17 00:00:00 2001
From: Fabian Maurer <dark.shadow4@web.de>
Date: Fri, 10 Apr 2020 18:47:18 +0200
Subject: [PATCH] kernelbase: Implement sortkey generation on official tables
@@ -10,10 +10,10 @@ Signed-off-by: Fabian Maurer <dark.shadow4@web.de>
2 files changed, 413 insertions(+), 123 deletions(-)
diff --git a/dlls/kernel32/tests/locale.c b/dlls/kernel32/tests/locale.c
index 42e14eb736f..29cfe95a47b 100644
index c65c2cce3f2..a5d88288f27 100644
--- a/dlls/kernel32/tests/locale.c
+++ b/dlls/kernel32/tests/locale.c
@@ -2692,6 +2692,13 @@ static void test_lcmapstring_unicode(lcmapstring_wrapper func_ptr, const char *f
@@ -2697,6 +2697,13 @@ static void test_lcmapstring_unicode(lcmapstring_wrapper func_ptr, const char *f
lstrlenW(symbols_stripped) + 1, ret);
ok(!lstrcmpW(buf, symbols_stripped), "%s string comparison mismatch\n", func_name);
@@ -27,7 +27,7 @@ index 42e14eb736f..29cfe95a47b 100644
/* test srclen = 0 */
SetLastError(0xdeadbeef);
ret = func_ptr(0, upper_case, 0, buf, ARRAY_SIZE(buf));
@@ -3114,6 +3121,135 @@ static void test_sorting(void)
@@ -3126,6 +3133,135 @@ static void test_sorting(void)
}
}
@@ -163,17 +163,17 @@ index 42e14eb736f..29cfe95a47b 100644
static void test_FoldStringA(void)
{
int ret, i, j;
@@ -7180,4 +7316,5 @@ START_TEST(locale)
@@ -7191,4 +7327,5 @@ START_TEST(locale)
test_NLSVersion();
test_geo_name();
/* this requires collation table patch to make it MS compatible */
if (0) test_sorting();
test_sorting();
+ test_unicode_sorting();
}
diff --git a/dlls/kernelbase/locale.c b/dlls/kernelbase/locale.c
index 24e8cd3f338..0e40db40f72 100644
index 89b35775053..5da87e065f1 100644
--- a/dlls/kernelbase/locale.c
+++ b/dlls/kernelbase/locale.c
@@ -2161,127 +2161,6 @@ static int wcstombs_codepage( UINT codepage, DWORD flags, const WCHAR *src, int
@@ -2164,127 +2164,6 @@ static int wcstombs_codepage( UINT codepage, DWORD flags, const WCHAR *src, int
return wcstombs_sbcs( info, src, srclen, dst, dstlen );
}
@@ -301,7 +301,7 @@ index 24e8cd3f338..0e40db40f72 100644
/* compose a full-width katakana. return consumed source characters. */
static int compose_katakana( const WCHAR *src, int srclen, WCHAR *dst )
{
@@ -2609,6 +2488,280 @@ static int compare_weights(int flags, const WCHAR *str1, int len1,
@@ -2612,6 +2491,280 @@ static int compare_weights(int flags, const WCHAR *str1, int len1,
return len1 - len2;
}
@@ -582,7 +582,7 @@ index 24e8cd3f338..0e40db40f72 100644
static const struct geoinfo *get_geoinfo_ptr( GEOID geoid )
{
@@ -5292,8 +5445,8 @@ INT WINAPI DECLSPEC_HOTPATCH LCMapStringEx( const WCHAR *locale, DWORD flags, co
@@ -5303,8 +5456,8 @@ INT WINAPI DECLSPEC_HOTPATCH LCMapStringEx( const WCHAR *locale, DWORD flags, co
TRACE( "(%s,0x%08x,%s,%d,%p,%d)\n",
debugstr_w(locale), flags, debugstr_wn(src, srclen), srclen, dst, dstlen );
@@ -594,5 +594,5 @@ index 24e8cd3f338..0e40db40f72 100644
}
--
2.30.1
2.30.2

View File

@@ -1,15 +1,15 @@
From adcb17116397f81a1ffec30badc6c02317033821 Mon Sep 17 00:00:00 2001
From ef7af537a65151a43603cf10a88d91a73fe07de4 Mon Sep 17 00:00:00 2001
From: Fabian Maurer <dark.shadow4@web.de>
Date: Sun, 6 Dec 2020 20:57:16 +0100
Subject: [PATCH] kernelbase: Implement CompareString functions
---
dlls/kernel32/tests/locale.c | 35 +++--
dlls/kernel32/tests/locale.c | 33 ++--
dlls/kernelbase/locale.c | 286 +++++++++++++++++++----------------
2 files changed, 175 insertions(+), 146 deletions(-)
2 files changed, 174 insertions(+), 145 deletions(-)
diff --git a/dlls/kernel32/tests/locale.c b/dlls/kernel32/tests/locale.c
index 276422801cb..51c6d91c0b5 100644
index 320e8f79387..667a950f4f1 100644
--- a/dlls/kernel32/tests/locale.c
+++ b/dlls/kernel32/tests/locale.c
@@ -1960,16 +1960,16 @@ static void test_CompareStringA(void)
@@ -33,7 +33,7 @@ index 276422801cb..51c6d91c0b5 100644
lcid = MAKELCID(MAKELANGID(LANG_POLISH, SUBLANG_DEFAULT), SORT_DEFAULT);
@@ -2050,9 +2050,9 @@ static void test_CompareStringW(void)
@@ -2055,9 +2055,9 @@ static void test_CompareStringW(void)
ok(ret == CSTR_EQUAL, "expected CSTR_EQUAL, got %d\n", ret);
ret = CompareStringW(CP_ACP, NORM_IGNORENONSPACE, ABC_EE, 3, A_ACUTE_BC, 4);
@@ -45,7 +45,7 @@ index 276422801cb..51c6d91c0b5 100644
ret = CompareStringW(CP_ACP, NORM_IGNORENONSPACE, A_ACUTE_BC, 4, A_ACUTE_BC_DECOMP, 5);
ok(ret == CSTR_EQUAL, "expected CSTR_EQUAL, got %d\n", ret);
@@ -2064,12 +2064,12 @@ static void test_CompareStringW(void)
@@ -2069,12 +2069,12 @@ static void test_CompareStringW(void)
ret = CompareStringW(CP_ACP, 0, A_NULL_BC, 4, A_ACUTE_BC, 4);
ok(ret == CSTR_LESS_THAN, "expected CSTR_LESS_THAN, got %d\n", ret);
ret = CompareStringW(CP_ACP, NORM_IGNORENONSPACE, A_NULL_BC, 4, A_ACUTE_BC, 4);
@@ -60,7 +60,7 @@ index 276422801cb..51c6d91c0b5 100644
}
struct comparestringex_test {
@@ -2106,7 +2106,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
@@ -2111,7 +2111,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{ /* 5 */
"tr-TR", 0,
@@ -69,7 +69,7 @@ index 276422801cb..51c6d91c0b5 100644
},
/* with NORM_IGNORECASE */
{ /* 6 */
@@ -2131,7 +2131,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
@@ -2136,7 +2136,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{ /* 11 */
"tr-TR", NORM_IGNORECASE,
@@ -78,7 +78,7 @@ index 276422801cb..51c6d91c0b5 100644
},
/* with NORM_LINGUISTIC_CASING */
{ /* 12 */
@@ -2156,7 +2156,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
@@ -2161,7 +2161,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{ /* 17 */
"tr-TR", NORM_LINGUISTIC_CASING,
@@ -87,7 +87,7 @@ index 276422801cb..51c6d91c0b5 100644
},
/* with LINGUISTIC_IGNORECASE */
{ /* 18 */
@@ -2181,7 +2181,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
@@ -2186,7 +2186,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{ /* 23 */
"tr-TR", LINGUISTIC_IGNORECASE,
@@ -96,7 +96,7 @@ index 276422801cb..51c6d91c0b5 100644
},
/* with NORM_LINGUISTIC_CASING | NORM_IGNORECASE */
{ /* 24 */
@@ -2206,7 +2206,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
@@ -2211,7 +2211,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{ /* 29 */
"tr-TR", NORM_LINGUISTIC_CASING | NORM_IGNORECASE,
@@ -105,7 +105,7 @@ index 276422801cb..51c6d91c0b5 100644
},
/* with NORM_LINGUISTIC_CASING | LINGUISTIC_IGNORECASE */
{ /* 30 */
@@ -2231,7 +2231,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
@@ -2236,7 +2236,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{ /* 35 */
"tr-TR", NORM_LINGUISTIC_CASING | LINGUISTIC_IGNORECASE,
@@ -114,7 +114,7 @@ index 276422801cb..51c6d91c0b5 100644
}
};
@@ -3385,6 +3385,9 @@ static const struct sorting_test_entry unicode_sorting_tests[] =
@@ -3397,6 +3397,9 @@ static const struct sorting_test_entry unicode_sorting_tests[] =
{ L"en-US", CSTR_LESS_THAN, CSTR_LESS_THAN, 0, L"\x00dc", L"\x1ee9" },
{ L"en-US", CSTR_LESS_THAN, CSTR_LESS_THAN, 0, L"\x00fc", L"\x1ee6" },
{ L"en-US", CSTR_GREATER_THAN, CSTR_GREATER_THAN, 0, L"\x0152", L"\x00d6" },
@@ -124,7 +124,7 @@ index 276422801cb..51c6d91c0b5 100644
};
static void test_unicode_sorting(void)
@@ -6126,7 +6129,7 @@ static void test_FindNLSStringEx(void)
@@ -6138,7 +6141,7 @@ static void test_FindNLSStringEx(void)
{ localeW, FIND_FROMSTART, comb_s_accent1W, ARRAY_SIZE(comb_s_accent1W)-1,
comb_s_accent2W, ARRAY_SIZE(comb_s_accent2W)-1, 0, 0, 6, 1, TRUE },
{ localeW, FIND_FROMSTART, comb_q_accent1W, ARRAY_SIZE(comb_q_accent1W)-1,
@@ -133,19 +133,11 @@ index 276422801cb..51c6d91c0b5 100644
{ 0 }
};
struct test_data *ptest;
@@ -7490,6 +7493,6 @@ START_TEST(locale)
test_NLSVersion();
test_geo_name();
/* this requires collation table patch to make it MS compatible */
- if (0) test_sorting();
+ test_sorting();
test_unicode_sorting();
}
diff --git a/dlls/kernelbase/locale.c b/dlls/kernelbase/locale.c
index f651d7dc384..abcafbfa586 100644
index 5b27dd1d36c..01bc3357cf1 100644
--- a/dlls/kernelbase/locale.c
+++ b/dlls/kernelbase/locale.c
@@ -2368,126 +2368,6 @@ static int map_to_halfwidth( WCHAR c, WCHAR *dst, int dstlen )
@@ -2371,126 +2371,6 @@ static int map_to_halfwidth( WCHAR c, WCHAR *dst, int dstlen )
return 1;
}
@@ -272,7 +264,7 @@ index f651d7dc384..abcafbfa586 100644
enum sortkey_special_script
{
SORTKEY_UNSORTABLE = 0,
@@ -2525,6 +2405,7 @@ struct sortkey_data
@@ -2528,6 +2408,7 @@ struct sortkey_data
BYTE *buffer;
int buffer_pos;
int buffer_len;
@@ -280,7 +272,7 @@ index f651d7dc384..abcafbfa586 100644
};
static DWORD sortkey_get_exception(WCHAR ch, const struct sortguid *locale)
@@ -2736,7 +2617,10 @@ static void sortkey_add_diacritic_weights(struct sortkey_data *data, int flags,
@@ -2739,7 +2620,10 @@ static void sortkey_add_diacritic_weights(struct sortkey_data *data, int flags,
if (old_pos >= diacritic_start_pos)
{
if (old_pos < data->buffer_len)
@@ -291,7 +283,7 @@ index f651d7dc384..abcafbfa586 100644
}
else
sortkey_add_diacritic_weight(data, info.weight_diacritic, last_weighted_pos);
@@ -2945,6 +2829,7 @@ static int sortkey_generate(int flags, const WCHAR *locale_name, const WCHAR *st
@@ -2948,6 +2832,7 @@ static int sortkey_generate(int flags, const WCHAR *locale_name, const WCHAR *st
data.buffer = buffer;
data.buffer_pos = 0;
data.buffer_len = buffer ? buffer_len : 0;
@@ -299,7 +291,7 @@ index f651d7dc384..abcafbfa586 100644
if (str_len == -1)
str_len = wcslen(str);
@@ -2994,6 +2879,155 @@ static int sortkey_generate(int flags, const WCHAR *locale_name, const WCHAR *st
@@ -2997,6 +2882,155 @@ static int sortkey_generate(int flags, const WCHAR *locale_name, const WCHAR *st
return 0;
}
@@ -455,7 +447,7 @@ index f651d7dc384..abcafbfa586 100644
static const struct geoinfo *get_geoinfo_ptr( GEOID geoid )
{
int min = 0, max = ARRAY_SIZE( geoinfodata )-1;
@@ -3467,16 +3501,8 @@ INT WINAPI CompareStringEx( const WCHAR *locale, DWORD flags, const WCHAR *str1,
@@ -3471,16 +3505,8 @@ INT WINAPI CompareStringEx( const WCHAR *locale, DWORD flags, const WCHAR *str1,
if (len1 < 0) len1 = lstrlenW(str1);
if (len2 < 0) len2 = lstrlenW(str2);
@@ -475,5 +467,5 @@ index f651d7dc384..abcafbfa586 100644
--
2.30.1
2.30.2

View File

@@ -1,8 +1,8 @@
From d95656904e4d7d2c9a4006e90f123e28bbcdbb70 Mon Sep 17 00:00:00 2001
From 1adbc46410773bdd75d844280738be677bb75906 Mon Sep 17 00:00:00 2001
From: Derek Lesho <dlesho@codeweavers.com>
Date: Tue, 9 Mar 2021 16:53:09 -0500
Subject: [PATCH 01/39] winegstreamer: Activate source pad in push mode if it
isn't activated in pull mode.
Subject: [PATCH] winegstreamer: Activate source pad in push mode if it isn't
activated in pull mode.
Since our source pad is not part of any element, gstreamer won't end up activating it
directly through the state transition. Instead, if the downstream element doesn't
@@ -15,10 +15,10 @@ Signed-off-by: Derek Lesho <dlesho@codeweavers.com>
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/dlls/winegstreamer/wg_parser.c b/dlls/winegstreamer/wg_parser.c
index 0d59297a026..00ff02ef462 100644
index cd12a23d0c8..9b4c9c1c9ed 100644
--- a/dlls/winegstreamer/wg_parser.c
+++ b/dlls/winegstreamer/wg_parser.c
@@ -58,7 +58,7 @@ struct wg_parser
@@ -61,7 +61,7 @@ struct wg_parser
pthread_mutex_t mutex;
pthread_cond_t init_cond;
@@ -27,7 +27,7 @@ index 0d59297a026..00ff02ef462 100644
pthread_cond_t read_cond, read_done_cond;
struct
@@ -1365,9 +1365,12 @@ static gboolean src_activate_mode_cb(GstPad *pad, GstObject *parent, GstPadMode
@@ -1358,9 +1358,12 @@ static gboolean src_activate_mode_cb(GstPad *pad, GstObject *parent, GstPadMode
GST_DEBUG("%s source pad for parser %p in %s mode.",
activate ? "Activating" : "Deactivating", parser, gst_pad_mode_get_name(mode));
@@ -40,7 +40,7 @@ index 0d59297a026..00ff02ef462 100644
return TRUE;
case GST_PAD_MODE_PUSH:
return activate_push(pad, activate);
@@ -1612,6 +1615,8 @@ static void CDECL wg_parser_disconnect(struct wg_parser *parser)
@@ -1636,6 +1639,8 @@ static void CDECL wg_parser_disconnect(struct wg_parser *parser)
pthread_mutex_unlock(&parser->mutex);
gst_element_set_state(parser->container, GST_STATE_NULL);
@@ -49,7 +49,7 @@ index 0d59297a026..00ff02ef462 100644
gst_pad_unlink(parser->my_src, parser->their_sink);
gst_object_unref(parser->my_src);
gst_object_unref(parser->their_sink);
@@ -1667,6 +1672,8 @@ static BOOL decodebin_parser_init_gst(struct wg_parser *parser)
@@ -1687,6 +1692,8 @@ static BOOL decodebin_parser_init_gst(struct wg_parser *parser)
}
gst_element_set_state(parser->container, GST_STATE_PAUSED);
@@ -58,7 +58,7 @@ index 0d59297a026..00ff02ef462 100644
ret = gst_element_get_state(parser->container, NULL, NULL, -1);
if (ret == GST_STATE_CHANGE_FAILURE)
{
@@ -1718,6 +1725,8 @@ static BOOL avi_parser_init_gst(struct wg_parser *parser)
@@ -1734,6 +1741,8 @@ static BOOL avi_parser_init_gst(struct wg_parser *parser)
}
gst_element_set_state(parser->container, GST_STATE_PAUSED);
@@ -67,7 +67,7 @@ index 0d59297a026..00ff02ef462 100644
ret = gst_element_get_state(parser->container, NULL, NULL, -1);
if (ret == GST_STATE_CHANGE_FAILURE)
{
@@ -1772,6 +1781,8 @@ static BOOL mpeg_audio_parser_init_gst(struct wg_parser *parser)
@@ -1784,6 +1793,8 @@ static BOOL mpeg_audio_parser_init_gst(struct wg_parser *parser)
gst_pad_set_active(stream->my_sink, 1);
gst_element_set_state(parser->container, GST_STATE_PAUSED);
@@ -76,7 +76,7 @@ index 0d59297a026..00ff02ef462 100644
ret = gst_element_get_state(parser->container, NULL, NULL, -1);
if (ret == GST_STATE_CHANGE_FAILURE)
{
@@ -1826,6 +1837,8 @@ static BOOL wave_parser_init_gst(struct wg_parser *parser)
@@ -1825,6 +1836,8 @@ static BOOL wave_parser_init_gst(struct wg_parser *parser)
gst_pad_set_active(stream->my_sink, 1);
gst_element_set_state(parser->container, GST_STATE_PAUSED);

Some files were not shown because too many files have changed in this diff Show More