dmusic: Call SetSynkSink() first to initialize the Synth.

Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Michael Stefaniuc 2022-01-20 21:20:19 +01:00 committed by Alexandre Julliard
parent d878158675
commit 7217973cb9
1 changed files with 3 additions and 3 deletions

View File

@ -850,15 +850,15 @@ HRESULT synth_port_create(IDirectMusic8Impl *parent, DMUS_PORTPARAMS *port_param
if (SUCCEEDED(hr)) if (SUCCEEDED(hr))
hr = CoCreateInstance(&CLSID_DirectMusicSynthSink, NULL, CLSCTX_INPROC_SERVER, &IID_IDirectMusicSynthSink, (void**)&obj->synth_sink); hr = CoCreateInstance(&CLSID_DirectMusicSynthSink, NULL, CLSCTX_INPROC_SERVER, &IID_IDirectMusicSynthSink, (void**)&obj->synth_sink);
if (SUCCEEDED(hr))
hr = IDirectMusicSynth_SetSynthSink(obj->synth, obj->synth_sink);
if (SUCCEEDED(hr)) if (SUCCEEDED(hr))
hr = IDirectMusicSynth_SetMasterClock(obj->synth, obj->pLatencyClock); hr = IDirectMusicSynth_SetMasterClock(obj->synth, obj->pLatencyClock);
if (SUCCEEDED(hr)) if (SUCCEEDED(hr))
hr = IDirectMusicSynthSink_SetMasterClock(obj->synth_sink, obj->pLatencyClock); hr = IDirectMusicSynthSink_SetMasterClock(obj->synth_sink, obj->pLatencyClock);
if (SUCCEEDED(hr))
hr = IDirectMusicSynth_SetSynthSink(obj->synth, obj->synth_sink);
if (SUCCEEDED(hr)) if (SUCCEEDED(hr))
hr = IDirectMusicSynth_Open(obj->synth, port_params); hr = IDirectMusicSynth_Open(obj->synth, port_params);