Wine-Devel
By thread
wine-devel@list.winehq.org
By month
Messages by month
- ----- 2026 -----
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2005 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2004 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2003 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2002 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2001 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
June 2022
- 68 participants
- 3274 messages
[PATCH v2 6/8] mfplat/tests: Remove duplicated tests.
by Giovanni Mascellani
The same tests are already performed in test_MFGetPlaneSize().
Signed-off-by: Giovanni Mascellani <gmascellani(a)codeweavers.com>
---
v2:
* Added
---
dlls/mfplat/tests/mfplat.c | 10 ----------
1 file changed, 10 deletions(-)
diff --git a/dlls/mfplat/tests/mfplat.c b/dlls/mfplat/tests/mfplat.c
index fd757d26d9b..74de51b42f1 100644
--- a/dlls/mfplat/tests/mfplat.c
+++ b/dlls/mfplat/tests/mfplat.c
@@ -4318,7 +4318,6 @@ image_size_tests[] =
static void test_MFCalculateImageSize(void)
{
- DWORD plane_size;
unsigned int i;
UINT32 size;
HRESULT hr;
@@ -4340,15 +4339,6 @@ static void test_MFCalculateImageSize(void)
ok(hr == S_OK || (is_broken && hr == E_INVALIDARG), "%u: failed to calculate image size, hr %#lx.\n", i, hr);
ok(size == ptr->size, "%u: unexpected image size %u, expected %u. Size %u x %u, format %s.\n", i, size, ptr->size,
ptr->width, ptr->height, wine_dbgstr_an((char *)&ptr->subtype->Data1, 4));
-
- if (pMFGetPlaneSize)
- {
- unsigned int expected = ptr->plane_size ? ptr->plane_size : ptr->size;
-
- hr = pMFGetPlaneSize(ptr->subtype->Data1, ptr->width, ptr->height, &plane_size);
- ok(hr == S_OK, "%u: failed to get plane size, hr %#lx.\n", i, hr);
- ok(plane_size == expected, "%u: unexpected plane size %lu, expected %u.\n", i, plane_size, expected);
- }
}
}
--
2.36.1
June 14, 2022
[PATCH v2 5/8] mfplat/buffer: Redirect all Lock2D() implementations to Lock2DSize().
by Giovanni Mascellani
Signed-off-by: Giovanni Mascellani <gmascellani(a)codeweavers.com>
---
v2:
* Remove the trace in memory_2d_buffer_Lock2D()
---
dlls/mfplat/buffer.c | 116 +++++++------------------------------------
1 file changed, 18 insertions(+), 98 deletions(-)
diff --git a/dlls/mfplat/buffer.c b/dlls/mfplat/buffer.c
index a7ba306223d..52800b37203 100644
--- a/dlls/mfplat/buffer.c
+++ b/dlls/mfplat/buffer.c
@@ -485,44 +485,12 @@ static ULONG WINAPI memory_2d_buffer_Release(IMF2DBuffer2 *iface)
return IMFMediaBuffer_Release(&buffer->IMFMediaBuffer_iface);
}
-static HRESULT memory_2d_buffer_lock(struct buffer *buffer, BYTE **scanline0, LONG *pitch,
- BYTE **buffer_start, DWORD *buffer_length)
-{
- HRESULT hr = S_OK;
-
- if (buffer->_2d.linear_buffer)
- hr = MF_E_UNEXPECTED;
- else
- {
- ++buffer->_2d.locks;
- *scanline0 = buffer->_2d.scanline0;
- *pitch = buffer->_2d.pitch;
- if (buffer_start)
- *buffer_start = buffer->data;
- if (buffer_length)
- *buffer_length = buffer->max_length;
- }
-
- return hr;
-}
-
static HRESULT WINAPI memory_2d_buffer_Lock2D(IMF2DBuffer2 *iface, BYTE **scanline0, LONG *pitch)
{
- struct buffer *buffer = impl_from_IMF2DBuffer2(iface);
- HRESULT hr;
+ DWORD buffer_length;
+ BYTE *buffer_start;
- TRACE("%p, %p, %p.\n", iface, scanline0, pitch);
-
- if (!scanline0 || !pitch)
- return E_POINTER;
-
- EnterCriticalSection(&buffer->cs);
-
- hr = memory_2d_buffer_lock(buffer, scanline0, pitch, NULL, NULL);
-
- LeaveCriticalSection(&buffer->cs);
-
- return hr;
+ return IMF2DBuffer2_Lock2DSize(iface, MF2DBuffer_LockFlags_ReadWrite, scanline0, pitch, &buffer_start, &buffer_length);
}
static HRESULT WINAPI memory_2d_buffer_Unlock2D(IMF2DBuffer2 *iface)
@@ -616,7 +584,7 @@ static HRESULT WINAPI memory_2d_buffer_Lock2DSize(IMF2DBuffer2 *iface, MF2DBuffe
LONG *pitch, BYTE **buffer_start, DWORD *buffer_length)
{
struct buffer *buffer = impl_from_IMF2DBuffer2(iface);
- HRESULT hr;
+ HRESULT hr = S_OK;
TRACE("%p, %#x, %p, %p, %p, %p.\n", iface, flags, scanline0, pitch, buffer_start, buffer_length);
@@ -625,7 +593,18 @@ static HRESULT WINAPI memory_2d_buffer_Lock2DSize(IMF2DBuffer2 *iface, MF2DBuffe
EnterCriticalSection(&buffer->cs);
- hr = memory_2d_buffer_lock(buffer, scanline0, pitch, buffer_start, buffer_length);
+ if (buffer->_2d.linear_buffer)
+ hr = MF_E_UNEXPECTED;
+ else
+ {
+ ++buffer->_2d.locks;
+ *scanline0 = buffer->_2d.scanline0;
+ *pitch = buffer->_2d.pitch;
+ if (buffer_start)
+ *buffer_start = buffer->data;
+ if (buffer_length)
+ *buffer_length = buffer->max_length;
+ }
LeaveCriticalSection(&buffer->cs);
@@ -655,37 +634,6 @@ static const IMF2DBuffer2Vtbl memory_2d_buffer_vtbl =
memory_2d_buffer_Copy2DTo,
};
-static HRESULT WINAPI d3d9_surface_buffer_Lock2D(IMF2DBuffer2 *iface, BYTE **scanline0, LONG *pitch)
-{
- struct buffer *buffer = impl_from_IMF2DBuffer2(iface);
- HRESULT hr = S_OK;
-
- TRACE("%p, %p, %p.\n", iface, scanline0, pitch);
-
- if (!scanline0 || !pitch)
- return E_POINTER;
-
- EnterCriticalSection(&buffer->cs);
-
- if (buffer->_2d.linear_buffer)
- hr = MF_E_UNEXPECTED;
- else if (!buffer->_2d.locks)
- {
- hr = IDirect3DSurface9_LockRect(buffer->d3d9_surface.surface, &buffer->d3d9_surface.rect, NULL, 0);
- }
-
- if (SUCCEEDED(hr))
- {
- buffer->_2d.locks++;
- *scanline0 = buffer->d3d9_surface.rect.pBits;
- *pitch = buffer->d3d9_surface.rect.Pitch;
- }
-
- LeaveCriticalSection(&buffer->cs);
-
- return hr;
-}
-
static HRESULT WINAPI d3d9_surface_buffer_Unlock2D(IMF2DBuffer2 *iface)
{
struct buffer *buffer = impl_from_IMF2DBuffer2(iface);
@@ -781,7 +729,7 @@ static const IMF2DBuffer2Vtbl d3d9_surface_buffer_vtbl =
memory_2d_buffer_QueryInterface,
memory_2d_buffer_AddRef,
memory_2d_buffer_Release,
- d3d9_surface_buffer_Lock2D,
+ memory_2d_buffer_Lock2D,
d3d9_surface_buffer_Unlock2D,
d3d9_surface_buffer_GetScanline0AndPitch,
memory_2d_buffer_IsContiguousFormat,
@@ -1030,34 +978,6 @@ static HRESULT WINAPI dxgi_surface_buffer_SetCurrentLength(IMFMediaBuffer *iface
return S_OK;
}
-static HRESULT WINAPI dxgi_surface_buffer_Lock2D(IMF2DBuffer2 *iface, BYTE **scanline0, LONG *pitch)
-{
- struct buffer *buffer = impl_from_IMF2DBuffer2(iface);
- HRESULT hr = S_OK;
-
- TRACE("%p, %p, %p.\n", iface, scanline0, pitch);
-
- if (!scanline0 || !pitch)
- return E_POINTER;
-
- EnterCriticalSection(&buffer->cs);
-
- if (buffer->_2d.linear_buffer)
- hr = MF_E_UNEXPECTED;
- else if (!buffer->_2d.locks++)
- hr = dxgi_surface_buffer_map(buffer);
-
- if (SUCCEEDED(hr))
- {
- *scanline0 = buffer->dxgi_surface.map_desc.pData;
- *pitch = buffer->dxgi_surface.map_desc.RowPitch;
- }
-
- LeaveCriticalSection(&buffer->cs);
-
- return hr;
-}
-
static HRESULT WINAPI dxgi_surface_buffer_Unlock2D(IMF2DBuffer2 *iface)
{
struct buffer *buffer = impl_from_IMF2DBuffer2(iface);
@@ -1236,7 +1156,7 @@ static const IMF2DBuffer2Vtbl dxgi_surface_buffer_vtbl =
memory_2d_buffer_QueryInterface,
memory_2d_buffer_AddRef,
memory_2d_buffer_Release,
- dxgi_surface_buffer_Lock2D,
+ memory_2d_buffer_Lock2D,
dxgi_surface_buffer_Unlock2D,
dxgi_surface_buffer_GetScanline0AndPitch,
memory_2d_buffer_IsContiguousFormat,
--
2.36.1
June 14, 2022
[PATCH v2 4/8] mfplat/tests: Test interaction between Lock2D() and LockRect().
by Giovanni Mascellani
Signed-off-by: Giovanni Mascellani <gmascellani(a)codeweavers.com>
---
dlls/mfplat/tests/mfplat.c | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/dlls/mfplat/tests/mfplat.c b/dlls/mfplat/tests/mfplat.c
index aefd4aa46c1..fd757d26d9b 100644
--- a/dlls/mfplat/tests/mfplat.c
+++ b/dlls/mfplat/tests/mfplat.c
@@ -6519,9 +6519,23 @@ static void test_MFCreateDXSurfaceBuffer(void)
hr = IMF2DBuffer_GetScanline0AndPitch(_2dbuffer, &data, &pitch);
ok(hr == HRESULT_FROM_WIN32(ERROR_WAS_UNLOCKED), "Unexpected hr %#lx.\n", hr);
+ hr = IDirect3DSurface9_LockRect(backbuffer, &locked_rect, NULL, 0);
+ ok(hr == S_OK, "Failed to lock back buffer, hr %#lx.\n", hr);
+
+ /* Cannot lock the buffer while the surface is locked. */
+ hr = IMF2DBuffer_Lock2D(_2dbuffer, &data, &pitch);
+ ok(hr == D3DERR_INVALIDCALL, "Unexpected hr %#lx.\n", hr);
+
+ hr = IDirect3DSurface9_UnlockRect(backbuffer);
+ ok(hr == S_OK, "Failed to unlock back buffer, hr %#lx.\n", hr);
+
hr = IMF2DBuffer_Lock2D(_2dbuffer, &data, &pitch);
ok(hr == S_OK, "Unexpected hr %#lx.\n", hr);
+ /* Cannot lock the surface once the buffer is locked. */
+ hr = IDirect3DSurface9_LockRect(backbuffer, &locked_rect, NULL, 0);
+ ok(hr == D3DERR_INVALIDCALL, "Unexpected hr %#lx.\n", hr);
+
hr = IMF2DBuffer_GetScanline0AndPitch(_2dbuffer, &data, &pitch);
ok(hr == S_OK, "Unexpected hr %#lx.\n", hr);
--
2.36.1
June 14, 2022
[PATCH v2 3/8] mfplat/tests: Test interaction between Lock() and LockRect().
by Giovanni Mascellani
Signed-off-by: Giovanni Mascellani <gmascellani(a)codeweavers.com>
---
dlls/mfplat/tests/mfplat.c | 26 +++++++++++++++++++++++++-
1 file changed, 25 insertions(+), 1 deletion(-)
diff --git a/dlls/mfplat/tests/mfplat.c b/dlls/mfplat/tests/mfplat.c
index 52608c05929..aefd4aa46c1 100644
--- a/dlls/mfplat/tests/mfplat.c
+++ b/dlls/mfplat/tests/mfplat.c
@@ -6391,6 +6391,7 @@ static void test_MFCreateDXSurfaceBuffer(void)
{
IDirect3DSurface9 *backbuffer = NULL, *surface;
IDirect3DSwapChain9 *swapchain;
+ D3DLOCKED_RECT locked_rect;
DWORD length, max_length;
IDirect3DDevice9 *device;
IMF2DBuffer2 *_2dbuffer2;
@@ -6463,9 +6464,32 @@ static void test_MFCreateDXSurfaceBuffer(void)
ok(hr == S_OK, "Failed to get length, hr %#lx.\n", hr);
ok(length == 2 * max_length, "Unexpected length %lu.\n", length);
+ hr = IDirect3DSurface9_LockRect(backbuffer, &locked_rect, NULL, 0);
+ ok(hr == S_OK, "Failed to lock back buffer, hr %#lx.\n", hr);
+
+ /* Cannot lock while the surface is locked. */
+ hr = IMFMediaBuffer_Lock(buffer, &data, NULL, &length);
+ ok(hr == D3DERR_INVALIDCALL, "Unexpected hr %#lx.\n", hr);
+
+ hr = IDirect3DSurface9_UnlockRect(backbuffer);
+ ok(hr == S_OK, "Failed to unlock back buffer, hr %#lx.\n", hr);
+
+ hr = IMFMediaBuffer_Lock(buffer, &data, NULL, &length);
+ ok(hr == S_OK, "Unexpected hr %#lx.\n", hr);
+ ok(length == max_length, "Unexpected length %lu instead of %lu.\n", length, max_length);
+
+ /* You can lock the surface while the media buffer is locked. */
+ hr = IDirect3DSurface9_LockRect(backbuffer, &locked_rect, NULL, 0);
+ ok(hr == S_OK, "Failed to lock back buffer, hr %#lx.\n", hr);
+
hr = IMFMediaBuffer_Lock(buffer, &data, NULL, &length);
ok(hr == S_OK, "Unexpected hr %#lx.\n", hr);
- ok(length == max_length, "Unexpected length.\n");
+
+ hr = IMFMediaBuffer_Unlock(buffer);
+ ok(hr == S_OK, "Unexpected hr %#lx.\n", hr);
+
+ hr = IDirect3DSurface9_UnlockRect(backbuffer);
+ ok(hr == S_OK, "Failed to unlock back buffer, hr %#lx.\n", hr);
/* Unlock twice. */
hr = IMFMediaBuffer_Unlock(buffer);
--
2.36.1
June 14, 2022
[PATCH v2 2/8] mfplat/buffer: Fix image copy function for IMC2/IMC4 buffers with odd height.
by Giovanni Mascellani
Signed-off-by: Giovanni Mascellani <gmascellani(a)codeweavers.com>
---
dlls/mfplat/buffer.c | 3 +--
dlls/mfplat/tests/mfplat.c | 9 ++++-----
2 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/dlls/mfplat/buffer.c b/dlls/mfplat/buffer.c
index 39407ccc9e2..a7ba306223d 100644
--- a/dlls/mfplat/buffer.c
+++ b/dlls/mfplat/buffer.c
@@ -100,8 +100,7 @@ static void copy_image_imc1(BYTE *dest, LONG dest_stride, const BYTE *src, LONG
static void copy_image_imc2(BYTE *dest, LONG dest_stride, const BYTE *src, LONG src_stride, DWORD width, DWORD lines)
{
- MFCopyImage(dest, dest_stride, src, src_stride, width / 2, lines / 2);
- MFCopyImage(dest + dest_stride / 2, dest_stride, src + src_stride / 2, src_stride, width / 2, lines / 2);
+ MFCopyImage(dest, dest_stride / 2, src, src_stride / 2, width / 2, lines);
}
static inline struct buffer *impl_from_IMFMediaBuffer(IMFMediaBuffer *iface)
diff --git a/dlls/mfplat/tests/mfplat.c b/dlls/mfplat/tests/mfplat.c
index 1b5e8cf7ed5..52608c05929 100644
--- a/dlls/mfplat/tests/mfplat.c
+++ b/dlls/mfplat/tests/mfplat.c
@@ -6027,12 +6027,11 @@ static void test_MFCreate2DMediaBuffer(void)
case MAKEFOURCC('I','M','C','2'):
case MAKEFOURCC('I','M','C','4'):
- for (j = ptr->height; j < length2 / stride; j++)
+ for (j = 0; ptr->height * stride + j * (stride / 2) < length2; j++)
for (k = 0; k < ptr->width / 2; k++)
- ok(data[j * pitch + k] == 0xff, "Unexpected byte %02x at test %d row %d column %d.\n", data[j * pitch + k], i, j, k);
- for (j = ptr->height; j < length2 / stride; j++)
- for (k = pitch / 2; k < pitch / 2 + ptr->width / 2; k++)
- ok(data[j * pitch + k] == 0xff, "Unexpected byte %02x at test %d row %d column %d.\n", data[j * pitch + k], i, j, k);
+ ok(data[ptr->height * pitch + j * (pitch / 2) + k] == 0xff,
+ "Unexpected byte %02x at test %d row %d column %d.\n",
+ data[ptr->height * pitch + j * (pitch / 2) + k], i, j, k);
break;
case MAKEFOURCC('N','V','1','2'):
--
2.36.1
June 14, 2022
[PATCH v2 1/8] mfplat/buffer: Fix size for IMC2/IMC4 buffers with odd height.
by Giovanni Mascellani
Signed-off-by: Giovanni Mascellani <gmascellani(a)codeweavers.com>
---
v2:
* Remove the multiplier
* The missing test cases will be reinsterted in a later commit
---
dlls/mfplat/buffer.c | 22 ++++++++++++++++++---
dlls/mfplat/tests/mfplat.c | 40 ++++++++++++++++----------------------
2 files changed, 36 insertions(+), 26 deletions(-)
diff --git a/dlls/mfplat/buffer.c b/dlls/mfplat/buffer.c
index eada3df18ad..39407ccc9e2 100644
--- a/dlls/mfplat/buffer.c
+++ b/dlls/mfplat/buffer.c
@@ -1351,8 +1351,25 @@ static HRESULT create_2d_buffer(DWORD width, DWORD height, DWORD fourcc, BOOL bo
if (is_yuv && bottom_up)
return MF_E_INVALIDMEDIATYPE;
- if (FAILED(hr = MFGetPlaneSize(fourcc, width, height, &plane_size)))
- return hr;
+ switch (fourcc)
+ {
+ case MAKEFOURCC('I','M','C','1'):
+ case MAKEFOURCC('I','M','C','3'):
+ plane_size = stride * height * 2;
+ break;
+ case MAKEFOURCC('I','M','C','2'):
+ case MAKEFOURCC('I','M','C','4'):
+ plane_size = stride * 3 / 2 * height;
+ break;
+ case MAKEFOURCC('N','V','1','2'):
+ case MAKEFOURCC('Y','V','1','2'):
+ case MAKEFOURCC('I','4','2','0'):
+ case MAKEFOURCC('I','Y','U','V'):
+ plane_size = stride * height * 3 / 2;
+ break;
+ default:
+ plane_size = stride * height;
+ }
if (!(object = calloc(1, sizeof(*object))))
return E_OUTOFMEMORY;
@@ -1377,7 +1394,6 @@ static HRESULT create_2d_buffer(DWORD width, DWORD height, DWORD fourcc, BOOL bo
case MAKEFOURCC('I','M','C','1'):
case MAKEFOURCC('I','M','C','3'):
max_length = pitch * height * 2;
- plane_size *= 2;
break;
case MAKEFOURCC('N','V','1','2'):
case MAKEFOURCC('Y','V','1','2'):
diff --git a/dlls/mfplat/tests/mfplat.c b/dlls/mfplat/tests/mfplat.c
index 28b89de4b1f..1b5e8cf7ed5 100644
--- a/dlls/mfplat/tests/mfplat.c
+++ b/dlls/mfplat/tests/mfplat.c
@@ -5723,48 +5723,49 @@ static void test_MFCreate2DMediaBuffer(void)
unsigned int fourcc;
unsigned int contiguous_length;
int pitch;
- unsigned int plane_multiplier;
unsigned int max_length;
} _2d_buffer_tests[] =
{
- { 2, 2, MAKEFOURCC('N','V','1','2'), 6, 64, 0, 192 },
+ { 2, 2, MAKEFOURCC('N','V','1','2'), 6, 64, 192 },
{ 4, 2, MAKEFOURCC('N','V','1','2'), 12, 64 },
{ 2, 4, MAKEFOURCC('N','V','1','2'), 12, 64 },
{ 1, 3, MAKEFOURCC('N','V','1','2'), 4, 64 },
- { 4, 16, MAKEFOURCC('N','V','1','2'), 96, 64, 0, 1536 },
+ { 4, 16, MAKEFOURCC('N','V','1','2'), 96, 64, 1536 },
- { 2, 2, MAKEFOURCC('I','M','C','2'), 6, 128, 0, 384 },
+ { 2, 2, MAKEFOURCC('I','M','C','2'), 6, 128, 384 },
{ 4, 2, MAKEFOURCC('I','M','C','2'), 12, 128 },
{ 2, 4, MAKEFOURCC('I','M','C','2'), 12, 128 },
+ { 3, 5, MAKEFOURCC('I','M','C','2'), 20, 128 },
{ 2, 2, MAKEFOURCC('I','M','C','4'), 6, 128 },
{ 4, 2, MAKEFOURCC('I','M','C','4'), 12, 128 },
{ 2, 4, MAKEFOURCC('I','M','C','4'), 12, 128 },
+ { 3, 5, MAKEFOURCC('I','M','C','4'), 20, 128 },
- { 4, 2, MAKEFOURCC('I','M','C','1'), 32, 128, 2 },
- { 4, 4, MAKEFOURCC('I','M','C','1'), 64, 128, 2 },
- { 4, 16, MAKEFOURCC('I','M','C','1'), 256, 128, 2, 4096 },
- { 4, 20, MAKEFOURCC('I','M','C','1'), 320, 128, 2 },
+ { 4, 2, MAKEFOURCC('I','M','C','1'), 32, 128 },
+ { 4, 4, MAKEFOURCC('I','M','C','1'), 64, 128 },
+ { 4, 16, MAKEFOURCC('I','M','C','1'), 256, 128, 4096 },
+ { 4, 20, MAKEFOURCC('I','M','C','1'), 320, 128 },
- { 4, 2, MAKEFOURCC('I','M','C','3'), 32, 128, 2 },
- { 4, 4, MAKEFOURCC('I','M','C','3'), 64, 128, 2 },
- { 4, 16, MAKEFOURCC('I','M','C','3'), 256, 128, 2, 4096 },
- { 4, 20, MAKEFOURCC('I','M','C','3'), 320, 128, 2 },
+ { 4, 2, MAKEFOURCC('I','M','C','3'), 32, 128 },
+ { 4, 4, MAKEFOURCC('I','M','C','3'), 64, 128 },
+ { 4, 16, MAKEFOURCC('I','M','C','3'), 256, 128, 4096 },
+ { 4, 20, MAKEFOURCC('I','M','C','3'), 320, 128 },
{ 4, 2, MAKEFOURCC('Y','V','1','2'), 12, 128 },
{ 4, 4, MAKEFOURCC('Y','V','1','2'), 24, 128 },
- { 4, 16, MAKEFOURCC('Y','V','1','2'), 96, 128, 0, 3072 },
+ { 4, 16, MAKEFOURCC('Y','V','1','2'), 96, 128, 3072 },
{ 4, 2, MAKEFOURCC('A','Y','U','V'), 32, 64 },
{ 4, 4, MAKEFOURCC('A','Y','U','V'), 64, 64 },
- { 4, 16, MAKEFOURCC('A','Y','U','V'), 256, 64, 0, 1024 },
+ { 4, 16, MAKEFOURCC('A','Y','U','V'), 256, 64, 1024 },
{ 4, 2, MAKEFOURCC('Y','U','Y','2'), 16, 64 },
{ 4, 4, MAKEFOURCC('Y','U','Y','2'), 32, 64 },
- { 4, 16, MAKEFOURCC('Y','U','Y','2'), 128, 64, 0, 1024 },
+ { 4, 16, MAKEFOURCC('Y','U','Y','2'), 128, 64, 1024 },
{ 4, 2, MAKEFOURCC('U','Y','V','Y'), 16, 64 },
{ 4, 4, MAKEFOURCC('U','Y','V','Y'), 32, 64 },
- { 4, 16, MAKEFOURCC('U','Y','V','Y'), 128, 64, 0, 1024 },
+ { 4, 16, MAKEFOURCC('U','Y','V','Y'), 128, 64, 1024 },
{ 2, 4, D3DFMT_A8R8G8B8, 32, 64 },
{ 1, 4, D3DFMT_A8R8G8B8, 16, 64 },
@@ -5998,13 +5999,6 @@ static void test_MFCreate2DMediaBuffer(void)
hr = IMFMediaBuffer_Unlock(buffer);
ok(hr == S_OK, "Failed to unlock buffer, hr %#lx.\n", hr);
- hr = pMFGetPlaneSize(ptr->fourcc, ptr->width, ptr->height, &length2);
- ok(hr == S_OK, "Failed to get plane size, hr %#lx.\n", hr);
- if (ptr->plane_multiplier)
- length2 *= ptr->plane_multiplier;
- ok(length2 == length, "%d: contiguous length %lu does not match plane size %lu, %u x %u, format %s.\n", i, length,
- length2, ptr->width, ptr->height, wine_dbgstr_an((char *)&ptr->fourcc, 4));
-
hr = IMF2DBuffer_Lock2D(_2dbuffer, &data, &pitch);
ok(hr == S_OK, "Failed to lock buffer, hr %#lx.\n", hr);
--
2.36.1
June 14, 2022
Re: Gitlab experiment status
by Bernhard Kölbl
Just noticed this:
When you resolve a thread, GitLab will automatically collapse it, but
this does not apply to messages from the ML bridge.
E.g: https://gitlab.winehq.org/wine/wine/-/merge_requests/217#note_1902
Would be a nice to have feature / fix.
--
Bernhard
Am Di., 24. Mai 2022 um 11:12 Uhr schrieb Alexandre Julliard
<julliard(a)winehq.org>:
>
> Folks,
>
> The Gitlab experiment seems to be going well. For the last release, more
> than half the patches were submitted as Gitlab merge requests, so that
> seems to be working well for us.
>
> There are still improvements we can make, and of course many more
> Gitlab features that we could start using, but before investing more
> effort we need to decide whether we want to use it going forward.
>
> So now that you have had a chance to try it, what do you people think?
> Should we adopt Gitlab as our development platform?
>
> --
> Alexandre Julliard
> julliard(a)winehq.org
>
June 14, 2022
[PATCH v5 9/9] windows.media.speech: Add stub ISpeechSynthesisStream iface.
by Bernhard Kölbl
From: Bernhard Kölbl <besentv(a)gmail.com>
Based on a patch by: Connor McAdams <cmcadams(a)codeweavers.com>
Silences a warning about narrator being broken in Forza Horizon 5.
Signed-off-by: Bernhard Kölbl <besentv(a)gmail.com>
---
dlls/windows.media.speech/synthesizer.c | 142 ++++++++++++++++++++++-
dlls/windows.media.speech/tests/speech.c | 37 +++---
2 files changed, 153 insertions(+), 26 deletions(-)
diff --git a/dlls/windows.media.speech/synthesizer.c b/dlls/windows.media.speech/synthesizer.c
index 7e1d19cb4c1..ce257c7c355 100644
--- a/dlls/windows.media.speech/synthesizer.c
+++ b/dlls/windows.media.speech/synthesizer.c
@@ -146,6 +146,140 @@ static struct voice_information_vector all_voices =
0
};
+/*
+ *
+ * ISpeechSynthesisStream
+ *
+ */
+
+struct synthesis_stream
+{
+ ISpeechSynthesisStream ISpeechSynthesisStream_iface;
+ LONG ref;
+
+ IVector_IMediaMarker *markers;
+};
+
+static inline struct synthesis_stream *impl_from_ISpeechSynthesisStream( ISpeechSynthesisStream *iface )
+{
+ return CONTAINING_RECORD(iface, struct synthesis_stream, ISpeechSynthesisStream_iface);
+}
+
+HRESULT WINAPI synthesis_stream_QueryInterface( ISpeechSynthesisStream *iface, REFIID iid, void **out )
+{
+ struct synthesis_stream *impl = impl_from_ISpeechSynthesisStream(iface);
+
+ TRACE("iface %p, iid %s, out %p stub!\n", iface, debugstr_guid(iid), out);
+
+ if (IsEqualGUID(iid, &IID_IUnknown) ||
+ IsEqualGUID(iid, &IID_IInspectable) ||
+ IsEqualGUID(iid, &IID_IAgileObject) ||
+ IsEqualGUID(iid, &IID_ISpeechSynthesisStream))
+ {
+ IInspectable_AddRef((*out = &impl->ISpeechSynthesisStream_iface));
+ return S_OK;
+ }
+
+ FIXME("%s not implemented, returning E_NOINTERFACE.\n", debugstr_guid(iid));
+ *out = NULL;
+ return E_NOINTERFACE;
+}
+
+ULONG WINAPI synthesis_stream_AddRef( ISpeechSynthesisStream *iface )
+{
+ struct synthesis_stream *impl = impl_from_ISpeechSynthesisStream(iface);
+ ULONG ref = InterlockedIncrement(&impl->ref);
+ TRACE("iface %p, ref %lu.\n", iface, ref);
+ return ref;
+}
+
+ULONG WINAPI synthesis_stream_Release( ISpeechSynthesisStream *iface )
+{
+ struct synthesis_stream *impl = impl_from_ISpeechSynthesisStream(iface);
+ ULONG ref = InterlockedDecrement(&impl->ref);
+
+ TRACE("iface %p, ref %lu.\n", iface, ref);
+
+ if (!ref)
+ free(impl);
+
+ return ref;
+}
+
+HRESULT WINAPI synthesis_stream_GetIids( ISpeechSynthesisStream *iface, ULONG *iid_count, IID **iids )
+{
+ FIXME("iface %p, iid_count %p, iids %p stub.\n", iface, iid_count, iids);
+ return E_NOTIMPL;
+}
+
+HRESULT WINAPI synthesis_stream_GetRuntimeClassName( ISpeechSynthesisStream *iface, HSTRING *class_name )
+{
+ FIXME("iface %p, class_name %p stub.\n", iface, class_name);
+ return E_NOTIMPL;
+}
+
+HRESULT WINAPI synthesis_stream_GetTrustLevel( ISpeechSynthesisStream *iface, TrustLevel *trust_level )
+{
+ FIXME("iface %p, trust_level %p stub.\n", iface, trust_level);
+ return E_NOTIMPL;
+}
+
+HRESULT WINAPI synthesis_stream_get_Markers( ISpeechSynthesisStream *iface, IVectorView_IMediaMarker **value )
+{
+ struct synthesis_stream *impl = impl_from_ISpeechSynthesisStream(iface);
+ FIXME("iface %p, value %p stub!\n", iface, value);
+ return IVector_IMediaMarker_GetView(impl->markers, value);
+}
+
+static const struct ISpeechSynthesisStreamVtbl synthesis_stream_vtbl =
+{
+ /* IUnknown methods */
+ synthesis_stream_QueryInterface,
+ synthesis_stream_AddRef,
+ synthesis_stream_Release,
+ /* IInspectable methods */
+ synthesis_stream_GetIids,
+ synthesis_stream_GetRuntimeClassName,
+ synthesis_stream_GetTrustLevel,
+ /* ISpeechSynthesisStream methods */
+ synthesis_stream_get_Markers
+};
+
+
+static HRESULT synthesis_stream_create( ISpeechSynthesisStream **out )
+{
+ struct synthesis_stream *impl;
+ struct vector_iids markers_iids =
+ {
+ .iterable = &IID_IIterable_IMediaMarker,
+ .iterator = &IID_IIterator_IMediaMarker,
+ .vector = &IID_IVector_IMediaMarker,
+ .view = &IID_IVectorView_IMediaMarker,
+ };
+ HRESULT hr;
+
+ TRACE("out %p.\n", out);
+
+ if (!(impl = calloc(1, sizeof(*impl))))
+ {
+ *out = NULL;
+ return E_OUTOFMEMORY;
+ }
+
+ impl->ISpeechSynthesisStream_iface.lpVtbl = &synthesis_stream_vtbl;
+ impl->ref = 1;
+ if (FAILED(hr = vector_inspectable_create(&markers_iids, (IVector_IInspectable**)&impl->markers)))
+ goto error;
+
+ TRACE("created ISpeechSynthesisStream %p.\n", impl);
+ *out = &impl->ISpeechSynthesisStream_iface;
+ return S_OK;
+
+error:
+ free(impl);
+ return hr;
+}
+
/*
*
* SpeechSynthesizer runtimeclass
@@ -243,26 +377,26 @@ static HRESULT WINAPI synthesizer_GetTrustLevel( ISpeechSynthesizer *iface, Trus
static HRESULT CALLBACK text_to_stream_operation( IInspectable *invoker, IInspectable **result )
{
- return S_OK;
+ return synthesis_stream_create((ISpeechSynthesisStream **)result);
}
static HRESULT WINAPI synthesizer_SynthesizeTextToStreamAsync( ISpeechSynthesizer *iface, HSTRING text,
IAsyncOperation_SpeechSynthesisStream **operation )
{
- FIXME("iface %p, text %p, operation %p stub.\n", iface, text, operation);
+ TRACE("iface %p, text %p, operation %p.\n", iface, text, operation);
return async_operation_inspectable_create(&IID_IAsyncOperation_SpeechSynthesisStream, NULL,
text_to_stream_operation, (IAsyncOperation_IInspectable **)operation);
}
static HRESULT CALLBACK ssml_to_stream_operation( IInspectable *invoker, IInspectable **result )
{
- return S_OK;
+ return synthesis_stream_create((ISpeechSynthesisStream **)result);
}
static HRESULT WINAPI synthesizer_SynthesizeSsmlToStreamAsync( ISpeechSynthesizer *iface, HSTRING ssml,
IAsyncOperation_SpeechSynthesisStream **operation )
{
- FIXME("iface %p, text %p, operation %p stub.\n", iface, ssml, operation);
+ TRACE("iface %p, ssml %p, operation %p.\n", iface, ssml, operation);
return async_operation_inspectable_create(&IID_IAsyncOperation_SpeechSynthesisStream, NULL,
ssml_to_stream_operation, (IAsyncOperation_IInspectable **)operation);
}
diff --git a/dlls/windows.media.speech/tests/speech.c b/dlls/windows.media.speech/tests/speech.c
index 6d0b09f3ebf..ceb1b7ade88 100644
--- a/dlls/windows.media.speech/tests/speech.c
+++ b/dlls/windows.media.speech/tests/speech.c
@@ -947,22 +947,19 @@ static void test_SpeechSynthesizer(void)
check_interface(operation_ss_stream, &IID_IAgileObject, TRUE);
hr = IAsyncOperation_SpeechSynthesisStream_GetResults(operation_ss_stream, &ss_stream);
- todo_wine ok(hr == S_OK, "IAsyncOperation_SpeechSynthesisStream_GetResults failed, hr %#lx\n", hr);
+ ok(hr == S_OK, "IAsyncOperation_SpeechSynthesisStream_GetResults failed, hr %#lx\n", hr);
- if (hr == S_OK)
- {
- hr = ISpeechSynthesisStream_get_Markers(ss_stream, &media_markers);
- todo_wine ok(hr == S_OK, "ISpeechSynthesisStream_get_Markers failed, hr %#lx\n", hr);
- check_interface(media_markers, &IID_IVectorView_IMediaMarker, TRUE);
- check_interface(media_markers, &IID_IIterable_IMediaMarker, TRUE);
- check_interface(media_markers, &IID_IAgileObject, TRUE);
+ hr = ISpeechSynthesisStream_get_Markers(ss_stream, &media_markers);
+ ok(hr == S_OK, "ISpeechSynthesisStream_get_Markers failed, hr %#lx\n", hr);
+ check_interface(media_markers, &IID_IVectorView_IMediaMarker, TRUE);
+ check_interface(media_markers, &IID_IIterable_IMediaMarker, TRUE);
+ check_interface(media_markers, &IID_IAgileObject, TRUE);
- ref = IVectorView_IMediaMarker_Release(media_markers);
- todo_wine ok(ref == 0, "Got unexpected ref %lu.\n", ref);
+ ref = IVectorView_IMediaMarker_Release(media_markers);
+ ok(ref == 0, "Got unexpected ref %lu.\n", ref);
- ref = ISpeechSynthesisStream_Release(ss_stream);
- todo_wine ok(ref == 0, "Got unexpected ref %lu.\n", ref);
- }
+ ref = ISpeechSynthesisStream_Release(ss_stream);
+ ok(ref == 0, "Got unexpected ref %lu.\n", ref);
IAsyncOperation_SpeechSynthesisStream_Release(operation_ss_stream);
@@ -981,16 +978,12 @@ static void test_SpeechSynthesizer(void)
check_interface(operation_ss_stream, &IID_IAgileObject, TRUE);
hr = IAsyncOperation_SpeechSynthesisStream_GetResults(operation_ss_stream, &ss_stream);
- todo_wine ok(hr == S_OK, "IAsyncOperation_SpeechSynthesisStream_GetResults failed, hr %#lx\n", hr);
+ ok(hr == S_OK, "IAsyncOperation_SpeechSynthesisStream_GetResults failed, hr %#lx\n", hr);
+ check_interface(ss_stream, &IID_ISpeechSynthesisStream, TRUE);
+ check_interface(ss_stream, &IID_IAgileObject, TRUE);
- if (hr == S_OK)
- {
- check_interface(ss_stream, &IID_ISpeechSynthesisStream, TRUE);
- check_interface(ss_stream, &IID_IAgileObject, TRUE);
-
- ref = ISpeechSynthesisStream_Release(ss_stream);
- ok(ref == 0, "Got unexpected ref %lu.\n", ref);
- }
+ ref = ISpeechSynthesisStream_Release(ss_stream);
+ ok(ref == 0, "Got unexpected ref %lu.\n", ref);
IAsyncOperation_SpeechSynthesisStream_Release(operation_ss_stream);
--
GitLab
https://gitlab.winehq.org/wine/wine/-/merge_requests/217
June 14, 2022
[PATCH v5 8/9] windows.media.speech: Return IAsyncOperation from synthesizer_SynthesizeSsmlToStreamAsync.
by Bernhard Kölbl
From: Bernhard Kölbl <besentv(a)gmail.com>
Based on a patch by: Connor McAdams <cmcadams(a)codeweavers.com>
Signed-off-by: Bernhard Kölbl <besentv(a)gmail.com>
---
dlls/windows.media.speech/synthesizer.c | 8 +++++++-
dlls/windows.media.speech/tests/speech.c | 16 +++++++---------
2 files changed, 14 insertions(+), 10 deletions(-)
diff --git a/dlls/windows.media.speech/synthesizer.c b/dlls/windows.media.speech/synthesizer.c
index 3a77fc62234..7e1d19cb4c1 100644
--- a/dlls/windows.media.speech/synthesizer.c
+++ b/dlls/windows.media.speech/synthesizer.c
@@ -254,11 +254,17 @@ static HRESULT WINAPI synthesizer_SynthesizeTextToStreamAsync( ISpeechSynthesize
text_to_stream_operation, (IAsyncOperation_IInspectable **)operation);
}
+static HRESULT CALLBACK ssml_to_stream_operation( IInspectable *invoker, IInspectable **result )
+{
+ return S_OK;
+}
+
static HRESULT WINAPI synthesizer_SynthesizeSsmlToStreamAsync( ISpeechSynthesizer *iface, HSTRING ssml,
IAsyncOperation_SpeechSynthesisStream **operation )
{
FIXME("iface %p, text %p, operation %p stub.\n", iface, ssml, operation);
- return E_NOTIMPL;
+ return async_operation_inspectable_create(&IID_IAsyncOperation_SpeechSynthesisStream, NULL,
+ ssml_to_stream_operation, (IAsyncOperation_IInspectable **)operation);
}
static HRESULT WINAPI synthesizer_put_Voice( ISpeechSynthesizer *iface, IVoiceInformation *value )
diff --git a/dlls/windows.media.speech/tests/speech.c b/dlls/windows.media.speech/tests/speech.c
index df5341d3142..6d0b09f3ebf 100644
--- a/dlls/windows.media.speech/tests/speech.c
+++ b/dlls/windows.media.speech/tests/speech.c
@@ -971,8 +971,7 @@ static void test_SpeechSynthesizer(void)
ok(hr == S_OK, "WindowsCreateString failed, hr %#lx\n", hr);
hr = ISpeechSynthesizer_SynthesizeSsmlToStreamAsync(synthesizer, str2, &operation_ss_stream);
- todo_wine ok(hr == S_OK, "ISpeechSynthesizer_SynthesizeSsmlToStreamAsync failed, hr %#lx\n", hr);
- if(FAILED(hr)) goto skip_ss_stream;
+ ok(hr == S_OK, "ISpeechSynthesizer_SynthesizeSsmlToStreamAsync failed, hr %#lx\n", hr);
await_async_inspectable((IAsyncOperation_IInspectable *)operation_ss_stream,
&async_inspectable_handler,
@@ -998,28 +997,27 @@ static void test_SpeechSynthesizer(void)
operation_ss_stream = (void *)0xdeadbeef;
hr = ISpeechSynthesizer_SynthesizeSsmlToStreamAsync(synthesizer, NULL, &operation_ss_stream);
/* Broken on Win 8 + 8.1 */
- todo_wine ok(hr == S_OK || broken(hr == E_INVALIDARG), "ISpeechSynthesizer_SynthesizeSsmlToStreamAsync failed, hr %#lx\n", hr);
+ ok(hr == S_OK || broken(hr == E_INVALIDARG), "ISpeechSynthesizer_SynthesizeSsmlToStreamAsync failed, hr %#lx\n", hr);
if (hr == S_OK)
{
- todo_wine ok(!!operation_ss_stream, "operation_ss_stream had value %p.\n", operation_ss_stream);
+ ok(!!operation_ss_stream, "operation_ss_stream had value %p.\n", operation_ss_stream);
IAsyncOperation_SpeechSynthesisStream_Release(operation_ss_stream);
}
- else todo_wine ok(operation_ss_stream == NULL, "operation_ss_stream had value %p.\n", operation_ss_stream);
+ else ok(operation_ss_stream == NULL, "operation_ss_stream had value %p.\n", operation_ss_stream);
operation_ss_stream = (void *)0xdeadbeef;
hr = ISpeechSynthesizer_SynthesizeSsmlToStreamAsync(synthesizer, str, &operation_ss_stream);
/* Broken on Win 8 + 8.1 */
- todo_wine ok(hr == S_OK || broken(hr == SPERR_WINRT_INCORRECT_FORMAT), "ISpeechSynthesizer_SynthesizeSsmlToStreamAsync failed, hr %#lx\n", hr);
+ ok(hr == S_OK || broken(hr == SPERR_WINRT_INCORRECT_FORMAT), "ISpeechSynthesizer_SynthesizeSsmlToStreamAsync failed, hr %#lx\n", hr);
if (hr == S_OK)
{
- todo_wine ok(!!operation_ss_stream, "operation_ss_stream had value %p.\n", operation_ss_stream);
+ ok(!!operation_ss_stream, "operation_ss_stream had value %p.\n", operation_ss_stream);
IAsyncOperation_SpeechSynthesisStream_Release(operation_ss_stream);
}
- else todo_wine ok(operation_ss_stream == NULL, "operation_ss_stream had value %p.\n", operation_ss_stream);
+ else ok(operation_ss_stream == NULL, "operation_ss_stream had value %p.\n", operation_ss_stream);
-skip_ss_stream:
WindowsDeleteString(str2);
WindowsDeleteString(str);
--
GitLab
https://gitlab.winehq.org/wine/wine/-/merge_requests/217
June 14, 2022
[PATCH v5 7/9] windows.media.speech: Return IAsyncOperation from synthesizer_SynthesizeTextToStreamAsync.
by Bernhard Kölbl
From: Bernhard Kölbl <besentv(a)gmail.com>
Based on a patch by: Connor McAdams <cmcadams(a)codeweavers.com>
Signed-off-by: Bernhard Kölbl <besentv(a)gmail.com>
---
dlls/windows.media.speech/synthesizer.c | 8 +++++++-
dlls/windows.media.speech/tests/speech.c | 11 +++++------
2 files changed, 12 insertions(+), 7 deletions(-)
diff --git a/dlls/windows.media.speech/synthesizer.c b/dlls/windows.media.speech/synthesizer.c
index e8c9f0a280d..3a77fc62234 100644
--- a/dlls/windows.media.speech/synthesizer.c
+++ b/dlls/windows.media.speech/synthesizer.c
@@ -241,11 +241,17 @@ static HRESULT WINAPI synthesizer_GetTrustLevel( ISpeechSynthesizer *iface, Trus
return E_NOTIMPL;
}
+static HRESULT CALLBACK text_to_stream_operation( IInspectable *invoker, IInspectable **result )
+{
+ return S_OK;
+}
+
static HRESULT WINAPI synthesizer_SynthesizeTextToStreamAsync( ISpeechSynthesizer *iface, HSTRING text,
IAsyncOperation_SpeechSynthesisStream **operation )
{
FIXME("iface %p, text %p, operation %p stub.\n", iface, text, operation);
- return E_NOTIMPL;
+ return async_operation_inspectable_create(&IID_IAsyncOperation_SpeechSynthesisStream, NULL,
+ text_to_stream_operation, (IAsyncOperation_IInspectable **)operation);
}
static HRESULT WINAPI synthesizer_SynthesizeSsmlToStreamAsync( ISpeechSynthesizer *iface, HSTRING ssml,
diff --git a/dlls/windows.media.speech/tests/speech.c b/dlls/windows.media.speech/tests/speech.c
index ef43eb77317..df5341d3142 100644
--- a/dlls/windows.media.speech/tests/speech.c
+++ b/dlls/windows.media.speech/tests/speech.c
@@ -933,13 +933,11 @@ static void test_SpeechSynthesizer(void)
ok(hr == S_OK, "WindowsCreateString failed, hr %#lx\n", hr);
hr = ISpeechSynthesizer_SynthesizeTextToStreamAsync(synthesizer, NULL, &operation_ss_stream);
- todo_wine ok(hr == S_OK, "ISpeechSynthesizer_SynthesizeTextToStreamAsync failed, hr %#lx\n", hr);
- if(FAILED(hr)) goto skip_ss_stream;
-
+ ok(hr == S_OK, "ISpeechSynthesizer_SynthesizeTextToStreamAsync failed, hr %#lx\n", hr);
IAsyncOperation_SpeechSynthesisStream_Release(operation_ss_stream);
hr = ISpeechSynthesizer_SynthesizeTextToStreamAsync(synthesizer, str, &operation_ss_stream);
- todo_wine ok(hr == S_OK, "ISpeechSynthesizer_SynthesizeTextToStreamAsync failed, hr %#lx\n", hr);
+ ok(hr == S_OK, "ISpeechSynthesizer_SynthesizeTextToStreamAsync failed, hr %#lx\n", hr);
await_async_inspectable((IAsyncOperation_IInspectable *)operation_ss_stream,
&async_inspectable_handler,
@@ -974,6 +972,8 @@ static void test_SpeechSynthesizer(void)
hr = ISpeechSynthesizer_SynthesizeSsmlToStreamAsync(synthesizer, str2, &operation_ss_stream);
todo_wine ok(hr == S_OK, "ISpeechSynthesizer_SynthesizeSsmlToStreamAsync failed, hr %#lx\n", hr);
+ if(FAILED(hr)) goto skip_ss_stream;
+
await_async_inspectable((IAsyncOperation_IInspectable *)operation_ss_stream,
&async_inspectable_handler,
&IID_IAsyncOperationCompletedHandler_SpeechSynthesisStream);
@@ -1019,9 +1019,8 @@ static void test_SpeechSynthesizer(void)
}
else todo_wine ok(operation_ss_stream == NULL, "operation_ss_stream had value %p.\n", operation_ss_stream);
- WindowsDeleteString(str2);
-
skip_ss_stream:
+ WindowsDeleteString(str2);
WindowsDeleteString(str);
hr = IInspectable_QueryInterface(inspectable, &IID_IClosable, (void **)&closable);
--
GitLab
https://gitlab.winehq.org/wine/wine/-/merge_requests/217
June 14, 2022