Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This interface represents a single, unidirectional connection point on a filter. A pin connects to exactly one other pin on another filter. Other objects can use this interface on this pin. The interface between the filter and the pin is private to the implementation of a specific filter.

During the connection process, one pin takes the lead. The base classes assume that this is the output pin of the upstream connecting filter.

The filter graph manager calls the IPin::Connectmethod on this pin's IPininterface, passing the IPinpointer for the connecting pin. This connecting pin then calls the IPin::ReceiveConnectionmethod located on the other pin, in addition to its format-enumeration, IUnknown::QueryInterface, and possibly IPin::QueryAcceptmethods, to establish whether the connection is possible.

When to Implement

All filters must implement this interface on each of its pins.

Which methods are implemented depends on whether the pin is an input pin or an output pin.

Use the CBasePin, CBaseInputPin, or CBaseOutputPinclass, or classes derived from these classes, to implement this interface.

When to Use

This interface is used by other connecting pins and by the filter graph manager.

Applications should not use this interface directly but should go through the filter graph manager.

Connecting pins use the IPininterface on the opposite pin to negotiate a common media type and an agreed allocator to use for passing samples.

Methods in Vtable Order

The following table shows the methods that appear in the Vtable beneath the standard COM methods inherited from IUnknown.

Method Description

Connect

Makes a connection to another pin.

ReceiveConnection

Makes a connection to this pin and is called by a connecting pin.

Disconnect

Breaks a connection.

ConnectedTo

Returns a pointer to the connecting pin.

ConnectionMediaType

Returns the media type of this pin's connection.

QueryPinInfo

Retrieves information about this pin (for example, the name, owning filter, and direction).

QueryId

Retrieves an identifier for the pin.

QueryAccept

Queries whether a given media type is acceptable by the pin.

EnumMediaTypes

Provides an enumerator for this pin's preferred media types.

QueryInternalConnections

Provides an array of the pins to which this pin internally connects.

EndOfStream

Informs the pin that no additional data is expected until a new run command is issued.

BeginFlush

Informs the pin to begin a flush operation.

EndFlush

Informs the pin to end a flush operation.

NewSegment

Specifies that samples following this call are grouped as a segment with a given start time, stop time, and rate.

QueryDirection

Retrieves the direction for this pin.

Requirements

Windows Embedded CE Windows CE 2.12 and later
Windows Mobile Pocket PC for Windows Mobile Version 5.0 and later, Smartphone for Windows Mobile Version 5.0 and later
Note Microsoft DirectShow applications and DirectShow filters have different include file and Library requirements
For more information, see Setting Up the Build Environment

See Also