Signed-off-by: Zebediah Figura z.figura12@gmail.com --- dlls/qcap/avimux.c | 16 +++++++------- dlls/qcap/smartteefilter.c | 8 +++---- dlls/qcap/vfwcapture.c | 10 ++++----- dlls/quartz/dsoundrender.c | 2 +- dlls/quartz/filesource.c | 10 ++++----- dlls/quartz/videorenderer.c | 2 +- dlls/quartz/vmr9.c | 4 ++-- dlls/strmbase/outputqueue.c | 4 ++-- dlls/strmbase/pin.c | 38 ++++++++++++++++----------------- dlls/strmbase/renderer.c | 14 ++++++------ dlls/strmbase/transform.c | 12 +++++------ dlls/strmbase/video.c | 6 +++--- dlls/winegstreamer/gstdemux.c | 38 ++++++++++++++++----------------- dlls/wineqtdecoder/qtsplitter.c | 20 ++++++++--------- include/wine/strmbase.h | 2 +- 15 files changed, 93 insertions(+), 93 deletions(-)
diff --git a/dlls/qcap/avimux.c b/dlls/qcap/avimux.c index 42b198deea4..596016cf77d 100644 --- a/dlls/qcap/avimux.c +++ b/dlls/qcap/avimux.c @@ -470,7 +470,7 @@ static HRESULT WINAPI AviMux_Stop(IBaseFilter *iface) return hr;
for(i=0; i<This->input_pin_no; i++) { - if(!This->in[i]->pin.pin.pConnectedTo) + if(!This->in[i]->pin.pin.peer) continue;
hr = out_seek(This, This->in[i]->ix_off); @@ -515,7 +515,7 @@ static HRESULT WINAPI AviMux_Stop(IBaseFilter *iface) return hr;
for(i=0; i<This->input_pin_no; i++) { - if(!This->in[i]->pin.pin.pConnectedTo) + if(!This->in[i]->pin.pin.peer) continue;
rl.cb = sizeof(FOURCC) + sizeof(AVISTREAMHEADER) + sizeof(RIFFCHUNK) + @@ -593,10 +593,10 @@ static HRESULT WINAPI AviMux_Run(IBaseFilter *iface, REFERENCE_TIME tStart) IMediaSeeking *ms; LONGLONG cur, stop;
- if(!This->in[i]->pin.pin.pConnectedTo) + if(!This->in[i]->pin.pin.peer) continue;
- hr = IPin_QueryInterface(This->in[i]->pin.pin.pConnectedTo, + hr = IPin_QueryInterface(This->in[i]->pin.pin.peer, &IID_IMediaSeeking, (void**)&ms); if(FAILED(hr)) continue; @@ -632,7 +632,7 @@ static HRESULT WINAPI AviMux_Run(IBaseFilter *iface, REFERENCE_TIME tStart) This->stop = -1; memset(&This->avih, 0, sizeof(This->avih)); for(i=0; i<This->input_pin_no; i++) { - if(!This->in[i]->pin.pin.pConnectedTo) + if(!This->in[i]->pin.pin.peer) continue;
This->avih.dwStreams++; @@ -660,7 +660,7 @@ static HRESULT WINAPI AviMux_Run(IBaseFilter *iface, REFERENCE_TIME tStart)
stream_id = 0; for(i=0; i<This->input_pin_no; i++) { - if(!This->in[i]->pin.pin.pConnectedTo) + if(!This->in[i]->pin.pin.peer) continue;
This->in[i]->ix_off = This->size; @@ -815,7 +815,7 @@ static HRESULT WINAPI ConfigInterleaving_put_Mode( return E_INVALIDARG;
if(This->mode != mode) { - if(This->source.pin.pConnectedTo) { + if(This->source.pin.peer) { HRESULT hr = IFilterGraph_Reconnect(This->filter.filterInfo.pGraph, &This->source.pin.IPin_iface); if(FAILED(hr)) @@ -1267,7 +1267,7 @@ static HRESULT WINAPI AviMuxOut_Connect(IPin *iface, return hr;
for(i=0; i<This->input_pin_no; i++) { - if(!This->in[i]->pin.pin.pConnectedTo) + if(!This->in[i]->pin.pin.peer) continue;
hr = IFilterGraph_Reconnect(This->filter.filterInfo.pGraph, &This->in[i]->pin.pin.IPin_iface); diff --git a/dlls/qcap/smartteefilter.c b/dlls/qcap/smartteefilter.c index d7e9e8b5f15..26f32559670 100644 --- a/dlls/qcap/smartteefilter.c +++ b/dlls/qcap/smartteefilter.c @@ -141,7 +141,7 @@ static HRESULT sink_get_media_type(struct strmbase_pin *base, if (iPosition) return S_FALSE; EnterCriticalSection(&This->filter.csFilter); - if (This->sink.pin.pConnectedTo) + if (This->sink.pin.peer) { CopyMediaType(amt, &This->sink.pin.mtCurrent); hr = S_OK; @@ -259,7 +259,7 @@ static HRESULT WINAPI SmartTeeFilterInput_Receive(BaseInputPin *base, IMediaSamp
/* FIXME: we should ideally do each of these in a separate thread */ EnterCriticalSection(&This->filter.csFilter); - if (This->capture.pin.pConnectedTo) + if (This->capture.pin.peer) hrCapture = copy_sample(inputSample, This->capture.pAllocator, &captureSample); LeaveCriticalSection(&This->filter.csFilter); if (SUCCEEDED(hrCapture)) @@ -268,7 +268,7 @@ static HRESULT WINAPI SmartTeeFilterInput_Receive(BaseInputPin *base, IMediaSamp IMediaSample_Release(captureSample);
EnterCriticalSection(&This->filter.csFilter); - if (This->preview.pin.pConnectedTo) + if (This->preview.pin.peer) hrPreview = copy_sample(inputSample, This->preview.pAllocator, &previewSample); LeaveCriticalSection(&This->filter.csFilter); /* No timestamps on preview stream: */ @@ -329,7 +329,7 @@ static HRESULT source_get_media_type(struct strmbase_pin *iface,
EnterCriticalSection(&filter->filter.csFilter);
- if (!filter->sink.pin.pConnectedTo) + if (!filter->sink.pin.peer) hr = VFW_E_NOT_CONNECTED; else if (!index) CopyMediaType(mt, &filter->sink.pin.mtCurrent); diff --git a/dlls/qcap/vfwcapture.c b/dlls/qcap/vfwcapture.c index e2608f43581..6fbe721a313 100644 --- a/dlls/qcap/vfwcapture.c +++ b/dlls/qcap/vfwcapture.c @@ -103,9 +103,9 @@ static void vfw_capture_destroy(struct strmbase_filter *iface) qcap_driver_destroy(filter->driver_info); }
- if (filter->source.pin.pConnectedTo) + if (filter->source.pin.peer) { - IPin_Disconnect(filter->source.pin.pConnectedTo); + IPin_Disconnect(filter->source.pin.peer); IPin_Disconnect(&filter->source.pin.IPin_iface); } strmbase_source_cleanup(&filter->source); @@ -221,16 +221,16 @@ AMStreamConfig_SetFormat(IAMStreamConfig *iface, AM_MEDIA_TYPE *pmt)
dump_AM_MEDIA_TYPE(pmt);
- if (This->source.pin.pConnectedTo) + if (This->source.pin.peer) { - hr = IPin_QueryAccept(This->source.pin.pConnectedTo, pmt); + hr = IPin_QueryAccept(This->source.pin.peer, pmt); TRACE("Would accept: %d\n", hr); if (hr == S_FALSE) return VFW_E_INVALIDMEDIATYPE; }
hr = qcap_driver_set_format(This->driver_info, pmt); - if (SUCCEEDED(hr) && This->filter.filterInfo.pGraph && This->source.pin.pConnectedTo) + if (SUCCEEDED(hr) && This->filter.filterInfo.pGraph && This->source.pin.peer) { hr = IFilterGraph_Reconnect(This->filter.filterInfo.pGraph, &This->source.pin.IPin_iface); if (SUCCEEDED(hr)) diff --git a/dlls/quartz/dsoundrender.c b/dlls/quartz/dsoundrender.c index dbb5b523fa8..b6eb7ba2587 100644 --- a/dlls/quartz/dsoundrender.c +++ b/dlls/quartz/dsoundrender.c @@ -436,7 +436,7 @@ static void dsound_render_start_stream(BaseRenderer *iface)
TRACE("(%p)\n", This);
- if (This->renderer.sink.pin.pConnectedTo) + if (This->renderer.sink.pin.peer) { IDirectSoundBuffer_Play(This->dsbuffer, 0, 0, DSBPLAY_LOOPING); } diff --git a/dlls/quartz/filesource.c b/dlls/quartz/filesource.c index 0c58ecaa2a9..36b7e95ad6f 100644 --- a/dlls/quartz/filesource.c +++ b/dlls/quartz/filesource.c @@ -358,8 +358,8 @@ static void async_reader_destroy(struct strmbase_filter *iface) { unsigned int i;
- if (filter->source.pin.pConnectedTo) - IPin_Disconnect(filter->source.pin.pConnectedTo); + if (filter->source.pin.peer) + IPin_Disconnect(filter->source.pin.peer);
IPin_Disconnect(&filter->source.pin.IPin_iface);
@@ -649,7 +649,7 @@ static HRESULT WINAPI FileAsyncReaderPin_AttemptConnection(struct strmbase_sourc
/* FIXME: call queryacceptproc */
- This->pin.pConnectedTo = pReceivePin; + This->pin.peer = pReceivePin; IPin_AddRef(pReceivePin); CopyMediaType(&This->pin.mtCurrent, pmt);
@@ -657,8 +657,8 @@ static HRESULT WINAPI FileAsyncReaderPin_AttemptConnection(struct strmbase_sourc
if (FAILED(hr)) { - IPin_Release(This->pin.pConnectedTo); - This->pin.pConnectedTo = NULL; + IPin_Release(This->pin.peer); + This->pin.peer = NULL; FreeMediaType(&This->pin.mtCurrent); }
diff --git a/dlls/quartz/videorenderer.c b/dlls/quartz/videorenderer.c index aee362c7ef2..a7b3159ebcc 100644 --- a/dlls/quartz/videorenderer.c +++ b/dlls/quartz/videorenderer.c @@ -419,7 +419,7 @@ static void video_renderer_start_stream(BaseRenderer *iface)
TRACE("(%p)\n", This);
- if (This->renderer.sink.pin.pConnectedTo + if (This->renderer.sink.pin.peer && (This->renderer.filter.state == State_Stopped || !This->renderer.sink.end_of_stream)) { if (This->renderer.filter.state == State_Stopped) diff --git a/dlls/quartz/vmr9.c b/dlls/quartz/vmr9.c index d81c3252b05..2c9c825b505 100644 --- a/dlls/quartz/vmr9.c +++ b/dlls/quartz/vmr9.c @@ -377,7 +377,7 @@ static HRESULT VMR9_maybe_init(struct quartz_vmr *This, BOOL force) HRESULT hr;
TRACE("my mode: %u, my window: %p, my last window: %p\n", This->mode, This->baseControlWindow.baseWindow.hWnd, This->hWndClippingWindow); - if (This->baseControlWindow.baseWindow.hWnd || !This->renderer.sink.pin.pConnectedTo) + if (This->baseControlWindow.baseWindow.hWnd || !This->renderer.sink.pin.peer) return S_OK;
if (This->mode == VMR9Mode_Windowless && !This->hWndClippingWindow) @@ -482,7 +482,7 @@ static HRESULT WINAPI VMR9_BreakConnect(BaseRenderer *This)
if (!pVMR9->mode) return S_FALSE; - if (This->sink.pin.pConnectedTo && pVMR9->allocator && pVMR9->presenter) + if (This->sink.pin.peer && pVMR9->allocator && pVMR9->presenter) { if (pVMR9->renderer.filter.state != State_Stopped) { diff --git a/dlls/strmbase/outputqueue.c b/dlls/strmbase/outputqueue.c index 6cb74f3e26c..ee05653d7a1 100644 --- a/dlls/strmbase/outputqueue.c +++ b/dlls/strmbase/outputqueue.c @@ -118,7 +118,7 @@ HRESULT WINAPI OutputQueue_ReceiveMultiple(OutputQueue *pOutputQueue, IMediaSamp HRESULT hr = S_OK; int i;
- if (!pOutputQueue->pInputPin->pin.pConnectedTo || !pOutputQueue->pInputPin->pMemInputPin) + if (!pOutputQueue->pInputPin->pin.peer || !pOutputQueue->pInputPin->pMemInputPin) return VFW_E_NOT_CONNECTED;
if (!pOutputQueue->hThread) @@ -241,7 +241,7 @@ DWORD WINAPI OutputQueueImpl_ThreadProc(OutputQueue *pOutputQueue) HeapFree(GetProcessHeap(),0,qev); }
- if (pOutputQueue->pInputPin->pin.pConnectedTo && pOutputQueue->pInputPin->pMemInputPin) + if (pOutputQueue->pInputPin->pin.peer && pOutputQueue->pInputPin->pMemInputPin) { IMemInputPin_AddRef(pOutputQueue->pInputPin->pMemInputPin); LeaveCriticalSection(&pOutputQueue->csQueue); diff --git a/dlls/strmbase/pin.c b/dlls/strmbase/pin.c index 190c9078fab..cc7db119fae 100644 --- a/dlls/strmbase/pin.c +++ b/dlls/strmbase/pin.c @@ -203,10 +203,10 @@ HRESULT WINAPI BasePinImpl_Disconnect(IPin * iface)
EnterCriticalSection(&This->filter->csFilter); { - if (This->pConnectedTo) + if (This->peer) { - IPin_Release(This->pConnectedTo); - This->pConnectedTo = NULL; + IPin_Release(This->peer); + This->peer = NULL; FreeMediaType(&This->mtCurrent); ZeroMemory(&This->mtCurrent, sizeof(This->mtCurrent)); hr = S_OK; @@ -228,9 +228,9 @@ HRESULT WINAPI BasePinImpl_ConnectedTo(IPin * iface, IPin ** ppPin)
EnterCriticalSection(&This->filter->csFilter); { - if (This->pConnectedTo) + if (This->peer) { - *ppPin = This->pConnectedTo; + *ppPin = This->peer; IPin_AddRef(*ppPin); hr = S_OK; } @@ -254,7 +254,7 @@ HRESULT WINAPI BasePinImpl_ConnectionMediaType(IPin * iface, AM_MEDIA_TYPE * pmt
EnterCriticalSection(&This->filter->csFilter); { - if (This->pConnectedTo) + if (This->peer) { CopyMediaType(pmt, &This->mtCurrent); hr = S_OK; @@ -467,10 +467,10 @@ HRESULT WINAPI BaseOutputPinImpl_Disconnect(IPin * iface) IMemInputPin_Release(This->pMemInputPin); This->pMemInputPin = NULL; } - if (This->pin.pConnectedTo) + if (This->pin.peer) { - IPin_Release(This->pin.pConnectedTo); - This->pin.pConnectedTo = NULL; + IPin_Release(This->pin.peer); + This->pin.peer = NULL; FreeMediaType(&This->pin.mtCurrent); ZeroMemory(&This->pin.mtCurrent, sizeof(This->pin.mtCurrent)); hr = S_OK; @@ -517,7 +517,7 @@ HRESULT WINAPI BaseOutputPinImpl_GetDeliveryBuffer(struct strmbase_source *This,
TRACE("(%p)->(%p, %p, %p, %x)\n", This, ppSample, tStart, tStop, dwFlags);
- if (!This->pin.pConnectedTo) + if (!This->pin.peer) hr = VFW_E_NOT_CONNECTED; else { @@ -539,7 +539,7 @@ HRESULT WINAPI BaseOutputPinImpl_Deliver(struct strmbase_source *This, IMediaSam
EnterCriticalSection(&This->pin.filter->csFilter); { - if (!This->pin.pConnectedTo || !This->pMemInputPin) + if (!This->pin.peer || !This->pMemInputPin) hr = VFW_E_NOT_CONNECTED; else { @@ -548,7 +548,7 @@ HRESULT WINAPI BaseOutputPinImpl_Deliver(struct strmbase_source *This, IMediaSam * using it. Same with its filter. */ pMemConnected = This->pMemInputPin; IMemInputPin_AddRef(pMemConnected); - hr = IPin_QueryPinInfo(This->pin.pConnectedTo, &pinInfo); + hr = IPin_QueryPinInfo(This->pin.peer, &pinInfo); } } LeaveCriticalSection(&This->pin.filter->csFilter); @@ -579,7 +579,7 @@ HRESULT WINAPI BaseOutputPinImpl_Active(struct strmbase_source *This)
EnterCriticalSection(&This->pin.filter->csFilter); { - if (!This->pin.pConnectedTo || !This->pMemInputPin) + if (!This->pin.peer || !This->pMemInputPin) hr = VFW_E_NOT_CONNECTED; else hr = IMemAllocator_Commit(This->pAllocator); @@ -599,7 +599,7 @@ HRESULT WINAPI BaseOutputPinImpl_Inactive(struct strmbase_source *This)
EnterCriticalSection(&This->pin.filter->csFilter); { - if (!This->pin.pConnectedTo || !This->pMemInputPin) + if (!This->pin.peer || !This->pMemInputPin) hr = VFW_E_NOT_CONNECTED; else hr = IMemAllocator_Decommit(This->pAllocator); @@ -657,7 +657,7 @@ HRESULT WINAPI BaseOutputPinImpl_AttemptConnection(struct strmbase_source *This, if ((hr = This->pFuncsTable->base.pin_query_accept(&This->pin, pmt)) != S_OK) return hr;
- This->pin.pConnectedTo = pReceivePin; + This->pin.peer = pReceivePin; IPin_AddRef(pReceivePin); CopyMediaType(&This->pin.mtCurrent, pmt);
@@ -692,8 +692,8 @@ HRESULT WINAPI BaseOutputPinImpl_AttemptConnection(struct strmbase_source *This,
if (FAILED(hr)) { - IPin_Release(This->pin.pConnectedTo); - This->pin.pConnectedTo = NULL; + IPin_Release(This->pin.peer); + This->pin.peer = NULL; FreeMediaType(&This->pin.mtCurrent); }
@@ -747,7 +747,7 @@ HRESULT WINAPI BaseInputPinImpl_ReceiveConnection(IPin * iface, IPin * pReceiveP
EnterCriticalSection(&This->pin.filter->csFilter); { - if (This->pin.pConnectedTo) + if (This->pin.peer) hr = VFW_E_ALREADY_CONNECTED;
if (SUCCEEDED(hr) && This->pin.pFuncsTable->pin_query_accept(&This->pin, pmt) != S_OK) @@ -768,7 +768,7 @@ HRESULT WINAPI BaseInputPinImpl_ReceiveConnection(IPin * iface, IPin * pReceiveP if (SUCCEEDED(hr)) { CopyMediaType(&This->pin.mtCurrent, pmt); - This->pin.pConnectedTo = pReceivePin; + This->pin.peer = pReceivePin; IPin_AddRef(pReceivePin); } } diff --git a/dlls/strmbase/renderer.c b/dlls/strmbase/renderer.c index 051230186d2..038cb48b57b 100644 --- a/dlls/strmbase/renderer.c +++ b/dlls/strmbase/renderer.c @@ -282,8 +282,8 @@ HRESULT WINAPI strmbase_renderer_init(BaseRenderer *filter, const IBaseFilterVtb
void strmbase_renderer_cleanup(BaseRenderer *filter) { - if (filter->sink.pin.pConnectedTo) - IPin_Disconnect(filter->sink.pin.pConnectedTo); + if (filter->sink.pin.peer) + IPin_Disconnect(filter->sink.pin.peer); IPin_Disconnect(&filter->sink.pin.IPin_iface); strmbase_sink_cleanup(&filter->sink);
@@ -407,7 +407,7 @@ HRESULT WINAPI BaseRendererImpl_Stop(IBaseFilter * iface) EnterCriticalSection(&This->csRenderLock); { RendererPosPassThru_ResetMediaTime(This->pPosition); - if (This->sink.pin.pConnectedTo && This->pFuncsTable->renderer_stop_stream) + if (This->sink.pin.peer && This->pFuncsTable->renderer_stop_stream) This->pFuncsTable->renderer_stop_stream(This); This->filter.state = State_Stopped; SetEvent(This->state_event); @@ -431,7 +431,7 @@ HRESULT WINAPI BaseRendererImpl_Run(IBaseFilter * iface, REFERENCE_TIME tStart)
SetEvent(This->state_event);
- if (This->sink.pin.pConnectedTo) + if (This->sink.pin.peer) { This->sink.end_of_stream = FALSE; } @@ -449,7 +449,7 @@ HRESULT WINAPI BaseRendererImpl_Run(IBaseFilter * iface, REFERENCE_TIME tStart) if (SUCCEEDED(hr)) { QualityControlRender_Start(This->qcimpl, This->filter.rtStreamStart); - if (This->sink.pin.pConnectedTo && This->pFuncsTable->renderer_start_stream) + if (This->sink.pin.peer && This->pFuncsTable->renderer_start_stream) This->pFuncsTable->renderer_start_stream(This); if (This->filter.state == State_Stopped) BaseRendererImpl_ClearPendingSample(This); @@ -473,11 +473,11 @@ HRESULT WINAPI BaseRendererImpl_Pause(IBaseFilter * iface) { if (This->filter.state == State_Stopped) { - if (This->sink.pin.pConnectedTo) + if (This->sink.pin.peer) ResetEvent(This->state_event); This->sink.end_of_stream = FALSE; } - else if (This->sink.pin.pConnectedTo && This->pFuncsTable->renderer_stop_stream) + else if (This->sink.pin.peer && This->pFuncsTable->renderer_stop_stream) This->pFuncsTable->renderer_stop_stream(This);
if (This->filter.state == State_Stopped) diff --git a/dlls/strmbase/transform.c b/dlls/strmbase/transform.c index 04acf63c9a5..77de1227dd9 100644 --- a/dlls/strmbase/transform.c +++ b/dlls/strmbase/transform.c @@ -135,12 +135,12 @@ static void transform_destroy(struct strmbase_filter *iface) { TransformFilter *filter = impl_from_strmbase_filter(iface);
- if (filter->sink.pin.pConnectedTo) - IPin_Disconnect(filter->sink.pin.pConnectedTo); + if (filter->sink.pin.peer) + IPin_Disconnect(filter->sink.pin.peer); IPin_Disconnect(&filter->sink.pin.IPin_iface);
- if (filter->source.pin.pConnectedTo) - IPin_Disconnect(filter->source.pin.pConnectedTo); + if (filter->source.pin.peer) + IPin_Disconnect(filter->source.pin.peer); IPin_Disconnect(&filter->source.pin.IPin_iface);
strmbase_sink_cleanup(&filter->sink); @@ -379,8 +379,8 @@ static HRESULT WINAPI TransformFilter_InputPin_EndOfStream(IPin * iface)
TRACE("iface %p.\n", iface);
- if (filter->source.pin.pConnectedTo) - return IPin_EndOfStream(filter->source.pin.pConnectedTo); + if (filter->source.pin.peer) + return IPin_EndOfStream(filter->source.pin.peer); return VFW_E_NOT_CONNECTED; }
diff --git a/dlls/strmbase/video.c b/dlls/strmbase/video.c index 4be4b2380f9..d1ebbdf235a 100644 --- a/dlls/strmbase/video.c +++ b/dlls/strmbase/video.c @@ -132,7 +132,7 @@ static HRESULT WINAPI basic_video_get_AvgTimePerFrame(IBasicVideo *iface, REFTIM
if (!pAvgTimePerFrame) return E_POINTER; - if (!This->pPin->pConnectedTo) + if (!This->pPin->peer) return VFW_E_NOT_CONNECTED;
TRACE("(%p/%p)->(%p)\n", This, iface, pAvgTimePerFrame); @@ -151,7 +151,7 @@ static HRESULT WINAPI basic_video_get_BitRate(IBasicVideo *iface, LONG *pBitRate
if (!pBitRate) return E_POINTER; - if (!This->pPin->pConnectedTo) + if (!This->pPin->peer) return VFW_E_NOT_CONNECTED;
vih = This->pFuncsTable->pfnGetVideoFormat(This); @@ -168,7 +168,7 @@ static HRESULT WINAPI basic_video_get_BitErrorRate(IBasicVideo *iface, LONG *pBi
if (!pBitErrorRate) return E_POINTER; - if (!This->pPin->pConnectedTo) + if (!This->pPin->peer) return VFW_E_NOT_CONNECTED;
vih = This->pFuncsTable->pfnGetVideoFormat(This); diff --git a/dlls/winegstreamer/gstdemux.c b/dlls/winegstreamer/gstdemux.c index de3bc996877..cee90d195bf 100644 --- a/dlls/winegstreamer/gstdemux.c +++ b/dlls/winegstreamer/gstdemux.c @@ -523,14 +523,14 @@ static gboolean event_sink(GstPad *pad, GstObject *parent, GstEvent *event) if (stop > 0) stop /= 100;
- if (pin->pin.pin.pConnectedTo) - IPin_NewSegment(pin->pin.pin.pConnectedTo, pos, stop, rate*applied_rate); + if (pin->pin.pin.peer) + IPin_NewSegment(pin->pin.pin.peer, pos, stop, rate*applied_rate);
return TRUE; } case GST_EVENT_EOS: - if (pin->pin.pin.pConnectedTo) - IPin_EndOfStream(pin->pin.pin.pConnectedTo); + if (pin->pin.pin.peer) + IPin_EndOfStream(pin->pin.pin.peer); return TRUE; case GST_EVENT_FLUSH_START: if (impl_from_strmbase_filter(pin->pin.pin.filter)->ignore_flush) { @@ -544,13 +544,13 @@ static gboolean event_sink(GstPad *pad, GstObject *parent, GstEvent *event) GST_PAD_UNSET_FLUSHING (pad); return TRUE; } - if (pin->pin.pin.pConnectedTo) - IPin_BeginFlush(pin->pin.pin.pConnectedTo); + if (pin->pin.pin.peer) + IPin_BeginFlush(pin->pin.pin.peer); return TRUE; case GST_EVENT_FLUSH_STOP: gst_segment_init(pin->segment, GST_FORMAT_TIME); - if (pin->pin.pin.pConnectedTo) - IPin_EndFlush(pin->pin.pin.pConnectedTo); + if (pin->pin.pin.peer) + IPin_EndFlush(pin->pin.pin.peer); return TRUE; case GST_EVENT_CAPS: { GstCaps *caps; @@ -731,7 +731,7 @@ static GstFlowReturn got_data_sink(GstPad *pad, GstObject *parent, GstBuffer *bu IMediaSample_SetPreroll(sample, GST_BUFFER_FLAG_IS_SET(buf, GST_BUFFER_FLAG_LIVE)); IMediaSample_SetSyncPoint(sample, !GST_BUFFER_FLAG_IS_SET(buf, GST_BUFFER_FLAG_DELTA_UNIT));
- if (!pin->pin.pin.pConnectedTo) + if (!pin->pin.pin.peer) hr = VFW_E_NOT_CONNECTED; else hr = IMemInputPin_Receive(pin->pin.pMemInputPin, sample); @@ -1208,9 +1208,9 @@ static void gstdemux_destroy(struct strmbase_filter *iface) CloseHandle(filter->duration_event);
/* Don't need to clean up output pins, disconnecting input pin will do that */ - if (filter->sink.pConnectedTo) + if (filter->sink.peer) { - hr = IPin_Disconnect(filter->sink.pConnectedTo); + hr = IPin_Disconnect(filter->sink.peer); assert(hr == S_OK); hr = IPin_Disconnect(&filter->sink.IPin_iface); assert(hr == S_OK); @@ -1847,10 +1847,10 @@ static HRESULT WINAPI GSTOutPin_DecideAllocator(struct strmbase_source *base,
static void free_source_pin(struct gstdemux_source *pin) { - if (pin->pin.pin.pConnectedTo) + if (pin->pin.pin.peer) { if (SUCCEEDED(IMemAllocator_Decommit(pin->pin.pAllocator))) - IPin_Disconnect(pin->pin.pin.pConnectedTo); + IPin_Disconnect(pin->pin.pin.peer); IPin_Disconnect(&pin->pin.pin.IPin_iface); }
@@ -1986,7 +1986,7 @@ static HRESULT WINAPI GSTInPin_ReceiveConnection(IPin *iface, IPin *pReceivePin, mark_wine_thread();
EnterCriticalSection(&filter->filter.csFilter); - if (!filter->sink.pConnectedTo) + if (!filter->sink.peer) { ALLOCATOR_PROPERTIES props; IMemAllocator *pAlloc = NULL; @@ -2028,7 +2028,7 @@ static HRESULT WINAPI GSTInPin_ReceiveConnection(IPin *iface, IPin *pReceivePin, IMemAllocator_Release(pAlloc); if (SUCCEEDED(hr)) { CopyMediaType(&filter->sink.mtCurrent, pmt); - filter->sink.pConnectedTo = pReceivePin; + filter->sink.peer = pReceivePin; IPin_AddRef(pReceivePin); hr = IMemAllocator_Commit(filter->alloc); } else { @@ -2059,13 +2059,13 @@ static HRESULT WINAPI GSTInPin_Disconnect(IPin *iface)
hr = IBaseFilter_GetState(&filter->filter.IBaseFilter_iface, INFINITE, &state); EnterCriticalSection(&filter->filter.csFilter); - if (filter->sink.pConnectedTo) + if (filter->sink.peer) { if (SUCCEEDED(hr) && state == State_Stopped) { IMemAllocator_Decommit(filter->alloc); - IPin_Disconnect(filter->sink.pConnectedTo); - IPin_Release(filter->sink.pConnectedTo); - filter->sink.pConnectedTo = NULL; + IPin_Disconnect(filter->sink.peer); + IPin_Release(filter->sink.peer); + filter->sink.peer = NULL; hr = GST_RemoveOutputPins(filter); } else hr = VFW_E_NOT_STOPPED; diff --git a/dlls/wineqtdecoder/qtsplitter.c b/dlls/wineqtdecoder/qtsplitter.c index d3b9596375d..218ed5dad70 100644 --- a/dlls/wineqtdecoder/qtsplitter.c +++ b/dlls/wineqtdecoder/qtsplitter.c @@ -340,7 +340,7 @@ IUnknown * CALLBACK QTSplitter_create(IUnknown *outer, HRESULT *phr) This->pInputPin.pin.filter = &This->filter; lstrcpynW(This->pInputPin.pin.name, wcsInputPinName, ARRAY_SIZE(This->pInputPin.pin.name)); This->pInputPin.pin.IPin_iface.lpVtbl = &QT_InputPin_Vtbl; - This->pInputPin.pin.pConnectedTo = NULL; + This->pInputPin.pin.peer = NULL; This->pInputPin.pin.pFuncsTable = &sink_ops;
SourceSeeking_Init(&This->sourceSeeking, &QT_Seeking_Vtbl, QTSplitter_ChangeStop, QTSplitter_ChangeStart, QTSplitter_ChangeRate, &This->filter.csFilter); @@ -586,7 +586,7 @@ static DWORD WINAPI QTSplitter_thread(LPVOID data) tStop = time * 10000000;
/* Deliver Audio */ - if (This->pAudio_Pin && This->pAudio_Pin->pin.pin.pConnectedTo && This->aSession) + if (This->pAudio_Pin && This->pAudio_Pin->pin.pin.peer && This->aSession) { int data_size=0; BYTE* ptr; @@ -802,10 +802,10 @@ static const IBaseFilterVtbl QT_Vtbl = {
static void free_source_pin(QTOutPin *pin) { - if (pin->pin.pin.pConnectedTo) + if (pin->pin.pin.peer) { if (SUCCEEDED(IMemAllocator_Decommit(pin->pin.pAllocator))) - IPin_Disconnect(pin->pin.pin.pConnectedTo); + IPin_Disconnect(pin->pin.pin.peer); IPin_Disconnect(&pin->pin.pin.IPin_iface); }
@@ -1064,7 +1064,7 @@ static HRESULT WINAPI QTInPin_ReceiveConnection(IPin *iface, IPin *pReceivePin, EnterCriticalSection(&filter->filter.csFilter); This->pReader = NULL;
- if (This->pin.pConnectedTo) + if (This->pin.peer) hr = VFW_E_ALREADY_CONNECTED; else if (IPin_QueryAccept(iface, pmt) != S_OK) hr = VFW_E_TYPE_NOT_ACCEPTED; @@ -1122,7 +1122,7 @@ static HRESULT WINAPI QTInPin_ReceiveConnection(IPin *iface, IPin *pReceivePin, if (SUCCEEDED(hr)) { CopyMediaType(&This->pin.mtCurrent, pmt); - This->pin.pConnectedTo = pReceivePin; + This->pin.peer = pReceivePin; IPin_AddRef(pReceivePin); hr = IMemAllocator_Commit(This->pAlloc); } @@ -1152,16 +1152,16 @@ static HRESULT WINAPI QTInPin_Disconnect(IPin *iface)
hr = IBaseFilter_GetState(&filter->filter.IBaseFilter_iface, INFINITE, &state); EnterCriticalSection(&filter->filter.csFilter); - if (This->pin.pConnectedTo) + if (This->pin.peer) { QTSplitter *Parser = impl_from_strmbase_filter(This->pin.filter);
if (SUCCEEDED(hr) && state == State_Stopped) { IMemAllocator_Decommit(This->pAlloc); - IPin_Disconnect(This->pin.pConnectedTo); - IPin_Release(This->pin.pConnectedTo); - This->pin.pConnectedTo = NULL; + IPin_Disconnect(This->pin.peer); + IPin_Release(This->pin.peer); + This->pin.peer = NULL; hr = QT_RemoveOutputPins(Parser); } else diff --git a/include/wine/strmbase.h b/include/wine/strmbase.h index 85c5486f6b4..6a358decfc7 100644 --- a/include/wine/strmbase.h +++ b/include/wine/strmbase.h @@ -34,7 +34,7 @@ struct strmbase_pin struct strmbase_filter *filter; PIN_DIRECTION dir; WCHAR name[128]; - IPin *pConnectedTo; + IPin *peer; AM_MEDIA_TYPE mtCurrent; REFERENCE_TIME tStart, tStop; double dRate;