From: Rémi Bernon rbernon@codeweavers.com
--- dlls/mfsrcsnk/factory.c | 3 +++ dlls/mfsrcsnk/media_source.c | 18 ++++++++++++++++++ dlls/mfsrcsnk/media_source.h | 1 + dlls/mfsrcsnk/mfsrcsnk.idl | 7 +++++++ dlls/mfsrcsnk/mfsrcsnk.rgs | 13 +++++++++++++ include/wine/mfinternal.idl | 1 + 6 files changed, 43 insertions(+)
diff --git a/dlls/mfsrcsnk/factory.c b/dlls/mfsrcsnk/factory.c index e89129f9e03..c0a02d5fa9d 100644 --- a/dlls/mfsrcsnk/factory.c +++ b/dlls/mfsrcsnk/factory.c @@ -31,6 +31,9 @@ HRESULT WINAPI DllGetClassObject(REFCLSID clsid, REFIID riid, void **out)
if (IsEqualGUID(clsid, &CLSID_AVIByteStreamPlugin)) return IClassFactory_QueryInterface(&avi_byte_stream_plugin_factory, riid, out); + if (IsEqualGUID(clsid, &CLSID_WAVByteStreamPlugin)) + return IClassFactory_QueryInterface(&wav_byte_stream_plugin_factory, riid, out); + if (IsEqualGUID(clsid, &CLSID_MFWAVESinkClassFactory)) return IClassFactory_QueryInterface(wave_sink_class_factory, riid, out);
diff --git a/dlls/mfsrcsnk/media_source.c b/dlls/mfsrcsnk/media_source.c index 0c765ab9494..5c3605b8cdf 100644 --- a/dlls/mfsrcsnk/media_source.c +++ b/dlls/mfsrcsnk/media_source.c @@ -37,3 +37,21 @@ static const IClassFactoryVtbl avi_byte_stream_plugin_factory_vtbl = };
IClassFactory avi_byte_stream_plugin_factory = {&avi_byte_stream_plugin_factory_vtbl}; + +static HRESULT WINAPI wav_byte_stream_plugin_factory_CreateInstance(IClassFactory *iface, + IUnknown *outer, REFIID riid, void **out) +{ + static const GUID CLSID_GStreamerByteStreamHandler = {0x317df618,0x5e5a,0x468a,{0x9f,0x15,0xd8,0x27,0xa9,0xa0,0x81,0x62}}; + return CoCreateInstance(&CLSID_GStreamerByteStreamHandler, outer, CLSCTX_INPROC_SERVER, riid, out); +} + +static const IClassFactoryVtbl wav_byte_stream_plugin_factory_vtbl = +{ + class_factory_QueryInterface, + class_factory_AddRef, + class_factory_Release, + wav_byte_stream_plugin_factory_CreateInstance, + class_factory_LockServer, +}; + +IClassFactory wav_byte_stream_plugin_factory = {&wav_byte_stream_plugin_factory_vtbl}; diff --git a/dlls/mfsrcsnk/media_source.h b/dlls/mfsrcsnk/media_source.h index 63333658086..5c555c31a95 100644 --- a/dlls/mfsrcsnk/media_source.h +++ b/dlls/mfsrcsnk/media_source.h @@ -21,3 +21,4 @@ #include "wine/debug.h"
extern IClassFactory avi_byte_stream_plugin_factory; +extern IClassFactory wav_byte_stream_plugin_factory; diff --git a/dlls/mfsrcsnk/mfsrcsnk.idl b/dlls/mfsrcsnk/mfsrcsnk.idl index e40831d7a7f..10b41769060 100644 --- a/dlls/mfsrcsnk/mfsrcsnk.idl +++ b/dlls/mfsrcsnk/mfsrcsnk.idl @@ -31,3 +31,10 @@ coclass AVIByteStreamPlugin { } uuid(36f99745-23c9-4c9c-8dd5-cc31ce964390) ] coclass MFWAVESinkClassFactory { } + +[ + helpstring("WAV Byte Stream Handler"), + threading(both), + uuid(42c9b9f5-16fc-47ef-af22-da05f7c842e3) +] +coclass WAVByteStreamPlugin {} diff --git a/dlls/mfsrcsnk/mfsrcsnk.rgs b/dlls/mfsrcsnk/mfsrcsnk.rgs index ee897e464a2..c8272189273 100644 --- a/dlls/mfsrcsnk/mfsrcsnk.rgs +++ b/dlls/mfsrcsnk/mfsrcsnk.rgs @@ -24,6 +24,19 @@ HKLM { val '{7afa253e-f823-42f6-a5d9-714bde467412}' = s 'AVI Byte Stream Handler' } + + '.wav' + { + val '{42c9b9f5-16fc-47ef-af22-da05f7c842e3}' = s 'WAV Byte Stream Handler' + } + 'audio/wav' + { + val '{42c9b9f5-16fc-47ef-af22-da05f7c842e3}' = s 'WAV Byte Stream Handler' + } + 'audio/x-wav' + { + val '{42c9b9f5-16fc-47ef-af22-da05f7c842e3}' = s 'WAV Byte Stream Handler' + } } } } diff --git a/include/wine/mfinternal.idl b/include/wine/mfinternal.idl index 41cac45bbbb..a014faf4c3c 100644 --- a/include/wine/mfinternal.idl +++ b/include/wine/mfinternal.idl @@ -54,3 +54,4 @@ cpp_quote("DEFINE_GUID(CLSID_MFMPEG4SinkClassFactory, 0xa22c4fc7, 0x6e91, 0x4e1d cpp_quote("DEFINE_GUID(CLSID_MFWAVESinkClassFactory, 0x36f99745, 0x23c9, 0x4c9c, 0x8d, 0xd5, 0xcc, 0x31, 0xce, 0x96, 0x43, 0x90);")
cpp_quote("DEFINE_GUID(CLSID_AVIByteStreamPlugin, 0x7afa253e, 0xf823, 0x42f6, 0xa5, 0xd9, 0x71, 0x4b, 0xde, 0x46, 0x74, 0x12);") +cpp_quote("DEFINE_GUID(CLSID_WAVByteStreamPlugin, 0x42c9b9f5, 0x16fc, 0x47ef, 0xaf, 0x22, 0xda, 0x05, 0xf7, 0xc8, 0x42, 0xe3);")