Condividi tramite


Pin Property Set

 
Microsoft DirectShow 9.0

Pin Property Set

The pin property set returns the pin category for a pin on a filter. The category is set by the filter when it creates the pin; the category indicates what type of data the pin is delivered or receives by this pin.

Property Set GUID AMPROPSETID_Pin
Property ID Descriptiom
AMPROPERTY_PIN_CATEGORY Specifies the category of a pin.

DirectShow defines the following pin categories in the Uuids.h header file.

Category GUID Description
PIN_CATEGORY_ANALOGVIDEOIN Input pin of the capture filter that takes analog and digitizes it.
PIN_CATEGORY_CAPTURE Capture pin.
PIN_CATEGORY_CC Pin providing closed captioning data from Line 21.
PIN_CATEGORY_EDS Pin providing Extended Data Services (Line 21, even fields).
PIN_CATEGORY_NABTS Pin providing North American Videotext Standard data.
PIN_CATEGORY_PREVIEW Preview pin.
PIN_CATEGORY_STILL Pin that provides a still image. The filter's capture pin must be connected before the still-image pin is connected.
PIN_CATEGORY_TELETEXT Pin providing teletext (a closed captioning variant).
PIN_CATEGORY_TIMECODE Pin providing timecode data.
PIN_CATEGORY_VBI Pin providing vertical blanking interval data.
PIN_CATEGORY_VIDEOPORT Video output pin to be connected to input pin zero on the Overlay Mixer.
PIN_CATEGORY_VIDEOPORT_VBI Pin to be connected to the VBI Surface Allocator, the VBI surface allocator filter that is needed to allocate the correct video memory for things like closed captioning overlays in scenarios where a video port is being used. PCI, IEEE 1394, and USB scenarios do not use this filter. For more information, see Microsoft TV Technologies.
PINNAME_VIDEO_CC_CAPTURE Hardware slicing closed-captioning pin

This property is read-only.

Example Code

The following code shows how to check whether a pin supports this property set, and if so, how to obtain the pin category:

HRESULT GetPinCategory(IPin *pPin, GUID *pPinCategory)
{
    HRESULT hr;
    IKsPropertySet *pKs;
    hr = pPin->QueryInterface(IID_IKsPropertySet, (void **)&pKs);
    if (FAILED(hr))
    {
        // The pin does not support IKsPropertySet.
        return hr;
    }
    // Try to retrieve the pin category.
    DWORD cbReturned;
    hr = pKs->Get(AMPROPSETID_Pin, AMPROPERTY_PIN_CATEGORY, NULL, 0, 
        pPinCategory, sizeof(GUID), &cbReturned);

    // If this succeeded, pPinCategory now contains the category GUID.

    pKs->Release();
    return hr;
}

See Also