## Object and Pin Functions

The Wxutil.h and Combase.h header files in the DirectShow base classes provides helper functions for comparing objects and pins and retrieving interfaces to objects.

Function | Description
EqualPins | Checks if two pins are on the same object.
GetInterface | Returns an interface pointer to the requested client.
IsEqualObject | Checks if two interfaces are on the same object.

###

EqualPins

Object and Pin Functions

Checks if two pins are on the same object.

BOOL EqualPins(
IUnknown * pPin1,
IUnknown * pPin2
);

##### Parameters

pPin1
  Address of one pin.
pPin2
  Address of the other pin.

##### Return Values

Returns TRUE if the pins are both on the same object, or FALSE otherwise.

###

GetInterface

Object and Pin Functions

Retrieves an interface pointer.

HRESULT GetInterface(
LPUNKNOWN pUnk,
void **ppv
);

##### Parameters

pUnk
  Pointer to the IUnknown interface.
ppv
  Retrieved interface.

##### Return Values

Returns an HRESULT value.

##### Remarks

This member function performs a thread-safe increment of the reference count. To retrieve the interface and add a reference, call this function from your overriding implementation of the INonDelegatingUnknown::NonDelegatingQueryInterface method.

###

IsEqualObject

Object and Pin Functions

Checks if two interfaces are on the same object.

BOOL WINAPI IsEqualObject(
IUnknown * pFirst,
IUnknown * pSecond
);

##### Parameters

pFirst
  Address of one interface.
pSecond
  Address of the other interface.

##### Return Values

Returns TRUE if the interfaces are both on the same object, or FALSE otherwise.

© 1997 Microsoft Corporation. All rights reserved. Terms of Use.