CBaseFilter::FindPin

 
Microsoft DirectShow 9.0

CBaseFilter::FindPin

The FindPin method retrieves the pin with the specified identifier. This method implements the IBaseFilter::FindPin method.

Syntax

  HRESULT FindPin(
    LPCWSTR Id,
    IPin **ppPin
);

Parameters

Id

Pointer to a constant, null-terminated Unicode™ string that identifies the pin.

ppPin

Address of a variable that receives a pointer to the pin's IPin interface.

Return Value

Returns one of the following HRESULT values.

Value Description
S_OK Success.
E_POINTER NULL pointer argument.
VFW_E_NOT_FOUND Could not find a matching pin.

Remarks

This method calls the CBasePin::Name method to compare each pin's name against the string specified by the Id parameter.

If the method succeeds, the IPin interface has an outstanding reference count. Be sure to release it when you are done.

Requirements

**  Header:** Declared in Amfilter.h; include Streams.h.

**  Library:** Use Strmbase.lib (retail builds) or Strmbasd.lib (debug builds).

See Also