From 817424320354a4d665867fc8b226531e4f1818aa Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sat, 9 Oct 2021 13:49:52 +1100 Subject: [PATCH] Reenabled mfplat patchset --- ...amer-Get-rid-of-the-WMReader-typedef.patch | 1945 +++++++++++++++++ ...ove-the-async-reader-implementation-.patch | 168 ++ ...amer-Get-rid-of-the-WMSyncReader-typ.patch | 579 +++++ ...ove-the-sync-reader-implementation-t.patch | 161 ++ ...amer-Translate-GST_AUDIO_CHANNEL_POS.patch | 30 + ...mer-Trace-the-unfiltered-caps-in-si.patch} | 4 +- ...mer-Avoid-seeking-past-the-end-of-a.patch} | 4 +- ...mer-Avoid-passing-a-NULL-buffer-to-.patch} | 4 +- ...mer-Use-array_reserve-to-reallocate.patch} | 4 +- ...mer-Handle-zero-length-reads-in-src.patch} | 4 +- ...mer-Convert-the-Unix-library-to-the.patch} | 4 +- ...mer-Return-void-from-wg_parser_stre.patch} | 4 +- ...mer-Move-Unix-library-definitions-i.patch} | 4 +- ...mer-Remove-the-no-longer-used-start.patch} | 4 +- ...mer-Set-unlimited-buffering-using-a.patch} | 4 +- ...mer-Initialize-GStreamer-in-wg_pars.patch} | 4 +- ...mer-Use-a-single-wg_parser_create-e.patch} | 4 +- ...mer-Fix-return-code-in-init_gst-fai.patch} | 4 +- ...mer-Allocate-source-media-buffers-i.patch} | 4 +- ...mer-Duplicate-source-shutdown-path-.patch} | 4 +- ...mer-Properly-clean-up-from-failure-.patch} | 4 +- ...mer-Factor-out-more-of-the-init_gst.patch} | 4 +- patches/mfplat-reverts/definition | 1 - patches/mfplat-streaming-support/definition | 1 - patches/patchinstall.sh | 106 +- staging/patchutils.py | 3 +- 26 files changed, 3024 insertions(+), 38 deletions(-) create mode 100644 patches/mfplat-reverts/0001-Revert-winegstreamer-Get-rid-of-the-WMReader-typedef.patch create mode 100644 patches/mfplat-reverts/0002-Revert-wmvcore-Move-the-async-reader-implementation-.patch create mode 100644 patches/mfplat-reverts/0003-Revert-winegstreamer-Get-rid-of-the-WMSyncReader-typ.patch create mode 100644 patches/mfplat-reverts/0004-Revert-wmvcore-Move-the-sync-reader-implementation-t.patch create mode 100644 patches/mfplat-reverts/0005-Revert-winegstreamer-Translate-GST_AUDIO_CHANNEL_POS.patch rename patches/mfplat-reverts/{0001-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch => 0006-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch} (89%) rename patches/mfplat-reverts/{0002-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch => 0007-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch} (88%) rename patches/mfplat-reverts/{0003-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch => 0008-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch} (92%) rename patches/mfplat-reverts/{0004-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch => 0009-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch} (96%) rename patches/mfplat-reverts/{0005-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch => 0010-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch} (92%) rename patches/mfplat-reverts/{0006-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch => 0011-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch} (99%) rename patches/mfplat-reverts/{0007-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch => 0012-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch} (96%) rename patches/mfplat-reverts/{0008-Revert-winegstreamer-Move-Unix-library-definitions-i.patch => 0013-Revert-winegstreamer-Move-Unix-library-definitions-i.patch} (98%) rename patches/mfplat-reverts/{0009-Revert-winegstreamer-Remove-the-no-longer-used-start.patch => 0014-Revert-winegstreamer-Remove-the-no-longer-used-start.patch} (87%) rename patches/mfplat-reverts/{0010-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch => 0015-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch} (98%) rename patches/mfplat-reverts/{0011-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch => 0016-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch} (95%) rename patches/mfplat-reverts/{0012-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch => 0017-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch} (98%) rename patches/mfplat-reverts/{0013-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch => 0018-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch} (85%) rename patches/mfplat-reverts/{0014-Revert-winegstreamer-Allocate-source-media-buffers-i.patch => 0019-Revert-winegstreamer-Allocate-source-media-buffers-i.patch} (98%) rename patches/mfplat-reverts/{0015-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch => 0020-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch} (98%) rename patches/mfplat-reverts/{0016-Revert-winegstreamer-Properly-clean-up-from-failure-.patch => 0021-Revert-winegstreamer-Properly-clean-up-from-failure-.patch} (97%) rename patches/mfplat-reverts/{0017-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch => 0022-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch} (97%) diff --git a/patches/mfplat-reverts/0001-Revert-winegstreamer-Get-rid-of-the-WMReader-typedef.patch b/patches/mfplat-reverts/0001-Revert-winegstreamer-Get-rid-of-the-WMReader-typedef.patch new file mode 100644 index 00000000..8c4faf0b --- /dev/null +++ b/patches/mfplat-reverts/0001-Revert-winegstreamer-Get-rid-of-the-WMReader-typedef.patch @@ -0,0 +1,1945 @@ +From 587ce9ff24747b30b2a48020a8671d6fd142b110 Mon Sep 17 00:00:00 2001 +From: Alistair Leslie-Hughes +Date: Sat, 9 Oct 2021 13:47:39 +1100 +Subject: [PATCH 01/22] Revert "winegstreamer: Get rid of the WMReader + typedef." + +This reverts commit 2652416be7b3914a98474faa562274c363f1dce8. +--- + dlls/winegstreamer/wm_asyncreader.c | 497 ++++++++++++++-------------- + 1 file changed, 248 insertions(+), 249 deletions(-) + +diff --git a/dlls/winegstreamer/wm_asyncreader.c b/dlls/winegstreamer/wm_asyncreader.c +index b4ef4851c33..d3fd1624f24 100644 +--- a/dlls/winegstreamer/wm_asyncreader.c ++++ b/dlls/winegstreamer/wm_asyncreader.c +@@ -21,8 +21,7 @@ + + WINE_DEFAULT_DEBUG_CHANNEL(wmvcore); + +-struct async_reader +-{ ++typedef struct { + IWMReader IWMReader_iface; + IWMReaderAdvanced6 IWMReaderAdvanced6_iface; + IWMReaderAccelerator IWMReaderAccelerator_iface; +@@ -37,16 +36,16 @@ struct async_reader + IWMProfile3 IWMProfile3_iface; + IWMPacketSize2 IWMPacketSize2_iface; + LONG ref; +-}; ++} WMReader; + +-static struct async_reader *impl_from_IWMReader(IWMReader *iface) ++static inline WMReader *impl_from_IWMReader(IWMReader *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReader_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReader_iface); + } + + static HRESULT WINAPI WMReader_QueryInterface(IWMReader *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + + if(IsEqualGUID(riid, &IID_IUnknown)) { + TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); +@@ -135,7 +134,7 @@ static HRESULT WINAPI WMReader_QueryInterface(IWMReader *iface, REFIID riid, voi + + static ULONG WINAPI WMReader_AddRef(IWMReader *iface) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + LONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); +@@ -145,7 +144,7 @@ static ULONG WINAPI WMReader_AddRef(IWMReader *iface) + + static ULONG WINAPI WMReader_Release(IWMReader *iface) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + LONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); +@@ -158,21 +157,21 @@ static ULONG WINAPI WMReader_Release(IWMReader *iface) + + static HRESULT WINAPI WMReader_Open(IWMReader *iface, const WCHAR *url, IWMReaderCallback *callback, void *context) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)->(%s %p %p)\n", This, debugstr_w(url), callback, context); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_Close(IWMReader *iface) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_GetOutputCount(IWMReader *iface, DWORD *outputs) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)->(%p)\n", This, outputs); + + if(!outputs) +@@ -184,56 +183,56 @@ static HRESULT WINAPI WMReader_GetOutputCount(IWMReader *iface, DWORD *outputs) + + static HRESULT WINAPI WMReader_GetOutputProps(IWMReader *iface, DWORD output_num, IWMOutputMediaProps **output) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)->(%u %p)\n", This, output_num, output); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_SetOutputProps(IWMReader *iface, DWORD output_num, IWMOutputMediaProps *output) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)->(%u %p)\n", This, output_num, output); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_GetOutputFormatCount(IWMReader *iface, DWORD output_num, DWORD *formats) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)->(%u %p)\n", This, output_num, formats); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_GetOutputFormat(IWMReader *iface, DWORD output_num, DWORD format_num, IWMOutputMediaProps **props) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)->(%u %u %p)\n", This, output_num, format_num, props); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_Start(IWMReader *iface, QWORD start, QWORD duration, float rate, void *context) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)->(%s %s %f %p)\n", This, wine_dbgstr_longlong(start), wine_dbgstr_longlong(duration), rate, context); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_Stop(IWMReader *iface) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_Pause(IWMReader *iface) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReader_Resume(IWMReader *iface) + { +- struct async_reader *This = impl_from_IWMReader(iface); ++ WMReader *This = impl_from_IWMReader(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } +@@ -255,60 +254,60 @@ static const IWMReaderVtbl WMReaderVtbl = { + WMReader_Resume + }; + +-static struct async_reader *impl_from_IWMReaderAdvanced6(IWMReaderAdvanced6 *iface) ++static inline WMReader *impl_from_IWMReaderAdvanced6(IWMReaderAdvanced6 *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReaderAdvanced6_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReaderAdvanced6_iface); + } + + static HRESULT WINAPI WMReaderAdvanced_QueryInterface(IWMReaderAdvanced6 *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI WMReaderAdvanced_AddRef(IWMReaderAdvanced6 *iface) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI WMReaderAdvanced_Release(IWMReaderAdvanced6 *iface) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI WMReaderAdvanced_SetUserProvidedClock(IWMReaderAdvanced6 *iface, BOOL user_clock) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%x)\n", This, user_clock); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetUserProvidedClock(IWMReaderAdvanced6 *iface, BOOL *user_clock) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, user_clock); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_DeliverTime(IWMReaderAdvanced6 *iface, QWORD time) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%s)\n", This, wine_dbgstr_longlong(time)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_SetManualStreamSelection(IWMReaderAdvanced6 *iface, BOOL selection) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%x)\n", This, selection); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetManualStreamSelection(IWMReaderAdvanced6 *iface, BOOL *selection) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, selection); + return E_NOTIMPL; + } +@@ -316,7 +315,7 @@ static HRESULT WINAPI WMReaderAdvanced_GetManualStreamSelection(IWMReaderAdvance + static HRESULT WINAPI WMReaderAdvanced_SetStreamsSelected(IWMReaderAdvanced6 *iface, WORD stream_count, + WORD *stream_numbers, WMT_STREAM_SELECTION *selections) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p %p)\n", This, stream_count, stream_numbers, selections); + return E_NOTIMPL; + } +@@ -324,21 +323,21 @@ static HRESULT WINAPI WMReaderAdvanced_SetStreamsSelected(IWMReaderAdvanced6 *if + static HRESULT WINAPI WMReaderAdvanced_GetStreamSelected(IWMReaderAdvanced6 *iface, WORD stream_num, + WMT_STREAM_SELECTION *selection) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, stream_num, selection); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_SetReceiveSelectionCallbacks(IWMReaderAdvanced6 *iface, BOOL get_callbacks) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%x)\n", This, get_callbacks); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetReceiveSelectionCallbacks(IWMReaderAdvanced6 *iface, BOOL *get_callbacks) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, get_callbacks); + return E_NOTIMPL; + } +@@ -346,7 +345,7 @@ static HRESULT WINAPI WMReaderAdvanced_GetReceiveSelectionCallbacks(IWMReaderAdv + static HRESULT WINAPI WMReaderAdvanced_SetReceiveStreamSamples(IWMReaderAdvanced6 *iface, WORD stream_num, + BOOL receive_stream_samples) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %x)\n", This, stream_num, receive_stream_samples); + return E_NOTIMPL; + } +@@ -354,91 +353,91 @@ static HRESULT WINAPI WMReaderAdvanced_SetReceiveStreamSamples(IWMReaderAdvanced + static HRESULT WINAPI WMReaderAdvanced_GetReceiveStreamSamples(IWMReaderAdvanced6 *iface, WORD stream_num, + BOOL *receive_stream_samples) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, stream_num, receive_stream_samples); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_SetAllocateForOutput(IWMReaderAdvanced6 *iface, DWORD output_num, BOOL allocate) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %x)\n", This, output_num, allocate); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetAllocateForOutput(IWMReaderAdvanced6 *iface, DWORD output_num, BOOL *allocate) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, output_num, allocate); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_SetAllocateForStream(IWMReaderAdvanced6 *iface, WORD output_num, BOOL allocate) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %x)\n", This, output_num, allocate); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetAllocateForStream(IWMReaderAdvanced6 *iface, WORD output_num, BOOL *allocate) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, output_num, allocate); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetStatistics(IWMReaderAdvanced6 *iface, WM_READER_STATISTICS *statistics) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, statistics); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_SetClientInfo(IWMReaderAdvanced6 *iface, WM_READER_CLIENTINFO *client_info) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, client_info); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetMaxOutputSampleSize(IWMReaderAdvanced6 *iface, DWORD output, DWORD *max) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, output, max); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_GetMaxStreamSampleSize(IWMReaderAdvanced6 *iface, WORD stream, DWORD *max) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, stream, max); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced_NotifyLateDelivery(IWMReaderAdvanced6 *iface, QWORD lateness) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%s)\n", This, wine_dbgstr_longlong(lateness)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_SetPlayMode(IWMReaderAdvanced6 *iface, WMT_PLAY_MODE mode) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d)\n", This, mode); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_GetPlayMode(IWMReaderAdvanced6 *iface, WMT_PLAY_MODE *mode) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, mode); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_GetBufferProgress(IWMReaderAdvanced6 *iface, DWORD *percent, QWORD *buffering) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p %p)\n", This, percent, buffering); + return E_NOTIMPL; + } +@@ -446,28 +445,28 @@ static HRESULT WINAPI WMReaderAdvanced2_GetBufferProgress(IWMReaderAdvanced6 *if + static HRESULT WINAPI WMReaderAdvanced2_GetDownloadProgress(IWMReaderAdvanced6 *iface, DWORD *percent, + QWORD *bytes_downloaded, QWORD *download) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p %p %p)\n", This, percent, bytes_downloaded, download); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_GetSaveAsProgress(IWMReaderAdvanced6 *iface, DWORD *percent) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, percent); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_SaveFileAs(IWMReaderAdvanced6 *iface, const WCHAR *filename) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%s)\n", This, debugstr_w(filename)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_GetProtocolName(IWMReaderAdvanced6 *iface, WCHAR *protocol, DWORD *protocol_len) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p %p)\n", This, protocol, protocol_len); + return E_NOTIMPL; + } +@@ -475,7 +474,7 @@ static HRESULT WINAPI WMReaderAdvanced2_GetProtocolName(IWMReaderAdvanced6 *ifac + static HRESULT WINAPI WMReaderAdvanced2_StartAtMarker(IWMReaderAdvanced6 *iface, WORD marker_index, + QWORD duration, float rate, void *context) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %s %f %p)\n", This, marker_index, wine_dbgstr_longlong(duration), rate, context); + return E_NOTIMPL; + } +@@ -483,7 +482,7 @@ static HRESULT WINAPI WMReaderAdvanced2_StartAtMarker(IWMReaderAdvanced6 *iface, + static HRESULT WINAPI WMReaderAdvanced2_GetOutputSetting(IWMReaderAdvanced6 *iface, DWORD output_num, + const WCHAR *name, WMT_ATTR_DATATYPE *type, BYTE *value, WORD *length) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %s %p %p %p)\n", This, output_num, debugstr_w(name), type, value, length); + return E_NOTIMPL; + } +@@ -491,35 +490,35 @@ static HRESULT WINAPI WMReaderAdvanced2_GetOutputSetting(IWMReaderAdvanced6 *ifa + static HRESULT WINAPI WMReaderAdvanced2_SetOutputSetting(IWMReaderAdvanced6 *iface, DWORD output_num, + const WCHAR *name, WMT_ATTR_DATATYPE type, const BYTE *value, WORD length) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %s %d %p %d)\n", This, output_num, debugstr_w(name), type, value, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_Preroll(IWMReaderAdvanced6 *iface, QWORD start, QWORD duration, float rate) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%s %s %f)\n", This, wine_dbgstr_longlong(start), wine_dbgstr_longlong(duration), rate); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_SetLogClientID(IWMReaderAdvanced6 *iface, BOOL log_client_id) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%x)\n", This, log_client_id); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_GetLogClientID(IWMReaderAdvanced6 *iface, BOOL *log_client_id) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, log_client_id); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced2_StopBuffering(IWMReaderAdvanced6 *iface) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } +@@ -527,14 +526,14 @@ static HRESULT WINAPI WMReaderAdvanced2_StopBuffering(IWMReaderAdvanced6 *iface) + static HRESULT WINAPI WMReaderAdvanced2_OpenStream(IWMReaderAdvanced6 *iface, IStream *stream, + IWMReaderCallback *callback, void *context) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p %p %p)\n", This, stream, callback, context); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced3_StopNetStreaming(IWMReaderAdvanced6 *iface) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } +@@ -542,14 +541,14 @@ static HRESULT WINAPI WMReaderAdvanced3_StopNetStreaming(IWMReaderAdvanced6 *ifa + static HRESULT WINAPI WMReaderAdvanced3_StartAtPosition(IWMReaderAdvanced6 *iface, WORD stream_num, + void *offset_start, void *duration, WMT_OFFSET_FORMAT format, float rate, void *context) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p %p %d %f %p)\n", This, stream_num, offset_start, duration, format, rate, context); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced4_GetLanguageCount(IWMReaderAdvanced6 *iface, DWORD output_num, WORD *language_count) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, output_num, language_count); + return E_NOTIMPL; + } +@@ -557,21 +556,21 @@ static HRESULT WINAPI WMReaderAdvanced4_GetLanguageCount(IWMReaderAdvanced6 *ifa + static HRESULT WINAPI WMReaderAdvanced4_GetLanguage(IWMReaderAdvanced6 *iface, DWORD output_num, + WORD language, WCHAR *language_string, WORD *language_string_len) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %x %p %p)\n", This, output_num, language, language_string, language_string_len); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced4_GetMaxSpeedFactor(IWMReaderAdvanced6 *iface, double *factor) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, factor); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced4_IsUsingFastCache(IWMReaderAdvanced6 *iface, BOOL *using_fast_cache) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, using_fast_cache); + return E_NOTIMPL; + } +@@ -579,42 +578,42 @@ static HRESULT WINAPI WMReaderAdvanced4_IsUsingFastCache(IWMReaderAdvanced6 *ifa + static HRESULT WINAPI WMReaderAdvanced4_AddLogParam(IWMReaderAdvanced6 *iface, const WCHAR *namespace, + const WCHAR *name, const WCHAR *value) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%s %s %s)\n", This, debugstr_w(namespace), debugstr_w(name), debugstr_w(value)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced4_SendLogParams(IWMReaderAdvanced6 *iface) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced4_CanSaveFileAs(IWMReaderAdvanced6 *iface, BOOL *can_save) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p)\n", This, can_save); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced4_CancelSaveFileAs(IWMReaderAdvanced6 *iface) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced4_GetURL(IWMReaderAdvanced6 *iface, WCHAR *url, DWORD *url_len) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p %p)\n", This, url, url_len); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMReaderAdvanced5_SetPlayerHook(IWMReaderAdvanced6 *iface, DWORD output_num, IWMPlayerHook *hook) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%d %p)\n", This, output_num, hook); + return E_NOTIMPL; + } +@@ -622,7 +621,7 @@ static HRESULT WINAPI WMReaderAdvanced5_SetPlayerHook(IWMReaderAdvanced6 *iface, + static HRESULT WINAPI WMReaderAdvanced6_SetProtectStreamSamples(IWMReaderAdvanced6 *iface, BYTE *cert, + DWORD cert_size, DWORD cert_type, DWORD flags, BYTE *initialization_vector, DWORD *initialization_vector_size) + { +- struct async_reader *This = impl_from_IWMReaderAdvanced6(iface); ++ WMReader *This = impl_from_IWMReaderAdvanced6(iface); + FIXME("(%p)->(%p %d %d %x %p %p)\n", This, cert, cert_size, cert_type, flags, initialization_vector, + initialization_vector_size); + return E_NOTIMPL; +@@ -682,32 +681,32 @@ static const IWMReaderAdvanced6Vtbl WMReaderAdvanced6Vtbl = { + WMReaderAdvanced6_SetProtectStreamSamples + }; + +-static struct async_reader *impl_from_IWMReaderAccelerator(IWMReaderAccelerator *iface) ++static inline WMReader *impl_from_IWMReaderAccelerator(IWMReaderAccelerator *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReaderAccelerator_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReaderAccelerator_iface); + } + + static HRESULT WINAPI reader_accl_QueryInterface(IWMReaderAccelerator *iface, REFIID riid, void **object) + { +- struct async_reader *This = impl_from_IWMReaderAccelerator(iface); ++ WMReader *This = impl_from_IWMReaderAccelerator(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, object); + } + + static ULONG WINAPI reader_accl_AddRef(IWMReaderAccelerator *iface) + { +- struct async_reader *This = impl_from_IWMReaderAccelerator(iface); ++ WMReader *This = impl_from_IWMReaderAccelerator(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI reader_accl_Release(IWMReaderAccelerator *iface) + { +- struct async_reader *This = impl_from_IWMReaderAccelerator(iface); ++ WMReader *This = impl_from_IWMReaderAccelerator(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI reader_accl_GetCodecInterface(IWMReaderAccelerator *iface, DWORD output, REFIID riid, void **codec) + { +- struct async_reader *This = impl_from_IWMReaderAccelerator(iface); ++ WMReader *This = impl_from_IWMReaderAccelerator(iface); + + FIXME("%p, %d, %s, %p\n", This, output, debugstr_guid(riid), codec); + +@@ -716,7 +715,7 @@ static HRESULT WINAPI reader_accl_GetCodecInterface(IWMReaderAccelerator *iface, + + static HRESULT WINAPI reader_accl_Notify(IWMReaderAccelerator *iface, DWORD output, WM_MEDIA_TYPE *subtype) + { +- struct async_reader *This = impl_from_IWMReaderAccelerator(iface); ++ WMReader *This = impl_from_IWMReaderAccelerator(iface); + + FIXME("%p, %d, %p\n", This, output, subtype); + +@@ -731,39 +730,39 @@ static const IWMReaderAcceleratorVtbl WMReaderAcceleratorVtbl = { + reader_accl_Notify + }; + +-static struct async_reader *impl_from_IWMReaderNetworkConfig2(IWMReaderNetworkConfig2 *iface) ++static inline WMReader *impl_from_IWMReaderNetworkConfig2(IWMReaderNetworkConfig2 *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReaderNetworkConfig2_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReaderNetworkConfig2_iface); + } + + static HRESULT WINAPI networkconfig_QueryInterface(IWMReaderNetworkConfig2 *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI networkconfig_AddRef(IWMReaderNetworkConfig2 *iface) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI networkconfig_Release(IWMReaderNetworkConfig2 *iface) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI networkconfig_GetBufferingTime(IWMReaderNetworkConfig2 *iface, QWORD *buffering_time) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, buffering_time); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetBufferingTime(IWMReaderNetworkConfig2 *iface, QWORD buffering_time) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s\n", This, wine_dbgstr_longlong(buffering_time)); + return E_NOTIMPL; + } +@@ -771,7 +770,7 @@ static HRESULT WINAPI networkconfig_SetBufferingTime(IWMReaderNetworkConfig2 *if + static HRESULT WINAPI networkconfig_GetUDPPortRanges(IWMReaderNetworkConfig2 *iface, WM_PORT_NUMBER_RANGE *array, + DWORD *ranges) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p, %p\n", This, array, ranges); + return E_NOTIMPL; + } +@@ -779,7 +778,7 @@ static HRESULT WINAPI networkconfig_GetUDPPortRanges(IWMReaderNetworkConfig2 *if + static HRESULT WINAPI networkconfig_SetUDPPortRanges(IWMReaderNetworkConfig2 *iface, WM_PORT_NUMBER_RANGE *array, + DWORD ranges) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p, %u\n", This, array, ranges); + return E_NOTIMPL; + } +@@ -787,7 +786,7 @@ static HRESULT WINAPI networkconfig_SetUDPPortRanges(IWMReaderNetworkConfig2 *if + static HRESULT WINAPI networkconfig_GetProxySettings(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + WMT_PROXY_SETTINGS *proxy) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %p\n", This, debugstr_w(protocol), proxy); + return E_NOTIMPL; + } +@@ -795,7 +794,7 @@ static HRESULT WINAPI networkconfig_GetProxySettings(IWMReaderNetworkConfig2 *if + static HRESULT WINAPI networkconfig_SetProxySettings(IWMReaderNetworkConfig2 *iface, LPCWSTR protocol, + WMT_PROXY_SETTINGS proxy) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %d\n", This, debugstr_w(protocol), proxy); + return E_NOTIMPL; + } +@@ -803,7 +802,7 @@ static HRESULT WINAPI networkconfig_SetProxySettings(IWMReaderNetworkConfig2 *if + static HRESULT WINAPI networkconfig_GetProxyHostName(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + WCHAR *hostname, DWORD *size) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %p, %p\n", This, debugstr_w(protocol), hostname, size); + return E_NOTIMPL; + } +@@ -811,7 +810,7 @@ static HRESULT WINAPI networkconfig_GetProxyHostName(IWMReaderNetworkConfig2 *if + static HRESULT WINAPI networkconfig_SetProxyHostName(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + const WCHAR *hostname) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %s\n", This, debugstr_w(protocol), debugstr_w(hostname)); + return E_NOTIMPL; + } +@@ -819,7 +818,7 @@ static HRESULT WINAPI networkconfig_SetProxyHostName(IWMReaderNetworkConfig2 *if + static HRESULT WINAPI networkconfig_GetProxyPort(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + DWORD *port) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %p\n", This, debugstr_w(protocol), port); + return E_NOTIMPL; + } +@@ -827,7 +826,7 @@ static HRESULT WINAPI networkconfig_GetProxyPort(IWMReaderNetworkConfig2 *iface, + static HRESULT WINAPI networkconfig_SetProxyPort(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + DWORD port) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %u\n", This, debugstr_w(protocol), port); + return E_NOTIMPL; + } +@@ -835,7 +834,7 @@ static HRESULT WINAPI networkconfig_SetProxyPort(IWMReaderNetworkConfig2 *iface, + static HRESULT WINAPI networkconfig_GetProxyExceptionList(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + WCHAR *exceptions, DWORD *count) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %p, %p\n", This, debugstr_w(protocol), exceptions, count); + return E_NOTIMPL; + } +@@ -843,7 +842,7 @@ static HRESULT WINAPI networkconfig_GetProxyExceptionList(IWMReaderNetworkConfig + static HRESULT WINAPI networkconfig_SetProxyExceptionList(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + const WCHAR *exceptions) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %s\n", This, debugstr_w(protocol), debugstr_w(exceptions)); + return E_NOTIMPL; + } +@@ -851,7 +850,7 @@ static HRESULT WINAPI networkconfig_SetProxyExceptionList(IWMReaderNetworkConfig + static HRESULT WINAPI networkconfig_GetProxyBypassForLocal(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + BOOL *bypass) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %p\n", This, debugstr_w(protocol), bypass); + return E_NOTIMPL; + } +@@ -859,7 +858,7 @@ static HRESULT WINAPI networkconfig_GetProxyBypassForLocal(IWMReaderNetworkConfi + static HRESULT WINAPI networkconfig_SetProxyBypassForLocal(IWMReaderNetworkConfig2 *iface, const WCHAR *protocol, + BOOL bypass) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s, %d\n", This, debugstr_w(protocol), bypass); + return E_NOTIMPL; + } +@@ -867,7 +866,7 @@ static HRESULT WINAPI networkconfig_SetProxyBypassForLocal(IWMReaderNetworkConfi + static HRESULT WINAPI networkconfig_GetForceRerunAutoProxyDetection(IWMReaderNetworkConfig2 *iface, + BOOL *detection) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, detection); + return E_NOTIMPL; + } +@@ -875,91 +874,91 @@ static HRESULT WINAPI networkconfig_GetForceRerunAutoProxyDetection(IWMReaderNet + static HRESULT WINAPI networkconfig_SetForceRerunAutoProxyDetection(IWMReaderNetworkConfig2 *iface, + BOOL detection) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %d\n", This, detection); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableMulticast(IWMReaderNetworkConfig2 *iface, BOOL *multicast) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, multicast); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableMulticast(IWMReaderNetworkConfig2 *iface, BOOL multicast) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %d\n", This, multicast); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableHTTP(IWMReaderNetworkConfig2 *iface, BOOL *enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableHTTP(IWMReaderNetworkConfig2 *iface, BOOL enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %d\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableUDP(IWMReaderNetworkConfig2 *iface, BOOL *enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableUDP(IWMReaderNetworkConfig2 *iface, BOOL enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %d\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableTCP(IWMReaderNetworkConfig2 *iface, BOOL *enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableTCP(IWMReaderNetworkConfig2 *iface, BOOL enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %d\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_ResetProtocolRollover(IWMReaderNetworkConfig2 *iface) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetConnectionBandwidth(IWMReaderNetworkConfig2 *iface, DWORD *bandwidth) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetConnectionBandwidth(IWMReaderNetworkConfig2 *iface, DWORD bandwidth) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %u\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetNumProtocolsSupported(IWMReaderNetworkConfig2 *iface, DWORD *protocols) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, protocols); + return E_NOTIMPL; + } +@@ -967,14 +966,14 @@ static HRESULT WINAPI networkconfig_GetNumProtocolsSupported(IWMReaderNetworkCon + static HRESULT WINAPI networkconfig_GetSupportedProtocolName(IWMReaderNetworkConfig2 *iface, DWORD protocol_num, + WCHAR *protocol, DWORD *size) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %u, %p %p\n", This, protocol_num, protocol, size); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_AddLoggingUrl(IWMReaderNetworkConfig2 *iface, const WCHAR *url) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s\n", This, debugstr_w(url)); + return E_NOTIMPL; + } +@@ -982,49 +981,49 @@ static HRESULT WINAPI networkconfig_AddLoggingUrl(IWMReaderNetworkConfig2 *iface + static HRESULT WINAPI networkconfig_GetLoggingUrl(IWMReaderNetworkConfig2 *iface, DWORD index, WCHAR *url, + DWORD *size) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %u, %p, %p\n", This, index, url, size); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetLoggingUrlCount(IWMReaderNetworkConfig2 *iface, DWORD *count) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, count); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_ResetLoggingUrlList(IWMReaderNetworkConfig2 *iface) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableContentCaching(IWMReaderNetworkConfig2 *iface, BOOL *enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableContentCaching(IWMReaderNetworkConfig2 *iface, BOOL enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %d\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableFastCache(IWMReaderNetworkConfig2 *iface, BOOL *enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableFastCache(IWMReaderNetworkConfig2 *iface, BOOL enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %d\n", This, enable); + return E_NOTIMPL; + } +@@ -1032,7 +1031,7 @@ static HRESULT WINAPI networkconfig_SetEnableFastCache(IWMReaderNetworkConfig2 * + static HRESULT WINAPI networkconfig_GetAcceleratedStreamingDuration(IWMReaderNetworkConfig2 *iface, + QWORD *duration) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, duration); + return E_NOTIMPL; + } +@@ -1040,56 +1039,56 @@ static HRESULT WINAPI networkconfig_GetAcceleratedStreamingDuration(IWMReaderNet + static HRESULT WINAPI networkconfig_SetAcceleratedStreamingDuration(IWMReaderNetworkConfig2 *iface, + QWORD duration) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %s\n", This, wine_dbgstr_longlong(duration)); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetAutoReconnectLimit(IWMReaderNetworkConfig2 *iface, DWORD *limit) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, limit); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetAutoReconnectLimit(IWMReaderNetworkConfig2 *iface, DWORD limit) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %u\n", This, limit); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableResends(IWMReaderNetworkConfig2 *iface, BOOL *enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableResends(IWMReaderNetworkConfig2 *iface, BOOL enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %u\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetEnableThinning(IWMReaderNetworkConfig2 *iface, BOOL *enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_SetEnableThinning(IWMReaderNetworkConfig2 *iface, BOOL enable) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %u\n", This, enable); + return E_NOTIMPL; + } + + static HRESULT WINAPI networkconfig_GetMaxNetPacketSize(IWMReaderNetworkConfig2 *iface, DWORD *packet_size) + { +- struct async_reader *This = impl_from_IWMReaderNetworkConfig2(iface); ++ WMReader *This = impl_from_IWMReaderNetworkConfig2(iface); + FIXME("%p, %p\n", This, packet_size); + return E_NOTIMPL; + } +@@ -1147,46 +1146,46 @@ static const IWMReaderNetworkConfig2Vtbl WMReaderNetworkConfig2Vtbl = + networkconfig_GetMaxNetPacketSize + }; + +-static struct async_reader *impl_from_IWMReaderStreamClock(IWMReaderStreamClock *iface) ++static inline WMReader *impl_from_IWMReaderStreamClock(IWMReaderStreamClock *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReaderStreamClock_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReaderStreamClock_iface); + } + + static HRESULT WINAPI readclock_QueryInterface(IWMReaderStreamClock *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMReaderStreamClock(iface); ++ WMReader *This = impl_from_IWMReaderStreamClock(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI readclock_AddRef(IWMReaderStreamClock *iface) + { +- struct async_reader *This = impl_from_IWMReaderStreamClock(iface); ++ WMReader *This = impl_from_IWMReaderStreamClock(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI readclock_Release(IWMReaderStreamClock *iface) + { +- struct async_reader *This = impl_from_IWMReaderStreamClock(iface); ++ WMReader *This = impl_from_IWMReaderStreamClock(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI readclock_GetTime(IWMReaderStreamClock *iface, QWORD *now) + { +- struct async_reader *This = impl_from_IWMReaderStreamClock(iface); ++ WMReader *This = impl_from_IWMReaderStreamClock(iface); + FIXME("%p, %p\n", This, now); + return E_NOTIMPL; + } + + static HRESULT WINAPI readclock_SetTimer(IWMReaderStreamClock *iface, QWORD when, void *param, DWORD *id) + { +- struct async_reader *This = impl_from_IWMReaderStreamClock(iface); ++ WMReader *This = impl_from_IWMReaderStreamClock(iface); + FIXME("%p, %s, %p, %p\n", This, wine_dbgstr_longlong(when), param, id); + return E_NOTIMPL; + } + + static HRESULT WINAPI readclock_KillTimer(IWMReaderStreamClock *iface, DWORD id) + { +- struct async_reader *This = impl_from_IWMReaderStreamClock(iface); ++ WMReader *This = impl_from_IWMReaderStreamClock(iface); + FIXME("%p, %d\n", This, id); + return E_NOTIMPL; + } +@@ -1201,32 +1200,32 @@ static const IWMReaderStreamClockVtbl WMReaderStreamClockVtbl = + readclock_KillTimer + }; + +-static struct async_reader *impl_from_IWMReaderTypeNegotiation(IWMReaderTypeNegotiation *iface) ++static inline WMReader *impl_from_IWMReaderTypeNegotiation(IWMReaderTypeNegotiation *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReaderTypeNegotiation_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReaderTypeNegotiation_iface); + } + + static HRESULT WINAPI negotiation_QueryInterface(IWMReaderTypeNegotiation *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMReaderTypeNegotiation(iface); ++ WMReader *This = impl_from_IWMReaderTypeNegotiation(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI negotiation_AddRef(IWMReaderTypeNegotiation *iface) + { +- struct async_reader *This = impl_from_IWMReaderTypeNegotiation(iface); ++ WMReader *This = impl_from_IWMReaderTypeNegotiation(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI negotiation_Release(IWMReaderTypeNegotiation *iface) + { +- struct async_reader *This = impl_from_IWMReaderTypeNegotiation(iface); ++ WMReader *This = impl_from_IWMReaderTypeNegotiation(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI negotiation_TryOutputProps(IWMReaderTypeNegotiation *iface, DWORD output, IWMOutputMediaProps *props) + { +- struct async_reader *This = impl_from_IWMReaderTypeNegotiation(iface); ++ WMReader *This = impl_from_IWMReaderTypeNegotiation(iface); + FIXME("%p, %d, %p\n", This, output, props); + return E_NOTIMPL; + } +@@ -1239,32 +1238,32 @@ static const IWMReaderTypeNegotiationVtbl WMReaderTypeNegotiationVtbl = + negotiation_TryOutputProps + }; + +-static struct async_reader *impl_from_IWMReaderTimecode(IWMReaderTimecode *iface) ++static inline WMReader *impl_from_IWMReaderTimecode(IWMReaderTimecode *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReaderTimecode_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReaderTimecode_iface); + } + + static HRESULT WINAPI timecode_QueryInterface(IWMReaderTimecode *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMReaderTimecode(iface); ++ WMReader *This = impl_from_IWMReaderTimecode(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI timecode_AddRef(IWMReaderTimecode *iface) + { +- struct async_reader *This = impl_from_IWMReaderTimecode(iface); ++ WMReader *This = impl_from_IWMReaderTimecode(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI timecode_Release(IWMReaderTimecode *iface) + { +- struct async_reader *This = impl_from_IWMReaderTimecode(iface); ++ WMReader *This = impl_from_IWMReaderTimecode(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI timecode_GetTimecodeRangeCount(IWMReaderTimecode *iface, WORD num, WORD *count) + { +- struct async_reader *This = impl_from_IWMReaderTimecode(iface); ++ WMReader *This = impl_from_IWMReaderTimecode(iface); + FIXME("%p, %d, %p\n", This, num, count); + return E_NOTIMPL; + } +@@ -1272,7 +1271,7 @@ static HRESULT WINAPI timecode_GetTimecodeRangeCount(IWMReaderTimecode *iface, W + static HRESULT WINAPI timecode_GetTimecodeRangeBounds(IWMReaderTimecode *iface, WORD stream, WORD range, + DWORD *start_timecode, DWORD *end_timecode) + { +- struct async_reader *This = impl_from_IWMReaderTimecode(iface); ++ WMReader *This = impl_from_IWMReaderTimecode(iface); + FIXME("%p, %d, %d, %p, %p\n", This, stream, range, start_timecode, end_timecode); + return E_NOTIMPL; + } +@@ -1287,54 +1286,54 @@ static const IWMReaderTimecodeVtbl WMReaderTimecodeVtbl = + }; + + +-static struct async_reader *impl_from_IWMReaderPlaylistBurn(IWMReaderPlaylistBurn *iface) ++static inline WMReader *impl_from_IWMReaderPlaylistBurn(IWMReaderPlaylistBurn *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMReaderPlaylistBurn_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMReaderPlaylistBurn_iface); + } + + static HRESULT WINAPI playlist_QueryInterface(IWMReaderPlaylistBurn *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMReaderPlaylistBurn(iface); ++ WMReader *This = impl_from_IWMReaderPlaylistBurn(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI playlist_AddRef(IWMReaderPlaylistBurn *iface) + { +- struct async_reader *This = impl_from_IWMReaderPlaylistBurn(iface); ++ WMReader *This = impl_from_IWMReaderPlaylistBurn(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI playlist_Release(IWMReaderPlaylistBurn *iface) + { +- struct async_reader *This = impl_from_IWMReaderPlaylistBurn(iface); ++ WMReader *This = impl_from_IWMReaderPlaylistBurn(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI playlist_InitPlaylistBurn(IWMReaderPlaylistBurn *iface, DWORD count, + LPCWSTR_WMSDK_TYPE_SAFE *filenames, IWMStatusCallback *callback, void *context) + { +- struct async_reader *This = impl_from_IWMReaderPlaylistBurn(iface); ++ WMReader *This = impl_from_IWMReaderPlaylistBurn(iface); + FIXME("%p, %d, %p, %p, %p\n", This, count, filenames, callback, context); + return E_NOTIMPL; + } + + static HRESULT WINAPI playlist_GetInitResults(IWMReaderPlaylistBurn *iface, DWORD count, HRESULT *stat) + { +- struct async_reader *This = impl_from_IWMReaderPlaylistBurn(iface); ++ WMReader *This = impl_from_IWMReaderPlaylistBurn(iface); + FIXME("%p, %d, %p\n", This, count, stat); + return E_NOTIMPL; + } + + static HRESULT WINAPI playlist_Cancel(IWMReaderPlaylistBurn *iface) + { +- struct async_reader *This = impl_from_IWMReaderPlaylistBurn(iface); ++ WMReader *This = impl_from_IWMReaderPlaylistBurn(iface); + FIXME("%p\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI playlist_EndPlaylistBurn(IWMReaderPlaylistBurn *iface, HRESULT result) + { +- struct async_reader *This = impl_from_IWMReaderPlaylistBurn(iface); ++ WMReader *This = impl_from_IWMReaderPlaylistBurn(iface); + FIXME("%p, 0x%08x\n", This, result); + return E_NOTIMPL; + } +@@ -1350,32 +1349,32 @@ static const IWMReaderPlaylistBurnVtbl WMReaderPlaylistBurnVtbl = + playlist_EndPlaylistBurn + }; + +-static struct async_reader *impl_from_IWMHeaderInfo3(IWMHeaderInfo3 *iface) ++static inline WMReader *impl_from_IWMHeaderInfo3(IWMHeaderInfo3 *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMHeaderInfo3_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMHeaderInfo3_iface); + } + + static HRESULT WINAPI headerinfo_QueryInterface(IWMHeaderInfo3 *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI headerinfo_AddRef(IWMHeaderInfo3 *iface) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI headerinfo_Release(IWMHeaderInfo3 *iface) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI headerinfo_GetAttributeCount(IWMHeaderInfo3 *iface, WORD stream_num, WORD *attributes) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %p\n", This, stream_num, attributes); + return E_NOTIMPL; + } +@@ -1383,7 +1382,7 @@ static HRESULT WINAPI headerinfo_GetAttributeCount(IWMHeaderInfo3 *iface, WORD s + static HRESULT WINAPI headerinfo_GetAttributeByIndex(IWMHeaderInfo3 *iface, WORD index, WORD *stream_num, + WCHAR *name, WORD *name_len, WMT_ATTR_DATATYPE *type, BYTE *value, WORD *length) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %p, %p, %p, %p, %p, %p\n", This, index, stream_num, name, name_len, type, + value, length); + return E_NOTIMPL; +@@ -1392,7 +1391,7 @@ static HRESULT WINAPI headerinfo_GetAttributeByIndex(IWMHeaderInfo3 *iface, WORD + static HRESULT WINAPI headerinfo_GetAttributeByName(IWMHeaderInfo3 *iface, WORD *stream_num, LPCWSTR name, + WMT_ATTR_DATATYPE *type, BYTE *value, WORD *length) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %p, %s, %p, %p, %p\n", This, stream_num, debugstr_w(name), type, value, length); + return E_NOTIMPL; + } +@@ -1400,14 +1399,14 @@ static HRESULT WINAPI headerinfo_GetAttributeByName(IWMHeaderInfo3 *iface, WORD + static HRESULT WINAPI headerinfo_SetAttribute(IWMHeaderInfo3 *iface, WORD stream_num, LPCWSTR name, + WMT_ATTR_DATATYPE type, const BYTE *value, WORD length) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %s, %d, %p, %d\n", This, stream_num, debugstr_w(name), type, value, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI headerinfo_GetMarkerCount(IWMHeaderInfo3 *iface, WORD *markers) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %p\n", This, markers); + return E_NOTIMPL; + } +@@ -1415,7 +1414,7 @@ static HRESULT WINAPI headerinfo_GetMarkerCount(IWMHeaderInfo3 *iface, WORD *mar + static HRESULT WINAPI headerinfo_GetMarker(IWMHeaderInfo3 *iface, WORD index, WCHAR *marker_name, + WORD *marker_len, QWORD *marker_time) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %p, %p, %p\n", This, index, marker_name, marker_len, marker_time); + return E_NOTIMPL; + } +@@ -1423,21 +1422,21 @@ static HRESULT WINAPI headerinfo_GetMarker(IWMHeaderInfo3 *iface, WORD index, WC + static HRESULT WINAPI headerinfo_AddMarker(IWMHeaderInfo3 *iface, LPCWSTR_WMSDK_TYPE_SAFE marker_name, + QWORD marker_time) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %p, %s\n", This, marker_name, wine_dbgstr_longlong(marker_time)); + return E_NOTIMPL; + } + + static HRESULT WINAPI headerinfo_RemoveMarker(IWMHeaderInfo3 *iface, WORD index) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d\n", This, index); + return E_NOTIMPL; + } + + static HRESULT WINAPI headerinfo_GetScriptCount(IWMHeaderInfo3 *iface, WORD *scripts) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %p\n", This, scripts); + return E_NOTIMPL; + } +@@ -1445,7 +1444,7 @@ static HRESULT WINAPI headerinfo_GetScriptCount(IWMHeaderInfo3 *iface, WORD *scr + static HRESULT WINAPI headerinfo_GetScript(IWMHeaderInfo3 *iface, WORD index, WCHAR *type, + WORD *type_len, WCHAR *command, WORD *command_len, QWORD *script_time) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %p, %p, %p, %p, %p\n", This, index, type, type_len, command, command_len, script_time); + return E_NOTIMPL; + } +@@ -1453,21 +1452,21 @@ static HRESULT WINAPI headerinfo_GetScript(IWMHeaderInfo3 *iface, WORD index, WC + static HRESULT WINAPI headerinfo_AddScript(IWMHeaderInfo3 *iface, LPCWSTR_WMSDK_TYPE_SAFE type, + LPCWSTR_WMSDK_TYPE_SAFE command, QWORD script_time) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %s, %s, %s\n", This, debugstr_w(type), debugstr_w(command), wine_dbgstr_longlong(script_time)); + return E_NOTIMPL; + } + + static HRESULT WINAPI headerinfo_RemoveScript(IWMHeaderInfo3 *iface, WORD index) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d\n", This, index); + return E_NOTIMPL; + } + + static HRESULT WINAPI headerinfo_GetCodecInfoCount(IWMHeaderInfo3 *iface, DWORD *codec_infos) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %p\n", This, codec_infos); + return E_NOTIMPL; + } +@@ -1476,7 +1475,7 @@ static HRESULT WINAPI headerinfo_GetCodecInfo(IWMHeaderInfo3 *iface, DWORD index + WCHAR *name, WORD *description_len, WCHAR *description, WMT_CODEC_INFO_TYPE *codec_type, + WORD *codec_info_cnt, BYTE *codec_info) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %p, %p, %p, %p, %p, %p, %p\n", This, index, name_len, name, description_len, + description, codec_type, codec_info_cnt, codec_info); + return E_NOTIMPL; +@@ -1484,7 +1483,7 @@ static HRESULT WINAPI headerinfo_GetCodecInfo(IWMHeaderInfo3 *iface, DWORD index + + static HRESULT WINAPI headerinfo_GetAttributeCountEx(IWMHeaderInfo3 *iface, WORD stream_num, WORD *attributes) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %p\n", This, stream_num, attributes); + return E_NOTIMPL; + } +@@ -1492,7 +1491,7 @@ static HRESULT WINAPI headerinfo_GetAttributeCountEx(IWMHeaderInfo3 *iface, WORD + static HRESULT WINAPI headerinfo_GetAttributeIndices(IWMHeaderInfo3 *iface, WORD stream_num, LPCWSTR name, + WORD *lang_index, WORD *indices, WORD *count) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %s, %p, %p, %p\n", This, stream_num, debugstr_w(name), lang_index, indices, count); + return E_NOTIMPL; + } +@@ -1501,7 +1500,7 @@ static HRESULT WINAPI headerinfo_GetAttributeByIndexEx(IWMHeaderInfo3 *iface, WO + WORD index, LPWSTR name, WORD *name_len, WMT_ATTR_DATATYPE *type, WORD *lang_index, + BYTE *value, DWORD *data_len) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %d, %s, %p, %p, %p, %p, %p\n", This, stream_num, index, debugstr_w(name), name_len, + type, lang_index, value, data_len); + return E_NOTIMPL; +@@ -1510,7 +1509,7 @@ static HRESULT WINAPI headerinfo_GetAttributeByIndexEx(IWMHeaderInfo3 *iface, WO + static HRESULT WINAPI headerinfo_ModifyAttribute(IWMHeaderInfo3 *iface, WORD stream_num, + WORD index, WMT_ATTR_DATATYPE type, WORD lang_index, const BYTE *value, DWORD length) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %d, %d, %d, %p, %d\n", This, stream_num, index, type, lang_index, value, length); + return E_NOTIMPL; + } +@@ -1518,7 +1517,7 @@ static HRESULT WINAPI headerinfo_ModifyAttribute(IWMHeaderInfo3 *iface, WORD str + static HRESULT WINAPI headerinfo_AddAttribute(IWMHeaderInfo3 *iface, WORD stream_num, LPCWSTR name, + WORD *index, WMT_ATTR_DATATYPE type, WORD lang_index, const BYTE *value, DWORD length) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %s, %p, %d, %d, %p, %d\n", This, stream_num, debugstr_w(name), index, + type, lang_index, value, length); + return E_NOTIMPL; +@@ -1526,7 +1525,7 @@ static HRESULT WINAPI headerinfo_AddAttribute(IWMHeaderInfo3 *iface, WORD stream + + static HRESULT WINAPI headerinfo_DeleteAttribute(IWMHeaderInfo3 *iface, WORD stream_num, WORD index) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %d, %d\n", This, stream_num, index); + return E_NOTIMPL; + } +@@ -1535,7 +1534,7 @@ static HRESULT WINAPI headerinfo_AddCodecInfo(IWMHeaderInfo3 *iface, LPCWSTR_WMS + LPCWSTR_WMSDK_TYPE_SAFE description, WMT_CODEC_INFO_TYPE codec_type, WORD codec_info_cnt, + BYTE *codec_info) + { +- struct async_reader *This = impl_from_IWMHeaderInfo3(iface); ++ WMReader *This = impl_from_IWMHeaderInfo3(iface); + FIXME("%p, %p, %p, %d, %d, %p\n", This, name, description, codec_type, codec_info_cnt, + codec_info); + return E_NOTIMPL; +@@ -1570,32 +1569,32 @@ static const IWMHeaderInfo3Vtbl WMHeaderInfo3Vtbl = + }; + + +-static struct async_reader *impl_from_IWMLanguageList(IWMLanguageList *iface) ++static inline WMReader *impl_from_IWMLanguageList(IWMLanguageList *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMLanguageList_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMLanguageList_iface); + } + + static HRESULT WINAPI langlist_QueryInterface(IWMLanguageList *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMLanguageList(iface); ++ WMReader *This = impl_from_IWMLanguageList(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI langlist_AddRef(IWMLanguageList *iface) + { +- struct async_reader *This = impl_from_IWMLanguageList(iface); ++ WMReader *This = impl_from_IWMLanguageList(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI langlist_Release(IWMLanguageList *iface) + { +- struct async_reader *This = impl_from_IWMLanguageList(iface); ++ WMReader *This = impl_from_IWMLanguageList(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI langlist_GetLanguageCount(IWMLanguageList *iface, WORD *count) + { +- struct async_reader *This = impl_from_IWMLanguageList(iface); ++ WMReader *This = impl_from_IWMLanguageList(iface); + FIXME("%p, %p\n", This, count); + return E_NOTIMPL; + } +@@ -1603,7 +1602,7 @@ static HRESULT WINAPI langlist_GetLanguageCount(IWMLanguageList *iface, WORD *co + static HRESULT WINAPI langlist_GetLanguageDetails(IWMLanguageList *iface, WORD index, + WCHAR *language, WORD *length) + { +- struct async_reader *This = impl_from_IWMLanguageList(iface); ++ WMReader *This = impl_from_IWMLanguageList(iface); + FIXME("%p, %d, %p, %p\n", This, index, language, length); + return E_NOTIMPL; + } +@@ -1611,7 +1610,7 @@ static HRESULT WINAPI langlist_GetLanguageDetails(IWMLanguageList *iface, WORD i + static HRESULT WINAPI langlist_AddLanguageByRFC1766String(IWMLanguageList *iface, LPCWSTR_WMSDK_TYPE_SAFE language, + WORD *index) + { +- struct async_reader *This = impl_from_IWMLanguageList(iface); ++ WMReader *This = impl_from_IWMLanguageList(iface); + FIXME("%p, %p, %p\n", This, language, index); + return E_NOTIMPL; + } +@@ -1626,32 +1625,32 @@ static const IWMLanguageListVtbl WMLanguageListVtbl = + langlist_AddLanguageByRFC1766String + }; + +-static struct async_reader *impl_from_IReferenceClock(IReferenceClock *iface) ++static inline WMReader *impl_from_IReferenceClock(IReferenceClock *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IReferenceClock_iface); ++ return CONTAINING_RECORD(iface, WMReader, IReferenceClock_iface); + } + + static HRESULT WINAPI refclock_QueryInterface(IReferenceClock *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IReferenceClock(iface); ++ WMReader *This = impl_from_IReferenceClock(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI refclock_AddRef(IReferenceClock *iface) + { +- struct async_reader *This = impl_from_IReferenceClock(iface); ++ WMReader *This = impl_from_IReferenceClock(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI refclock_Release(IReferenceClock *iface) + { +- struct async_reader *This = impl_from_IReferenceClock(iface); ++ WMReader *This = impl_from_IReferenceClock(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI refclock_GetTime(IReferenceClock *iface, REFERENCE_TIME *time) + { +- struct async_reader *This = impl_from_IReferenceClock(iface); ++ WMReader *This = impl_from_IReferenceClock(iface); + FIXME("%p, %p\n", This, time); + return E_NOTIMPL; + } +@@ -1659,7 +1658,7 @@ static HRESULT WINAPI refclock_GetTime(IReferenceClock *iface, REFERENCE_TIME *t + static HRESULT WINAPI refclock_AdviseTime(IReferenceClock *iface, REFERENCE_TIME basetime, + REFERENCE_TIME streamtime, HEVENT event, DWORD_PTR *cookie) + { +- struct async_reader *This = impl_from_IReferenceClock(iface); ++ WMReader *This = impl_from_IReferenceClock(iface); + FIXME("%p, %s, %s, %lu, %p\n", This, wine_dbgstr_longlong(basetime), + wine_dbgstr_longlong(streamtime), event, cookie); + return E_NOTIMPL; +@@ -1668,7 +1667,7 @@ static HRESULT WINAPI refclock_AdviseTime(IReferenceClock *iface, REFERENCE_TIME + static HRESULT WINAPI refclock_AdvisePeriodic(IReferenceClock *iface, REFERENCE_TIME starttime, + REFERENCE_TIME period, HSEMAPHORE semaphore, DWORD_PTR *cookie) + { +- struct async_reader *This = impl_from_IReferenceClock(iface); ++ WMReader *This = impl_from_IReferenceClock(iface); + FIXME("%p, %s, %s, %lu, %p\n", This, wine_dbgstr_longlong(starttime), + wine_dbgstr_longlong(period), semaphore, cookie); + return E_NOTIMPL; +@@ -1676,7 +1675,7 @@ static HRESULT WINAPI refclock_AdvisePeriodic(IReferenceClock *iface, REFERENCE_ + + static HRESULT WINAPI refclock_Unadvise(IReferenceClock *iface, DWORD_PTR cookie) + { +- struct async_reader *This = impl_from_IReferenceClock(iface); ++ WMReader *This = impl_from_IReferenceClock(iface); + FIXME("%p, %lu\n", This, cookie); + return E_NOTIMPL; + } +@@ -1692,67 +1691,67 @@ static const IReferenceClockVtbl ReferenceClockVtbl = + refclock_Unadvise + }; + +-static struct async_reader *impl_from_IWMProfile3(IWMProfile3 *iface) ++static inline WMReader *impl_from_IWMProfile3(IWMProfile3 *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMProfile3_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMProfile3_iface); + } + + static HRESULT WINAPI profile3_QueryInterface(IWMProfile3 *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI profile3_AddRef(IWMProfile3 *iface) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI profile3_Release(IWMProfile3 *iface) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI profile3_GetVersion(IWMProfile3 *iface, WMT_VERSION *version) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, version); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetName(IWMProfile3 *iface, WCHAR *name, DWORD *length) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p, %p\n", This, name, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_SetName(IWMProfile3 *iface, const WCHAR *name) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s\n", This, debugstr_w(name)); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetDescription(IWMProfile3 *iface, WCHAR *description, DWORD *length) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p, %p\n", This, description, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_SetDescription(IWMProfile3 *iface, const WCHAR *description) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s\n", This, debugstr_w(description)); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetStreamCount(IWMProfile3 *iface, DWORD *count) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, count); + + if (!count) +@@ -1764,175 +1763,175 @@ static HRESULT WINAPI profile3_GetStreamCount(IWMProfile3 *iface, DWORD *count) + + static HRESULT WINAPI profile3_GetStream(IWMProfile3 *iface, DWORD index, IWMStreamConfig **config) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, index, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetStreamByNumber(IWMProfile3 *iface, WORD stream, IWMStreamConfig **config) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, stream, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_RemoveStream(IWMProfile3 *iface, IWMStreamConfig *config) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_RemoveStreamByNumber(IWMProfile3 *iface, WORD stream) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_AddStream(IWMProfile3 *iface, IWMStreamConfig *config) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_ReconfigStream(IWMProfile3 *iface, IWMStreamConfig *config) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_CreateNewStream(IWMProfile3 *iface, REFGUID type, IWMStreamConfig **config) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s, %p\n", This, debugstr_guid(type), config); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetMutualExclusionCount(IWMProfile3 *iface, DWORD *count) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, count); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetMutualExclusion(IWMProfile3 *iface, DWORD index, IWMMutualExclusion **mutual) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, index, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_RemoveMutualExclusion(IWMProfile3 *iface, IWMMutualExclusion *mutual) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_AddMutualExclusion(IWMProfile3 *iface, IWMMutualExclusion *mutual) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_CreateNewMutualExclusion(IWMProfile3 *iface, IWMMutualExclusion **mutual) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetProfileID(IWMProfile3 *iface, GUID *guid) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, guid); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetStorageFormat(IWMProfile3 *iface, WMT_STORAGE_FORMAT *storage) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, storage); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_SetStorageFormat(IWMProfile3 *iface, WMT_STORAGE_FORMAT storage) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d\n", This, storage); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetBandwidthSharingCount(IWMProfile3 *iface, DWORD *count) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, count); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetBandwidthSharing(IWMProfile3 *iface, DWORD index, IWMBandwidthSharing **bandwidth) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, index, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_RemoveBandwidthSharing( IWMProfile3 *iface, IWMBandwidthSharing *bandwidth) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_AddBandwidthSharing(IWMProfile3 *iface, IWMBandwidthSharing *bandwidth) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_CreateNewBandwidthSharing( IWMProfile3 *iface, IWMBandwidthSharing **bandwidth) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetStreamPrioritization(IWMProfile3 *iface, IWMStreamPrioritization **stream) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_SetStreamPrioritization(IWMProfile3 *iface, IWMStreamPrioritization *stream) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_RemoveStreamPrioritization(IWMProfile3 *iface) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_CreateNewStreamPrioritization(IWMProfile3 *iface, IWMStreamPrioritization **stream) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI profile3_GetExpectedPacketCount(IWMProfile3 *iface, QWORD duration, QWORD *packets) + { +- struct async_reader *This = impl_from_IWMProfile3(iface); ++ WMReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s, %p\n", This, wine_dbgstr_longlong(duration), packets); + return E_NOTIMPL; + } +@@ -1975,53 +1974,53 @@ static const IWMProfile3Vtbl WMProfile3Vtbl = + profile3_GetExpectedPacketCount + }; + +-static struct async_reader *impl_from_IWMPacketSize2(IWMPacketSize2 *iface) ++static inline WMReader *impl_from_IWMPacketSize2(IWMPacketSize2 *iface) + { +- return CONTAINING_RECORD(iface, struct async_reader, IWMPacketSize2_iface); ++ return CONTAINING_RECORD(iface, WMReader, IWMPacketSize2_iface); + } + + static HRESULT WINAPI packetsize_QueryInterface(IWMPacketSize2 *iface, REFIID riid, void **ppv) + { +- struct async_reader *This = impl_from_IWMPacketSize2(iface); ++ WMReader *This = impl_from_IWMPacketSize2(iface); + return IWMReader_QueryInterface(&This->IWMReader_iface, riid, ppv); + } + + static ULONG WINAPI packetsize_AddRef(IWMPacketSize2 *iface) + { +- struct async_reader *This = impl_from_IWMPacketSize2(iface); ++ WMReader *This = impl_from_IWMPacketSize2(iface); + return IWMReader_AddRef(&This->IWMReader_iface); + } + + static ULONG WINAPI packetsize_Release(IWMPacketSize2 *iface) + { +- struct async_reader *This = impl_from_IWMPacketSize2(iface); ++ WMReader *This = impl_from_IWMPacketSize2(iface); + return IWMReader_Release(&This->IWMReader_iface); + } + + static HRESULT WINAPI packetsize_GetMaxPacketSize(IWMPacketSize2 *iface, DWORD *size) + { +- struct async_reader *This = impl_from_IWMPacketSize2(iface); ++ WMReader *This = impl_from_IWMPacketSize2(iface); + FIXME("%p, %p\n", This, size); + return E_NOTIMPL; + } + + static HRESULT WINAPI packetsize_SetMaxPacketSize(IWMPacketSize2 *iface, DWORD size) + { +- struct async_reader *This = impl_from_IWMPacketSize2(iface); ++ WMReader *This = impl_from_IWMPacketSize2(iface); + FIXME("%p, %d\n", This, size); + return E_NOTIMPL; + } + + static HRESULT WINAPI packetsize_GetMinPacketSize(IWMPacketSize2 *iface, DWORD *size) + { +- struct async_reader *This = impl_from_IWMPacketSize2(iface); ++ WMReader *This = impl_from_IWMPacketSize2(iface); + FIXME("%p, %p\n", This, size); + return E_NOTIMPL; + } + + static HRESULT WINAPI packetsize_SetMinPacketSize(IWMPacketSize2 *iface, DWORD size) + { +- struct async_reader *This = impl_from_IWMPacketSize2(iface); ++ WMReader *This = impl_from_IWMPacketSize2(iface); + FIXME("%p, %d\n", This, size); + return E_NOTIMPL; + } +@@ -2039,7 +2038,7 @@ static const IWMPacketSize2Vtbl WMPacketSize2Vtbl = + + HRESULT WINAPI winegstreamer_create_wm_async_reader(IWMReader **reader) + { +- struct async_reader *object; ++ WMReader *object; + + TRACE("reader %p.\n", reader); + +-- +2.33.0 + diff --git a/patches/mfplat-reverts/0002-Revert-wmvcore-Move-the-async-reader-implementation-.patch b/patches/mfplat-reverts/0002-Revert-wmvcore-Move-the-async-reader-implementation-.patch new file mode 100644 index 00000000..9d4726e0 --- /dev/null +++ b/patches/mfplat-reverts/0002-Revert-wmvcore-Move-the-async-reader-implementation-.patch @@ -0,0 +1,168 @@ +From 2c3d9dfc09ee64767347574e0bd6e8f5511a6a54 Mon Sep 17 00:00:00 2001 +From: Alistair Leslie-Hughes +Date: Sat, 9 Oct 2021 13:47:39 +1100 +Subject: [PATCH 02/22] Revert "wmvcore: Move the async reader implementation + to winegstreamer." + +This reverts commit bf7c05d87a65b7b9999d71fc0df602e3dfa2fafa. +--- + dlls/winegstreamer/Makefile.in | 1 - + dlls/winegstreamer/winegstreamer.spec | 1 - + dlls/wmvcore/Makefile.in | 1 + + .../wm_asyncreader.c => wmvcore/reader.c} | 54 +++++++++++-------- + dlls/wmvcore/wmvcore_main.c | 15 ------ + 5 files changed, 32 insertions(+), 40 deletions(-) + rename dlls/{winegstreamer/wm_asyncreader.c => wmvcore/reader.c} (98%) + +diff --git a/dlls/winegstreamer/Makefile.in b/dlls/winegstreamer/Makefile.in +index 17311cd663c..671e3bcb7ba 100644 +--- a/dlls/winegstreamer/Makefile.in ++++ b/dlls/winegstreamer/Makefile.in +@@ -13,7 +13,6 @@ C_SRCS = \ + mfplat.c \ + quartz_parser.c \ + wg_parser.c \ +- wm_asyncreader.c \ + wm_syncreader.c + + IDL_SRCS = \ +diff --git a/dlls/winegstreamer/winegstreamer.spec b/dlls/winegstreamer/winegstreamer.spec +index bc6a390f8b1..bd9f53a7445 100644 +--- a/dlls/winegstreamer/winegstreamer.spec ++++ b/dlls/winegstreamer/winegstreamer.spec +@@ -2,5 +2,4 @@ + @ stdcall -private DllGetClassObject(ptr ptr ptr) + @ stdcall -private DllRegisterServer() + @ stdcall -private DllUnregisterServer() +-@ stdcall winegstreamer_create_wm_async_reader(ptr) + @ stdcall winegstreamer_create_wm_sync_reader(ptr) +diff --git a/dlls/wmvcore/Makefile.in b/dlls/wmvcore/Makefile.in +index 6aed828abae..d0b230dd7c0 100644 +--- a/dlls/wmvcore/Makefile.in ++++ b/dlls/wmvcore/Makefile.in +@@ -6,6 +6,7 @@ DELAYIMPORTS = winegstreamer + EXTRADLLFLAGS = -Wb,--prefer-native + + C_SRCS = \ ++ reader.c \ + wmvcore_main.c \ + writer.c + +diff --git a/dlls/winegstreamer/wm_asyncreader.c b/dlls/wmvcore/reader.c +similarity index 98% +rename from dlls/winegstreamer/wm_asyncreader.c +rename to dlls/wmvcore/reader.c +index d3fd1624f24..12ba8099ab1 100644 +--- a/dlls/winegstreamer/wm_asyncreader.c ++++ b/dlls/wmvcore/reader.c +@@ -16,8 +16,11 @@ + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +-#include "gst_private.h" ++#include "wmvcore.h" ++ + #include "wmsdk.h" ++#include "wine/debug.h" ++#include "wine/heap.h" + + WINE_DEFAULT_DEBUG_CHANNEL(wmvcore); + +@@ -150,7 +153,7 @@ static ULONG WINAPI WMReader_Release(IWMReader *iface) + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) +- free(This); ++ heap_free(This); + + return ref; + } +@@ -2036,31 +2039,36 @@ static const IWMPacketSize2Vtbl WMPacketSize2Vtbl = + packetsize_SetMinPacketSize + }; + +-HRESULT WINAPI winegstreamer_create_wm_async_reader(IWMReader **reader) ++HRESULT WINAPI WMCreateReader(IUnknown *reserved, DWORD rights, IWMReader **ret_reader) + { +- WMReader *object; ++ WMReader *reader; + +- TRACE("reader %p.\n", reader); ++ TRACE("(%p, %x, %p)\n", reserved, rights, ret_reader); + +- if (!(object = calloc(1, sizeof(*object)))) ++ reader = heap_alloc(sizeof(*reader)); ++ if(!reader) + return E_OUTOFMEMORY; + +- object->IReferenceClock_iface.lpVtbl = &ReferenceClockVtbl; +- object->IWMHeaderInfo3_iface.lpVtbl = &WMHeaderInfo3Vtbl; +- object->IWMLanguageList_iface.lpVtbl = &WMLanguageListVtbl; +- object->IWMPacketSize2_iface.lpVtbl = &WMPacketSize2Vtbl; +- object->IWMProfile3_iface.lpVtbl = &WMProfile3Vtbl; +- object->IWMReader_iface.lpVtbl = &WMReaderVtbl; +- object->IWMReaderAdvanced6_iface.lpVtbl = &WMReaderAdvanced6Vtbl; +- object->IWMReaderAccelerator_iface.lpVtbl = &WMReaderAcceleratorVtbl; +- object->IWMReaderNetworkConfig2_iface.lpVtbl = &WMReaderNetworkConfig2Vtbl; +- object->IWMReaderPlaylistBurn_iface.lpVtbl = &WMReaderPlaylistBurnVtbl; +- object->IWMReaderStreamClock_iface.lpVtbl = &WMReaderStreamClockVtbl; +- object->IWMReaderTimecode_iface.lpVtbl = &WMReaderTimecodeVtbl; +- object->IWMReaderTypeNegotiation_iface.lpVtbl = &WMReaderTypeNegotiationVtbl; +- object->ref = 1; +- +- TRACE("Created async reader %p.\n", object); +- *reader = (IWMReader *)&object->IWMReader_iface; ++ reader->IWMReader_iface.lpVtbl = &WMReaderVtbl; ++ reader->IWMReaderAdvanced6_iface.lpVtbl = &WMReaderAdvanced6Vtbl; ++ reader->IWMReaderAccelerator_iface.lpVtbl = &WMReaderAcceleratorVtbl; ++ reader->IWMReaderNetworkConfig2_iface.lpVtbl = &WMReaderNetworkConfig2Vtbl; ++ reader->IWMReaderStreamClock_iface.lpVtbl = &WMReaderStreamClockVtbl; ++ reader->IWMReaderTypeNegotiation_iface.lpVtbl = &WMReaderTypeNegotiationVtbl; ++ reader->IWMReaderTimecode_iface.lpVtbl = &WMReaderTimecodeVtbl; ++ reader->IWMReaderPlaylistBurn_iface.lpVtbl = &WMReaderPlaylistBurnVtbl; ++ reader->IWMHeaderInfo3_iface.lpVtbl = &WMHeaderInfo3Vtbl; ++ reader->IWMLanguageList_iface.lpVtbl = &WMLanguageListVtbl; ++ reader->IReferenceClock_iface.lpVtbl = &ReferenceClockVtbl; ++ reader->IWMProfile3_iface.lpVtbl = &WMProfile3Vtbl; ++ reader->IWMPacketSize2_iface.lpVtbl = &WMPacketSize2Vtbl; ++ reader->ref = 1; ++ ++ *ret_reader = &reader->IWMReader_iface; + return S_OK; + } ++ ++HRESULT WINAPI WMCreateReaderPriv(IWMReader **ret_reader) ++{ ++ return WMCreateReader(NULL, 0, ret_reader); ++} +diff --git a/dlls/wmvcore/wmvcore_main.c b/dlls/wmvcore/wmvcore_main.c +index ff837921286..8d4d4251369 100644 +--- a/dlls/wmvcore/wmvcore_main.c ++++ b/dlls/wmvcore/wmvcore_main.c +@@ -25,23 +25,8 @@ + + WINE_DEFAULT_DEBUG_CHANNEL(wmvcore); + +-HRESULT WINAPI winegstreamer_create_wm_async_reader(IWMReader **reader); + HRESULT WINAPI winegstreamer_create_wm_sync_reader(IWMSyncReader **reader); + +-HRESULT WINAPI WMCreateReader(IUnknown *reserved, DWORD rights, IWMReader **reader) +-{ +- TRACE("reserved %p, rights %#x, reader %p.\n", reserved, rights, reader); +- +- return winegstreamer_create_wm_async_reader(reader); +-} +- +-HRESULT WINAPI WMCreateReaderPriv(IWMReader **reader) +-{ +- TRACE("reader %p.\n", reader); +- +- return winegstreamer_create_wm_async_reader(reader); +-} +- + HRESULT WINAPI WMCreateSyncReader(IUnknown *reserved, DWORD rights, IWMSyncReader **reader) + { + TRACE("reserved %p, rights %#x, reader %p.\n", reserved, rights, reader); +-- +2.33.0 + diff --git a/patches/mfplat-reverts/0003-Revert-winegstreamer-Get-rid-of-the-WMSyncReader-typ.patch b/patches/mfplat-reverts/0003-Revert-winegstreamer-Get-rid-of-the-WMSyncReader-typ.patch new file mode 100644 index 00000000..ae374c71 --- /dev/null +++ b/patches/mfplat-reverts/0003-Revert-winegstreamer-Get-rid-of-the-WMSyncReader-typ.patch @@ -0,0 +1,579 @@ +From 92f0e4d02787c066c9b58a661981723f26c8e123 Mon Sep 17 00:00:00 2001 +From: Alistair Leslie-Hughes +Date: Sat, 9 Oct 2021 13:47:41 +1100 +Subject: [PATCH 03/22] Revert "winegstreamer: Get rid of the WMSyncReader + typedef." + +This reverts commit ba3fa4254b3c336b171c9d47de677c2d9b277cdc. +--- + dlls/winegstreamer/wm_syncreader.c | 143 ++++++++++++++--------------- + 1 file changed, 71 insertions(+), 72 deletions(-) + +diff --git a/dlls/winegstreamer/wm_syncreader.c b/dlls/winegstreamer/wm_syncreader.c +index 1d65820aa02..75b8e021148 100644 +--- a/dlls/winegstreamer/wm_syncreader.c ++++ b/dlls/winegstreamer/wm_syncreader.c +@@ -22,21 +22,20 @@ + + WINE_DEFAULT_DEBUG_CHANNEL(wmvcore); + +-struct sync_reader +-{ ++typedef struct { + IWMProfile3 IWMProfile3_iface; + IWMSyncReader2 IWMSyncReader2_iface; + LONG ref; +-}; ++} WMSyncReader; + +-static struct sync_reader *impl_from_IWMSyncReader2(IWMSyncReader2 *iface) ++static inline WMSyncReader *impl_from_IWMSyncReader2(IWMSyncReader2 *iface) + { +- return CONTAINING_RECORD(iface, struct sync_reader, IWMSyncReader2_iface); ++ return CONTAINING_RECORD(iface, WMSyncReader, IWMSyncReader2_iface); + } + + static HRESULT WINAPI WMSyncReader_QueryInterface(IWMSyncReader2 *iface, REFIID riid, void **ppv) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + + if(IsEqualGUID(riid, &IID_IUnknown)) { + TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); +@@ -68,7 +67,7 @@ static HRESULT WINAPI WMSyncReader_QueryInterface(IWMSyncReader2 *iface, REFIID + + static ULONG WINAPI WMSyncReader_AddRef(IWMSyncReader2 *iface) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + LONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); +@@ -78,7 +77,7 @@ static ULONG WINAPI WMSyncReader_AddRef(IWMSyncReader2 *iface) + + static ULONG WINAPI WMSyncReader_Release(IWMSyncReader2 *iface) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + LONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); +@@ -91,21 +90,21 @@ static ULONG WINAPI WMSyncReader_Release(IWMSyncReader2 *iface) + + static HRESULT WINAPI WMSyncReader_Close(IWMSyncReader2 *iface) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p): stub!\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_GetMaxOutputSampleSize(IWMSyncReader2 *iface, DWORD output, DWORD *max) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, output, max); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_GetMaxStreamSampleSize(IWMSyncReader2 *iface, WORD stream, DWORD *max) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, stream, max); + return E_NOTIMPL; + } +@@ -113,7 +112,7 @@ static HRESULT WINAPI WMSyncReader_GetMaxStreamSampleSize(IWMSyncReader2 *iface, + static HRESULT WINAPI WMSyncReader_GetNextSample(IWMSyncReader2 *iface, WORD stream, INSSBuffer **sample, + QWORD *sample_time, QWORD *sample_duration, DWORD *flags, DWORD *output_num, WORD *stream_num) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p %p %p %p %p %p): stub!\n", This, stream, sample, sample_time, + sample_duration, flags, output_num, stream_num); + return E_NOTIMPL; +@@ -121,7 +120,7 @@ static HRESULT WINAPI WMSyncReader_GetNextSample(IWMSyncReader2 *iface, WORD str + + static HRESULT WINAPI WMSyncReader_GetOutputCount(IWMSyncReader2 *iface, DWORD *outputs) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%p): stub!\n", This, outputs); + return E_NOTIMPL; + } +@@ -129,28 +128,28 @@ static HRESULT WINAPI WMSyncReader_GetOutputCount(IWMSyncReader2 *iface, DWORD * + static HRESULT WINAPI WMSyncReader_GetOutputFormat(IWMSyncReader2 *iface, DWORD output_num, DWORD format_num, + IWMOutputMediaProps **props) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %u %p): stub!\n", This, output_num, format_num, props); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_GetOutputFormatCount(IWMSyncReader2 *iface, DWORD output_num, DWORD *formats) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %p): stub!\n", This, output_num, formats); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_GetOutputNumberForStream(IWMSyncReader2 *iface, WORD stream_num, DWORD *output_num) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %p): stub!\n", This, stream_num, output_num); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_GetOutputProps(IWMSyncReader2 *iface, DWORD output_num, IWMOutputMediaProps **output) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %p): stub!\n", This, output_num, output); + return E_NOTIMPL; + } +@@ -158,49 +157,49 @@ static HRESULT WINAPI WMSyncReader_GetOutputProps(IWMSyncReader2 *iface, DWORD o + static HRESULT WINAPI WMSyncReader_GetOutputSetting(IWMSyncReader2 *iface, DWORD output_num, const WCHAR *name, + WMT_ATTR_DATATYPE *type, BYTE *value, WORD *length) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %s %p %p %p): stub!\n", This, output_num, debugstr_w(name), type, value, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_GetReadStreamSamples(IWMSyncReader2 *iface, WORD stream_num, BOOL *compressed) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, stream_num, compressed); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_GetStreamNumberForOutput(IWMSyncReader2 *iface, DWORD output, WORD *stream_num) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %p): stub!\n", This, output, stream_num); + return S_OK; + } + + static HRESULT WINAPI WMSyncReader_GetStreamSelected(IWMSyncReader2 *iface, WORD stream_num, WMT_STREAM_SELECTION *selection) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, stream_num, selection); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_Open(IWMSyncReader2 *iface, const WCHAR *filename) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%s): stub!\n", This, debugstr_w(filename)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_OpenStream(IWMSyncReader2 *iface, IStream *stream) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%p): stub!\n", This, stream); + return S_OK; + } + + static HRESULT WINAPI WMSyncReader_SetOutputProps(IWMSyncReader2 *iface, DWORD output_num, IWMOutputMediaProps *output) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %p): stub!\n", This, output_num, output); + return E_NOTIMPL; + } +@@ -208,14 +207,14 @@ static HRESULT WINAPI WMSyncReader_SetOutputProps(IWMSyncReader2 *iface, DWORD o + static HRESULT WINAPI WMSyncReader_SetOutputSetting(IWMSyncReader2 *iface, DWORD output_num, const WCHAR *name, + WMT_ATTR_DATATYPE type, const BYTE *value, WORD length) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %s %d %p %d): stub!\n", This, output_num, debugstr_w(name), type, value, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_SetRange(IWMSyncReader2 *iface, QWORD start, LONGLONG duration) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%s %s): stub!\n", This, wine_dbgstr_longlong(start), wine_dbgstr_longlong(duration)); + return E_NOTIMPL; + } +@@ -223,14 +222,14 @@ static HRESULT WINAPI WMSyncReader_SetRange(IWMSyncReader2 *iface, QWORD start, + static HRESULT WINAPI WMSyncReader_SetRangeByFrame(IWMSyncReader2 *iface, WORD stream_num, QWORD frame_num, + LONGLONG frames) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %s %s): stub!\n", This, stream_num, wine_dbgstr_longlong(frame_num), wine_dbgstr_longlong(frames)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader_SetReadStreamSamples(IWMSyncReader2 *iface, WORD stream_num, BOOL compressed) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %x): stub!\n", This, stream_num, compressed); + return E_NOTIMPL; + } +@@ -238,7 +237,7 @@ static HRESULT WINAPI WMSyncReader_SetReadStreamSamples(IWMSyncReader2 *iface, W + static HRESULT WINAPI WMSyncReader_SetStreamsSelected(IWMSyncReader2 *iface, WORD stream_count, + WORD *stream_numbers, WMT_STREAM_SELECTION *selections) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p %p): stub!\n", This, stream_count, stream_numbers, selections); + return S_OK; + } +@@ -246,7 +245,7 @@ static HRESULT WINAPI WMSyncReader_SetStreamsSelected(IWMSyncReader2 *iface, WOR + static HRESULT WINAPI WMSyncReader2_SetRangeByTimecode(IWMSyncReader2 *iface, WORD stream_num, + WMT_TIMECODE_EXTENSION_DATA *start, WMT_TIMECODE_EXTENSION_DATA *end) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %p %p): stub!\n", This, stream_num, start, end); + return E_NOTIMPL; + } +@@ -254,7 +253,7 @@ static HRESULT WINAPI WMSyncReader2_SetRangeByTimecode(IWMSyncReader2 *iface, WO + static HRESULT WINAPI WMSyncReader2_SetRangeByFrameEx(IWMSyncReader2 *iface, WORD stream_num, QWORD frame_num, + LONGLONG frames_to_read, QWORD *starttime) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%u %s %s %p): stub!\n", This, stream_num, wine_dbgstr_longlong(frame_num), + wine_dbgstr_longlong(frames_to_read), starttime); + return E_NOTIMPL; +@@ -262,28 +261,28 @@ static HRESULT WINAPI WMSyncReader2_SetRangeByFrameEx(IWMSyncReader2 *iface, WOR + + static HRESULT WINAPI WMSyncReader2_SetAllocateForOutput(IWMSyncReader2 *iface, DWORD output_num, IWMReaderAllocatorEx *allocator) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, output_num, allocator); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader2_GetAllocateForOutput(IWMSyncReader2 *iface, DWORD output_num, IWMReaderAllocatorEx **allocator) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, output_num, allocator); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader2_SetAllocateForStream(IWMSyncReader2 *iface, DWORD stream_num, IWMReaderAllocatorEx *allocator) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, stream_num, allocator); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMSyncReader2_GetAllocateForStream(IWMSyncReader2 *iface, DWORD stream_num, IWMReaderAllocatorEx **allocator) + { +- struct sync_reader *This = impl_from_IWMSyncReader2(iface); ++ WMSyncReader *This = impl_from_IWMSyncReader2(iface); + FIXME("(%p)->(%d %p): stub!\n", This, stream_num, allocator); + return E_NOTIMPL; + } +@@ -321,67 +320,67 @@ static const IWMSyncReader2Vtbl WMSyncReader2Vtbl = { + WMSyncReader2_GetAllocateForStream + }; + +-static struct sync_reader *impl_from_IWMProfile3(IWMProfile3 *iface) ++static inline WMSyncReader *impl_from_IWMProfile3(IWMProfile3 *iface) + { +- return CONTAINING_RECORD(iface, struct sync_reader, IWMProfile3_iface); ++ return CONTAINING_RECORD(iface, WMSyncReader, IWMProfile3_iface); + } + + static HRESULT WINAPI WMProfile_QueryInterface(IWMProfile3 *iface, REFIID riid, void **ppv) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + return IWMSyncReader2_QueryInterface(&This->IWMSyncReader2_iface, riid, ppv); + } + + static ULONG WINAPI WMProfile_AddRef(IWMProfile3 *iface) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + return IWMSyncReader2_AddRef(&This->IWMSyncReader2_iface); + } + + static ULONG WINAPI WMProfile_Release(IWMProfile3 *iface) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + return IWMSyncReader2_Release(&This->IWMSyncReader2_iface); + } + + static HRESULT WINAPI WMProfile_GetVersion(IWMProfile3 *iface, WMT_VERSION *version) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, version); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_GetName(IWMProfile3 *iface, WCHAR *name, DWORD *length) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p, %p\n", This, name, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_SetName(IWMProfile3 *iface, const WCHAR *name) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s\n", This, debugstr_w(name)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_GetDescription(IWMProfile3 *iface, WCHAR *description, DWORD *length) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p, %p\n", This, description, length); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_SetDescription(IWMProfile3 *iface, const WCHAR *description) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s\n", This, debugstr_w(description)); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_GetStreamCount(IWMProfile3 *iface, DWORD *count) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, count); + + if (!count) +@@ -393,175 +392,175 @@ static HRESULT WINAPI WMProfile_GetStreamCount(IWMProfile3 *iface, DWORD *count) + + static HRESULT WINAPI WMProfile_GetStream(IWMProfile3 *iface, DWORD index, IWMStreamConfig **config) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, index, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_GetStreamByNumber(IWMProfile3 *iface, WORD stream, IWMStreamConfig **config) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, stream, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_RemoveStream(IWMProfile3 *iface, IWMStreamConfig *config) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_RemoveStreamByNumber(IWMProfile3 *iface, WORD stream) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_AddStream(IWMProfile3 *iface, IWMStreamConfig *config) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_ReconfigStream(IWMProfile3 *iface, IWMStreamConfig *config) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, config); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_CreateNewStream(IWMProfile3 *iface, REFGUID type, IWMStreamConfig **config) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s, %p\n", This, debugstr_guid(type), config); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_GetMutualExclusionCount(IWMProfile3 *iface, DWORD *count) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, count); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_GetMutualExclusion(IWMProfile3 *iface, DWORD index, IWMMutualExclusion **mutual) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, index, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_RemoveMutualExclusion(IWMProfile3 *iface, IWMMutualExclusion *mutual) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_AddMutualExclusion(IWMProfile3 *iface, IWMMutualExclusion *mutual) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile_CreateNewMutualExclusion(IWMProfile3 *iface, IWMMutualExclusion **mutual) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, mutual); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile2_GetProfileID(IWMProfile3 *iface, GUID *guid) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, guid); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_GetStorageFormat(IWMProfile3 *iface, WMT_STORAGE_FORMAT *storage) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, storage); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_SetStorageFormat(IWMProfile3 *iface, WMT_STORAGE_FORMAT storage) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d\n", This, storage); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_GetBandwidthSharingCount(IWMProfile3 *iface, DWORD *count) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, count); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_GetBandwidthSharing(IWMProfile3 *iface, DWORD index, IWMBandwidthSharing **bandwidth) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %d, %p\n", This, index, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_RemoveBandwidthSharing( IWMProfile3 *iface, IWMBandwidthSharing *bandwidth) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_AddBandwidthSharing(IWMProfile3 *iface, IWMBandwidthSharing *bandwidth) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_CreateNewBandwidthSharing( IWMProfile3 *iface, IWMBandwidthSharing **bandwidth) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, bandwidth); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_GetStreamPrioritization(IWMProfile3 *iface, IWMStreamPrioritization **stream) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_SetStreamPrioritization(IWMProfile3 *iface, IWMStreamPrioritization *stream) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_RemoveStreamPrioritization(IWMProfile3 *iface) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p\n", This); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_CreateNewStreamPrioritization(IWMProfile3 *iface, IWMStreamPrioritization **stream) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %p\n", This, stream); + return E_NOTIMPL; + } + + static HRESULT WINAPI WMProfile3_GetExpectedPacketCount(IWMProfile3 *iface, QWORD duration, QWORD *packets) + { +- struct sync_reader *This = impl_from_IWMProfile3(iface); ++ WMSyncReader *This = impl_from_IWMProfile3(iface); + FIXME("%p, %s, %p\n", This, wine_dbgstr_longlong(duration), packets); + return E_NOTIMPL; + } +@@ -606,7 +605,7 @@ static const IWMProfile3Vtbl WMProfile3Vtbl = + + HRESULT WINAPI winegstreamer_create_wm_sync_reader(IWMSyncReader **reader) + { +- struct sync_reader *object; ++ WMSyncReader *object; + + TRACE("reader %p.\n", reader); + +-- +2.33.0 + diff --git a/patches/mfplat-reverts/0004-Revert-wmvcore-Move-the-sync-reader-implementation-t.patch b/patches/mfplat-reverts/0004-Revert-wmvcore-Move-the-sync-reader-implementation-t.patch new file mode 100644 index 00000000..fc071f17 --- /dev/null +++ b/patches/mfplat-reverts/0004-Revert-wmvcore-Move-the-sync-reader-implementation-t.patch @@ -0,0 +1,161 @@ +From 59b60c9a19de54bc0f6541395ffcf49d96437b8c Mon Sep 17 00:00:00 2001 +From: Alistair Leslie-Hughes +Date: Sat, 9 Oct 2021 13:47:42 +1100 +Subject: [PATCH 04/22] Revert "wmvcore: Move the sync reader implementation to + winegstreamer." + +This reverts commit e4767ea6126fce8b419ef10a3cfce8bf43206d6f. +--- + dlls/winegstreamer/Makefile.in | 4 +-- + dlls/winegstreamer/winegstreamer.spec | 1 - + dlls/wmvcore/Makefile.in | 2 +- + .../wm_syncreader.c => wmvcore/syncreader.c} | 33 ++++++++++++------- + dlls/wmvcore/wmvcore_main.c | 16 --------- + 5 files changed, 23 insertions(+), 33 deletions(-) + rename dlls/{winegstreamer/wm_syncreader.c => wmvcore/syncreader.c} (96%) + +diff --git a/dlls/winegstreamer/Makefile.in b/dlls/winegstreamer/Makefile.in +index 671e3bcb7ba..e35df3cf3f9 100644 +--- a/dlls/winegstreamer/Makefile.in ++++ b/dlls/winegstreamer/Makefile.in +@@ -1,6 +1,5 @@ + MODULE = winegstreamer.dll + UNIXLIB = winegstreamer.so +-IMPORTLIB = winegstreamer + IMPORTS = strmbase strmiids uuid ole32 mfuuid + DELAYIMPORTS = mfplat + EXTRAINCL = $(GSTREAMER_CFLAGS) +@@ -12,8 +11,7 @@ C_SRCS = \ + media_source.c \ + mfplat.c \ + quartz_parser.c \ +- wg_parser.c \ +- wm_syncreader.c ++ wg_parser.c + + IDL_SRCS = \ + winegstreamer_classes.idl +diff --git a/dlls/winegstreamer/winegstreamer.spec b/dlls/winegstreamer/winegstreamer.spec +index bd9f53a7445..b16365d0c9f 100644 +--- a/dlls/winegstreamer/winegstreamer.spec ++++ b/dlls/winegstreamer/winegstreamer.spec +@@ -2,4 +2,3 @@ + @ stdcall -private DllGetClassObject(ptr ptr ptr) + @ stdcall -private DllRegisterServer() + @ stdcall -private DllUnregisterServer() +-@ stdcall winegstreamer_create_wm_sync_reader(ptr) +diff --git a/dlls/wmvcore/Makefile.in b/dlls/wmvcore/Makefile.in +index d0b230dd7c0..15c017f86d9 100644 +--- a/dlls/wmvcore/Makefile.in ++++ b/dlls/wmvcore/Makefile.in +@@ -1,12 +1,12 @@ + MODULE = wmvcore.dll + IMPORTLIB = wmvcore + IMPORTS = kernel32 +-DELAYIMPORTS = winegstreamer + + EXTRADLLFLAGS = -Wb,--prefer-native + + C_SRCS = \ + reader.c \ ++ syncreader.c \ + wmvcore_main.c \ + writer.c + +diff --git a/dlls/winegstreamer/wm_syncreader.c b/dlls/wmvcore/syncreader.c +similarity index 96% +rename from dlls/winegstreamer/wm_syncreader.c +rename to dlls/wmvcore/syncreader.c +index 75b8e021148..b245ff20d31 100644 +--- a/dlls/winegstreamer/wm_syncreader.c ++++ b/dlls/wmvcore/syncreader.c +@@ -16,9 +16,11 @@ + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +-#include "gst_private.h" +-#include "initguid.h" ++#include "wmvcore.h" ++ + #include "wmsdk.h" ++#include "wine/debug.h" ++#include "wine/heap.h" + + WINE_DEFAULT_DEBUG_CHANNEL(wmvcore); + +@@ -83,7 +85,7 @@ static ULONG WINAPI WMSyncReader_Release(IWMSyncReader2 *iface) + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) +- free(This); ++ heap_free(This); + + return ref; + } +@@ -603,20 +605,27 @@ static const IWMProfile3Vtbl WMProfile3Vtbl = + WMProfile3_GetExpectedPacketCount + }; + +-HRESULT WINAPI winegstreamer_create_wm_sync_reader(IWMSyncReader **reader) ++HRESULT WINAPI WMCreateSyncReader(IUnknown *pcert, DWORD rights, IWMSyncReader **syncreader) + { +- WMSyncReader *object; ++ WMSyncReader *sync; ++ ++ TRACE("(%p, %x, %p)\n", pcert, rights, syncreader); + +- TRACE("reader %p.\n", reader); ++ sync = heap_alloc(sizeof(*sync)); + +- if (!(object = calloc(1, sizeof(*object)))) ++ if (!sync) + return E_OUTOFMEMORY; + +- object->IWMProfile3_iface.lpVtbl = &WMProfile3Vtbl; +- object->IWMSyncReader2_iface.lpVtbl = &WMSyncReader2Vtbl; +- object->ref = 1; ++ sync->IWMProfile3_iface.lpVtbl = &WMProfile3Vtbl; ++ sync->IWMSyncReader2_iface.lpVtbl = &WMSyncReader2Vtbl; ++ sync->ref = 1; ++ ++ *syncreader = (IWMSyncReader *)&sync->IWMSyncReader2_iface; + +- TRACE("Created sync reader %p.\n", object); +- *reader = (IWMSyncReader *)&object->IWMSyncReader2_iface; + return S_OK; + } ++ ++HRESULT WINAPI WMCreateSyncReaderPriv(IWMSyncReader **syncreader) ++{ ++ return WMCreateSyncReader(NULL, 0, syncreader); ++} +diff --git a/dlls/wmvcore/wmvcore_main.c b/dlls/wmvcore/wmvcore_main.c +index 8d4d4251369..5f93fc68e3b 100644 +--- a/dlls/wmvcore/wmvcore_main.c ++++ b/dlls/wmvcore/wmvcore_main.c +@@ -25,22 +25,6 @@ + + WINE_DEFAULT_DEBUG_CHANNEL(wmvcore); + +-HRESULT WINAPI winegstreamer_create_wm_sync_reader(IWMSyncReader **reader); +- +-HRESULT WINAPI WMCreateSyncReader(IUnknown *reserved, DWORD rights, IWMSyncReader **reader) +-{ +- TRACE("reserved %p, rights %#x, reader %p.\n", reserved, rights, reader); +- +- return winegstreamer_create_wm_sync_reader(reader); +-} +- +-HRESULT WINAPI WMCreateSyncReaderPriv(IWMSyncReader **reader) +-{ +- TRACE("reader %p.\n", reader); +- +- return winegstreamer_create_wm_sync_reader(reader); +-} +- + HRESULT WINAPI WMCheckURLExtension(const WCHAR *url) + { + FIXME("(%s): stub\n", wine_dbgstr_w(url)); +-- +2.33.0 + diff --git a/patches/mfplat-reverts/0005-Revert-winegstreamer-Translate-GST_AUDIO_CHANNEL_POS.patch b/patches/mfplat-reverts/0005-Revert-winegstreamer-Translate-GST_AUDIO_CHANNEL_POS.patch new file mode 100644 index 00000000..d6511e74 --- /dev/null +++ b/patches/mfplat-reverts/0005-Revert-winegstreamer-Translate-GST_AUDIO_CHANNEL_POS.patch @@ -0,0 +1,30 @@ +From 6bde437d76c256778d706da4874a4db2a37e0e3a Mon Sep 17 00:00:00 2001 +From: Alistair Leslie-Hughes +Date: Sat, 9 Oct 2021 13:47:44 +1100 +Subject: [PATCH 05/22] Revert "winegstreamer: Translate + GST_AUDIO_CHANNEL_POSITION_MONO to SPEAKER_FRONT_CENTER." + +This reverts commit 009c1d66fa202666f778d7df2bbcc522993935cf. +--- + dlls/winegstreamer/wg_parser.c | 5 +---- + 1 file changed, 1 insertion(+), 4 deletions(-) + +diff --git a/dlls/winegstreamer/wg_parser.c b/dlls/winegstreamer/wg_parser.c +index c3c9051a174..0c23ae6d351 100644 +--- a/dlls/winegstreamer/wg_parser.c ++++ b/dlls/winegstreamer/wg_parser.c +@@ -159,10 +159,7 @@ static uint32_t wg_channel_position_from_gst(GstAudioChannelPosition position) + SPEAKER_TOP_BACK_CENTER, + }; + +- if (position == GST_AUDIO_CHANNEL_POSITION_MONO) +- return SPEAKER_FRONT_CENTER; +- +- if (position >= 0 && position < ARRAY_SIZE(position_map)) ++ if (position < ARRAY_SIZE(position_map)) + return position_map[position]; + return 0; + } +-- +2.33.0 + diff --git a/patches/mfplat-reverts/0001-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch b/patches/mfplat-reverts/0006-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch similarity index 89% rename from patches/mfplat-reverts/0001-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch rename to patches/mfplat-reverts/0006-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch index 4a1e0c28..13b08d73 100644 --- a/patches/mfplat-reverts/0001-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch +++ b/patches/mfplat-reverts/0006-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch @@ -1,7 +1,7 @@ -From c7cefd4d7ba969969ad31baa4e05c3968c5ae01c Mon Sep 17 00:00:00 2001 +From 0cc0b9856041daede1d49ce5ba3bde736edd0a92 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Thu, 7 Oct 2021 09:00:38 +1100 -Subject: [PATCH 01/17] Revert "winegstreamer: Trace the unfiltered caps in +Subject: [PATCH 06/22] Revert "winegstreamer: Trace the unfiltered caps in sink_query_cb()." This reverts commit fd6315eb8f6809b89b7449f4b9dd01453de32eda. diff --git a/patches/mfplat-reverts/0002-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch b/patches/mfplat-reverts/0007-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch similarity index 88% rename from patches/mfplat-reverts/0002-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch rename to patches/mfplat-reverts/0007-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch index 57bb86fa..5760be1e 100644 --- a/patches/mfplat-reverts/0002-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch +++ b/patches/mfplat-reverts/0007-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch @@ -1,7 +1,7 @@ -From 8750208931f96be6f30a13f033658eb92a51a8ef Mon Sep 17 00:00:00 2001 +From dd5d76af94c794f9679c29bec0dc436bfaa78edc Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Thu, 7 Oct 2021 09:00:39 +1100 -Subject: [PATCH 02/17] Revert "winegstreamer: Avoid seeking past the end of an +Subject: [PATCH 07/22] Revert "winegstreamer: Avoid seeking past the end of an IMFByteStream." This reverts commit 3efb72de5aca01d3d979ce697728e51bc3e99901. diff --git a/patches/mfplat-reverts/0003-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch b/patches/mfplat-reverts/0008-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch similarity index 92% rename from patches/mfplat-reverts/0003-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch rename to patches/mfplat-reverts/0008-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch index eb21d317..196ae4b6 100644 --- a/patches/mfplat-reverts/0003-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch +++ b/patches/mfplat-reverts/0008-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch @@ -1,7 +1,7 @@ -From 111eb77f0dc9fcf241167dec1656818e7a636f0a Mon Sep 17 00:00:00 2001 +From 9d20d8d508a65ef044a3d903eb2c96e9b4d08429 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Thu, 7 Oct 2021 09:00:39 +1100 -Subject: [PATCH 03/17] Revert "winegstreamer: Avoid passing a NULL buffer to +Subject: [PATCH 08/22] Revert "winegstreamer: Avoid passing a NULL buffer to wg_parser_push_data() in the case of a zero-length read." This reverts commit 585acfa04188f85fb9138e57d56dd44b870dca41. diff --git a/patches/mfplat-reverts/0004-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch b/patches/mfplat-reverts/0009-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch similarity index 96% rename from patches/mfplat-reverts/0004-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch rename to patches/mfplat-reverts/0009-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch index f013a431..00bc90c0 100644 --- a/patches/mfplat-reverts/0004-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch +++ b/patches/mfplat-reverts/0009-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch @@ -1,7 +1,7 @@ -From 6b2ebf10c196d3ced85546af54599071d750bb1d Mon Sep 17 00:00:00 2001 +From 997978816252d56a53b53d8d0a1913f78b3aad42 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Thu, 7 Oct 2021 09:00:40 +1100 -Subject: [PATCH 04/17] Revert "winegstreamer: Use array_reserve() to +Subject: [PATCH 09/22] Revert "winegstreamer: Use array_reserve() to reallocate read buffers." This reverts commit 59997c355fdc9cb5857c767b3bf16c9513b3d1f3. diff --git a/patches/mfplat-reverts/0005-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch b/patches/mfplat-reverts/0010-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch similarity index 92% rename from patches/mfplat-reverts/0005-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch rename to patches/mfplat-reverts/0010-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch index 6ca397ba..38b92735 100644 --- a/patches/mfplat-reverts/0005-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch +++ b/patches/mfplat-reverts/0010-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch @@ -1,7 +1,7 @@ -From 611e86da3f0b7050cd10c6fa693e31d7f37d7a8a Mon Sep 17 00:00:00 2001 +From 6e82f802820e9ed145201091cd636f2e83d85e67 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Thu, 7 Oct 2021 09:00:41 +1100 -Subject: [PATCH 05/17] Revert "winegstreamer: Handle zero-length reads in +Subject: [PATCH 10/22] Revert "winegstreamer: Handle zero-length reads in src_getrange_cb()." This reverts commit 8e9d7b031f7b0c93471cfbffe8f720c34623a273. diff --git a/patches/mfplat-reverts/0006-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch b/patches/mfplat-reverts/0011-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch similarity index 99% rename from patches/mfplat-reverts/0006-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch rename to patches/mfplat-reverts/0011-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch index 7f69aa62..10e9264d 100644 --- a/patches/mfplat-reverts/0006-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch +++ b/patches/mfplat-reverts/0011-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch @@ -1,7 +1,7 @@ -From cbb33659c8d97084e41648dd6d093508d493ffd8 Mon Sep 17 00:00:00 2001 +From 29f82e04e5040e430628975484666aaecb74f311 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Wed, 6 Oct 2021 08:38:11 +1100 -Subject: [PATCH 06/17] Revert "winegstreamer: Convert the Unix library to the +Subject: [PATCH 11/22] Revert "winegstreamer: Convert the Unix library to the __wine_unix_call interface." This reverts commit 4ba31162c37ea237763e650f6242535d86ffb170. diff --git a/patches/mfplat-reverts/0007-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch b/patches/mfplat-reverts/0012-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch similarity index 96% rename from patches/mfplat-reverts/0007-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch rename to patches/mfplat-reverts/0012-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch index 40a23fdc..73f36c56 100644 --- a/patches/mfplat-reverts/0007-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch +++ b/patches/mfplat-reverts/0012-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch @@ -1,7 +1,7 @@ -From 3f0ae88023b048aa9ae2d942a7d38a305a70fde2 Mon Sep 17 00:00:00 2001 +From 3753c3b6c8c99a664430805c3e7bd7273064f379 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Wed, 6 Oct 2021 08:38:12 +1100 -Subject: [PATCH 07/17] Revert "winegstreamer: Return void from +Subject: [PATCH 12/22] Revert "winegstreamer: Return void from wg_parser_stream_seek()." This reverts commit 494039d0d0df8fd5b2b3442caac7bd6c0c7433c0. diff --git a/patches/mfplat-reverts/0008-Revert-winegstreamer-Move-Unix-library-definitions-i.patch b/patches/mfplat-reverts/0013-Revert-winegstreamer-Move-Unix-library-definitions-i.patch similarity index 98% rename from patches/mfplat-reverts/0008-Revert-winegstreamer-Move-Unix-library-definitions-i.patch rename to patches/mfplat-reverts/0013-Revert-winegstreamer-Move-Unix-library-definitions-i.patch index 07b8766d..e5144539 100644 --- a/patches/mfplat-reverts/0008-Revert-winegstreamer-Move-Unix-library-definitions-i.patch +++ b/patches/mfplat-reverts/0013-Revert-winegstreamer-Move-Unix-library-definitions-i.patch @@ -1,7 +1,7 @@ -From 2060f5090f7b51b46d791b6f7997857ea7dd2797 Mon Sep 17 00:00:00 2001 +From 79181b01cb2cb9c6cafd3ea08920e892e37cd654 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Wed, 6 Oct 2021 08:38:12 +1100 -Subject: [PATCH 08/17] Revert "winegstreamer: Move Unix library definitions +Subject: [PATCH 13/22] Revert "winegstreamer: Move Unix library definitions into a separate header." This reverts commit 84b870bb1fcac27288ed70d28de6a1c2649e9fe6. diff --git a/patches/mfplat-reverts/0009-Revert-winegstreamer-Remove-the-no-longer-used-start.patch b/patches/mfplat-reverts/0014-Revert-winegstreamer-Remove-the-no-longer-used-start.patch similarity index 87% rename from patches/mfplat-reverts/0009-Revert-winegstreamer-Remove-the-no-longer-used-start.patch rename to patches/mfplat-reverts/0014-Revert-winegstreamer-Remove-the-no-longer-used-start.patch index 31e02bf4..e68a37b3 100644 --- a/patches/mfplat-reverts/0009-Revert-winegstreamer-Remove-the-no-longer-used-start.patch +++ b/patches/mfplat-reverts/0014-Revert-winegstreamer-Remove-the-no-longer-used-start.patch @@ -1,7 +1,7 @@ -From a0f69a9083c84afe21f397fdb4c7511cff4706cd Mon Sep 17 00:00:00 2001 +From d4afee5c3a6b8875563c3f931e3eaff3e55b87dc Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sat, 2 Oct 2021 10:35:45 +1000 -Subject: [PATCH 09/17] Revert "winegstreamer: Remove the no longer used +Subject: [PATCH 14/22] Revert "winegstreamer: Remove the no longer used start_dispatch_thread() declaration." This reverts commit a87abdbe85779adf6a2a7897bd88984587880693. diff --git a/patches/mfplat-reverts/0010-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch b/patches/mfplat-reverts/0015-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch similarity index 98% rename from patches/mfplat-reverts/0010-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch rename to patches/mfplat-reverts/0015-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch index 372f21de..8a0a979b 100644 --- a/patches/mfplat-reverts/0010-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch +++ b/patches/mfplat-reverts/0015-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch @@ -1,7 +1,7 @@ -From 49bb1f9a0024f79c5fc4bd015e87a94d9b088f3b Mon Sep 17 00:00:00 2001 +From 421567d9cdd09b1d9db8410160ac1c106a05f2f9 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sat, 2 Oct 2021 10:35:46 +1000 -Subject: [PATCH 10/17] Revert "winegstreamer: Set unlimited buffering using a +Subject: [PATCH 15/22] Revert "winegstreamer: Set unlimited buffering using a flag for wg_parser_create()." This reverts commit 45690320f933d68f613f95f0330098426fc5a08f. diff --git a/patches/mfplat-reverts/0011-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch b/patches/mfplat-reverts/0016-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch similarity index 95% rename from patches/mfplat-reverts/0011-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch rename to patches/mfplat-reverts/0016-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch index 894040a9..e389b122 100644 --- a/patches/mfplat-reverts/0011-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch +++ b/patches/mfplat-reverts/0016-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch @@ -1,7 +1,7 @@ -From a609f821cebb9005b52f5642c74d2e5d7a6a62c4 Mon Sep 17 00:00:00 2001 +From 1dd81b5b288ffe70164d06548cfcee61089ca0fd Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sat, 2 Oct 2021 10:35:47 +1000 -Subject: [PATCH 11/17] Revert "winegstreamer: Initialize GStreamer in +Subject: [PATCH 16/22] Revert "winegstreamer: Initialize GStreamer in wg_parser_create()." This reverts commit 3643f73ab61f05ddc9a637f8613c933dda0dd232. diff --git a/patches/mfplat-reverts/0012-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch b/patches/mfplat-reverts/0017-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch similarity index 98% rename from patches/mfplat-reverts/0012-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch rename to patches/mfplat-reverts/0017-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch index 521f6ce1..9950c368 100644 --- a/patches/mfplat-reverts/0012-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch +++ b/patches/mfplat-reverts/0017-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch @@ -1,7 +1,7 @@ -From 145dfaf9d560e16658710819e2b598e135ccb554 Mon Sep 17 00:00:00 2001 +From cf1958f12f33ec46546cac81d958cf38bf9245dc Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sat, 2 Oct 2021 10:35:47 +1000 -Subject: [PATCH 12/17] Revert "winegstreamer: Use a single wg_parser_create() +Subject: [PATCH 17/22] Revert "winegstreamer: Use a single wg_parser_create() entry point." This reverts commit eab189810d9c40c698bd049d9af647e195cd5993. diff --git a/patches/mfplat-reverts/0013-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch b/patches/mfplat-reverts/0018-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch similarity index 85% rename from patches/mfplat-reverts/0013-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch rename to patches/mfplat-reverts/0018-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch index 8fe23246..28dc680a 100644 --- a/patches/mfplat-reverts/0013-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch +++ b/patches/mfplat-reverts/0018-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch @@ -1,7 +1,7 @@ -From d32ea8a60ed0666a860e3bb6d8bb0c2f11fc80bd Mon Sep 17 00:00:00 2001 +From 5e55fd289a3baca9c53757c3b7ace7e5f51040f4 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sun, 19 Sep 2021 13:07:56 +1000 -Subject: [PATCH 13/17] Revert "winegstreamer: Fix return code in init_gst +Subject: [PATCH 18/22] Revert "winegstreamer: Fix return code in init_gst failure case." This reverts commit b9a7e961cdd39203866be38e90b1d901595d54ba. diff --git a/patches/mfplat-reverts/0014-Revert-winegstreamer-Allocate-source-media-buffers-i.patch b/patches/mfplat-reverts/0019-Revert-winegstreamer-Allocate-source-media-buffers-i.patch similarity index 98% rename from patches/mfplat-reverts/0014-Revert-winegstreamer-Allocate-source-media-buffers-i.patch rename to patches/mfplat-reverts/0019-Revert-winegstreamer-Allocate-source-media-buffers-i.patch index 09f662c2..b1eceb6e 100644 --- a/patches/mfplat-reverts/0014-Revert-winegstreamer-Allocate-source-media-buffers-i.patch +++ b/patches/mfplat-reverts/0019-Revert-winegstreamer-Allocate-source-media-buffers-i.patch @@ -1,7 +1,7 @@ -From cfc2e7689ca9832750e81e11bcff48715a8de778 Mon Sep 17 00:00:00 2001 +From eb244f666ec0ed78a7ca101f735c6555648c8da6 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sun, 19 Sep 2021 13:08:02 +1000 -Subject: [PATCH 14/17] Revert "winegstreamer: Allocate source media buffers in +Subject: [PATCH 19/22] Revert "winegstreamer: Allocate source media buffers in the PE components." This reverts commit 8b7390f80d866435f06f2571a93bcd67c0947673. diff --git a/patches/mfplat-reverts/0015-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch b/patches/mfplat-reverts/0020-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch similarity index 98% rename from patches/mfplat-reverts/0015-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch rename to patches/mfplat-reverts/0020-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch index 4600cd39..913ad4ad 100644 --- a/patches/mfplat-reverts/0015-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch +++ b/patches/mfplat-reverts/0020-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch @@ -1,7 +1,7 @@ -From 7ef1cf5893b686861b1704c9b87e2aa7ae29ce11 Mon Sep 17 00:00:00 2001 +From ee5ed3858dd7747358b2627511be3369f10a54c5 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sun, 19 Sep 2021 13:08:03 +1000 -Subject: [PATCH 15/17] Revert "winegstreamer: Duplicate source shutdown path +Subject: [PATCH 20/22] Revert "winegstreamer: Duplicate source shutdown path into constructor with leak fixes." This reverts commit 67734bfce31d6032cee1a8980a9022665e9e18fa. diff --git a/patches/mfplat-reverts/0016-Revert-winegstreamer-Properly-clean-up-from-failure-.patch b/patches/mfplat-reverts/0021-Revert-winegstreamer-Properly-clean-up-from-failure-.patch similarity index 97% rename from patches/mfplat-reverts/0016-Revert-winegstreamer-Properly-clean-up-from-failure-.patch rename to patches/mfplat-reverts/0021-Revert-winegstreamer-Properly-clean-up-from-failure-.patch index 61c6674e..14605c49 100644 --- a/patches/mfplat-reverts/0016-Revert-winegstreamer-Properly-clean-up-from-failure-.patch +++ b/patches/mfplat-reverts/0021-Revert-winegstreamer-Properly-clean-up-from-failure-.patch @@ -1,7 +1,7 @@ -From f47579e06833eeab21cb0ac30cd36bec8889a477 Mon Sep 17 00:00:00 2001 +From eb2329e6547f41329cb909f44fb05f7a8c2864ac Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sun, 19 Sep 2021 13:08:04 +1000 -Subject: [PATCH 16/17] Revert "winegstreamer: Properly clean up from failure +Subject: [PATCH 21/22] Revert "winegstreamer: Properly clean up from failure in wg_parser_connect()." This reverts commit 721b1eb2ebe5c3eaab8ac3fb1e4f4648cbee5b4d. diff --git a/patches/mfplat-reverts/0017-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch b/patches/mfplat-reverts/0022-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch similarity index 97% rename from patches/mfplat-reverts/0017-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch rename to patches/mfplat-reverts/0022-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch index 29762bcb..fea00b8e 100644 --- a/patches/mfplat-reverts/0017-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch +++ b/patches/mfplat-reverts/0022-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch @@ -1,7 +1,7 @@ -From d5ab02f7aaba148ecc74926d3fdda6484e74a646 Mon Sep 17 00:00:00 2001 +From 000e19a29821dbbe21534eb4b2a6d784001dbda2 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sun, 19 Sep 2021 13:08:05 +1000 -Subject: [PATCH 17/17] Revert "winegstreamer: Factor out more of the init_gst +Subject: [PATCH 22/22] Revert "winegstreamer: Factor out more of the init_gst callback into wg_parser_connect()." This reverts commit 830efe873a967dbbb0c9a65be6a66b124a5fa826. diff --git a/patches/mfplat-reverts/definition b/patches/mfplat-reverts/definition index 0198aede..bc488b8a 100644 --- a/patches/mfplat-reverts/definition +++ b/patches/mfplat-reverts/definition @@ -1,3 +1,2 @@ # This is just a revert of update mfplat patches until it's new versions # of the mfplat have been merged upstream. -Disabled: true \ No newline at end of file diff --git a/patches/mfplat-streaming-support/definition b/patches/mfplat-streaming-support/definition index 2d66342c..9ca1daa3 100644 --- a/patches/mfplat-streaming-support/definition +++ b/patches/mfplat-streaming-support/definition @@ -1,3 +1,2 @@ Fixes: [49692] Multiple applications need a Media Foundation media source implementation Depends: mfplat-reverts -Disabled: true \ No newline at end of file diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index 7954365d..a4780a89 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -51,7 +51,7 @@ usage() # Get the upstream commit sha upstream_commit() { - echo "5636088871714f2a2de9e543eb66f944ce188edc" + echo "7554bd4b41a1429517eb86fd20dbe813cdd0550a" } # Show version information @@ -135,6 +135,8 @@ patch_enable_all () enable_krnl386_exe16_Invalid_Console_Handles="$1" enable_libs_Unicode_Collation="$1" enable_loader_KeyboardLayouts="$1" + enable_mfplat_reverts="$1" + enable_mfplat_streaming_support="$1" enable_mmsystem_dll16_MIDIHDR_Refcount="$1" enable_mountmgr_DosDevices="$1" enable_mscoree_CorValidateImage="$1" @@ -440,6 +442,12 @@ patch_enable () loader-KeyboardLayouts) enable_loader_KeyboardLayouts="$2" ;; + mfplat-reverts) + enable_mfplat_reverts="$2" + ;; + mfplat-streaming-support) + enable_mfplat_streaming_support="$2" + ;; mmsystem.dll16-MIDIHDR_Refcount) enable_mmsystem_dll16_MIDIHDR_Refcount="$2" ;; @@ -1327,6 +1335,13 @@ if test "$enable_ntdll_WRITECOPY" -eq 1; then enable_ntdll_ForceBottomUpAlloc=1 fi +if test "$enable_mfplat_streaming_support" -eq 1; then + if test "$enable_mfplat_reverts" -gt 1; then + abort "Patchset mfplat-reverts disabled, but mfplat-streaming-support depends on that." + fi + enable_mfplat_reverts=1 +fi + if test "$enable_imm32_com_initialization" -eq 1; then if test "$enable_winex11__NET_ACTIVE_WINDOW" -gt 1; then abort "Patchset winex11-_NET_ACTIVE_WINDOW disabled, but imm32-com-initialization depends on that." @@ -2384,6 +2399,95 @@ if test "$enable_loader_KeyboardLayouts" -eq 1; then patch_apply loader-KeyboardLayouts/0002-user32-Improve-GetKeyboardLayoutList.patch fi +# Patchset mfplat-reverts +# | +# | Modified files: +# | * dlls/winegstreamer/Makefile.in, dlls/winegstreamer/gst_private.h, dlls/winegstreamer/main.c, +# | dlls/winegstreamer/media_source.c, dlls/winegstreamer/quartz_parser.c, dlls/winegstreamer/unixlib.h, +# | dlls/winegstreamer/wg_parser.c, dlls/winegstreamer/winegstreamer.spec, dlls/winegstreamer/wm_asyncreader.c, +# | dlls/winegstreamer/wm_syncreader.c, dlls/wmvcore/Makefile.in, dlls/wmvcore/reader.c, dlls/wmvcore/syncreader.c, +# | dlls/wmvcore/wmvcore_main.c +# | +if test "$enable_mfplat_reverts" -eq 1; then + patch_apply mfplat-reverts/0001-Revert-winegstreamer-Get-rid-of-the-WMReader-typedef.patch + patch_apply mfplat-reverts/0002-Revert-wmvcore-Move-the-async-reader-implementation-.patch + patch_apply mfplat-reverts/0003-Revert-winegstreamer-Get-rid-of-the-WMSyncReader-typ.patch + patch_apply mfplat-reverts/0004-Revert-wmvcore-Move-the-sync-reader-implementation-t.patch + patch_apply mfplat-reverts/0005-Revert-winegstreamer-Translate-GST_AUDIO_CHANNEL_POS.patch + patch_apply mfplat-reverts/0006-Revert-winegstreamer-Trace-the-unfiltered-caps-in-si.patch + patch_apply mfplat-reverts/0007-Revert-winegstreamer-Avoid-seeking-past-the-end-of-a.patch + patch_apply mfplat-reverts/0008-Revert-winegstreamer-Avoid-passing-a-NULL-buffer-to-.patch + patch_apply mfplat-reverts/0009-Revert-winegstreamer-Use-array_reserve-to-reallocate.patch + patch_apply mfplat-reverts/0010-Revert-winegstreamer-Handle-zero-length-reads-in-src.patch + patch_apply mfplat-reverts/0011-Revert-winegstreamer-Convert-the-Unix-library-to-the.patch + patch_apply mfplat-reverts/0012-Revert-winegstreamer-Return-void-from-wg_parser_stre.patch + patch_apply mfplat-reverts/0013-Revert-winegstreamer-Move-Unix-library-definitions-i.patch + patch_apply mfplat-reverts/0014-Revert-winegstreamer-Remove-the-no-longer-used-start.patch + patch_apply mfplat-reverts/0015-Revert-winegstreamer-Set-unlimited-buffering-using-a.patch + patch_apply mfplat-reverts/0016-Revert-winegstreamer-Initialize-GStreamer-in-wg_pars.patch + patch_apply mfplat-reverts/0017-Revert-winegstreamer-Use-a-single-wg_parser_create-e.patch + patch_apply mfplat-reverts/0018-Revert-winegstreamer-Fix-return-code-in-init_gst-fai.patch + patch_apply mfplat-reverts/0019-Revert-winegstreamer-Allocate-source-media-buffers-i.patch + patch_apply mfplat-reverts/0020-Revert-winegstreamer-Duplicate-source-shutdown-path-.patch + patch_apply mfplat-reverts/0021-Revert-winegstreamer-Properly-clean-up-from-failure-.patch + patch_apply mfplat-reverts/0022-Revert-winegstreamer-Factor-out-more-of-the-init_gst.patch +fi + +# Patchset mfplat-streaming-support +# | +# | This patchset has the following (direct or indirect) dependencies: +# | * mfplat-reverts +# | +# | This patchset fixes the following Wine bugs: +# | * [#49692] Multiple applications need a Media Foundation media source implementation +# | +# | Modified files: +# | * dlls/mf/topology.c, dlls/mfplat/main.c, dlls/winegstreamer/Makefile.in, dlls/winegstreamer/audioconvert.c, +# | dlls/winegstreamer/colorconvert.c, dlls/winegstreamer/decode_transform.c, dlls/winegstreamer/gst_private.h, +# | dlls/winegstreamer/media_source.c, dlls/winegstreamer/mfplat.c, dlls/winegstreamer/quartz_parser.c, +# | dlls/winegstreamer/wg_parser.c, dlls/winegstreamer/winegstreamer_classes.idl, include/mfidl.idl, include/wmcodecdsp.idl +# | +if test "$enable_mfplat_streaming_support" -eq 1; then + patch_apply mfplat-streaming-support/0001-winegstreamer-Activate-source-pad-in-push-mode-if-it.patch + patch_apply mfplat-streaming-support/0002-winegstreamer-Push-stream-start-and-segment-events-i.patch + patch_apply mfplat-streaming-support/0003-winegstreamer-Introduce-H.264-decoder-transform.patch + patch_apply mfplat-streaming-support/0004-winegstreamer-Implement-GetInputAvailableType-for-de.patch + patch_apply mfplat-streaming-support/0005-winegstreamer-Implement-GetOutputAvailableType-for-d.patch + patch_apply mfplat-streaming-support/0006-winegstreamer-Implement-SetInputType-for-decode-tran.patch + patch_apply mfplat-streaming-support/0007-winegstreamer-Implement-SetOutputType-for-decode-tra.patch + patch_apply mfplat-streaming-support/0008-winegstreamer-Implement-Get-Input-Output-StreamInfo-.patch + patch_apply mfplat-streaming-support/0009-winegstreamer-Add-push-mode-path-for-wg_parser.patch + patch_apply mfplat-streaming-support/0010-winegstreamer-Implement-Process-Input-Output-for-dec.patch + patch_apply mfplat-streaming-support/0011-winestreamer-Implement-ProcessMessage-for-decoder-tr.patch + patch_apply mfplat-streaming-support/0012-winegstreamer-Semi-stub-GetAttributes-for-decoder-tr.patch + patch_apply mfplat-streaming-support/0013-winegstreamer-Register-the-H.264-decoder-transform.patch + patch_apply mfplat-streaming-support/0014-winegstreamer-Introduce-AAC-decoder-transform.patch + patch_apply mfplat-streaming-support/0015-winegstreamer-Register-the-AAC-decoder-transform.patch + patch_apply mfplat-streaming-support/0016-winegstreamer-Rename-GStreamer-objects-to-be-more-ge.patch + patch_apply mfplat-streaming-support/0017-winegstreamer-Report-streams-backwards-in-media-sour.patch + patch_apply mfplat-streaming-support/0018-winegstreamer-Implement-Process-Input-Output-for-aud.patch + patch_apply mfplat-streaming-support/0019-winegstreamer-Implement-Get-Input-Output-StreamInfo-.patch + patch_apply mfplat-streaming-support/0020-winegstreamer-Semi-stub-Get-Attributes-functions-for.patch + patch_apply mfplat-streaming-support/0021-winegstreamer-Introduce-color-conversion-transform.patch + patch_apply mfplat-streaming-support/0022-winegstreamer-Register-the-color-conversion-transfor.patch + patch_apply mfplat-streaming-support/0023-winegstreamer-Implement-GetInputAvailableType-for-co.patch + patch_apply mfplat-streaming-support/0024-winegstreamer-Implement-SetInputType-for-color-conve.patch + patch_apply mfplat-streaming-support/0025-winegstreamer-Implement-GetOutputAvailableType-for-c.patch + patch_apply mfplat-streaming-support/0026-winegstreamer-Implement-SetOutputType-for-color-conv.patch + patch_apply mfplat-streaming-support/0027-winegstreamer-Implement-Process-Input-Output-for-col.patch + patch_apply mfplat-streaming-support/0028-winegstreamer-Implement-ProcessMessage-for-color-con.patch + patch_apply mfplat-streaming-support/0029-winegstreamer-Implement-Get-Input-Output-StreamInfo-.patch + patch_apply mfplat-streaming-support/0030-mf-topology-Forward-failure-from-SetOutputType-when-.patch + patch_apply mfplat-streaming-support/0031-winegstreamer-Handle-flush-command-in-audio-converst.patch + patch_apply mfplat-streaming-support/0032-winegstreamer-In-the-default-configuration-select-on.patch + patch_apply mfplat-streaming-support/0033-winegstreamer-Implement-MF_SD_LANGUAGE.patch + patch_apply mfplat-streaming-support/0034-winegstreamer-Only-require-videobox-element-for-pars.patch + patch_apply mfplat-streaming-support/0035-winegstreamer-Don-t-rely-on-max_size-in-unseekable-p.patch + patch_apply mfplat-streaming-support/0036-winegstreamer-Implement-MFT_MESSAGE_COMMAND_FLUSH-fo.patch + patch_apply mfplat-streaming-support/0037-winegstreamer-Default-Frame-size-if-one-isn-t-availa.patch + patch_apply mfplat-streaming-support/0038-mfplat-Stub-out-MFCreateDXGIDeviceManager-to-avoid-t.patch +fi + # Patchset mmsystem.dll16-MIDIHDR_Refcount # | # | This patchset fixes the following Wine bugs: diff --git a/staging/patchutils.py b/staging/patchutils.py index ed046bc1..18aed2f6 100644 --- a/staging/patchutils.py +++ b/staging/patchutils.py @@ -240,7 +240,8 @@ def _read_single_patch(fp, header, oldname=None, newname=None): raise NotImplementedError("Patch copy header not implemented yet.") elif line.startswith("rename "): - raise NotImplementedError("Patch rename header not implemented yet.") + pass +# raise NotImplementedError("Patch rename header not implemented yet.") elif line.startswith("similarity index") or line.startswith("dissimilarity index"): pass # ignore