|
IMVFilterInfo
The IMVFilterInfo interface offers several methods to get
general information about a MontiVision image processing
filter. Read the remarks for ímplementation
details.
Header
file: iMVFilterCommon.h
Interface definition language file:
iMVFilterCommon.idl
Interface ID:IID_IMVFilterInfo
HRESULT GetNumOfInPins( [out,
retval] int *piInputPins );
Returns the number of the filter's video input pins.
Parameter:
|
|
piInputPins |
A pointer to an integer value that receives the
number of input pins. |
HRESULT GetNumOfOutPins( [out,
retval] int *piOutputPins );
Returns the number of the filter's video output pins.
Parameter:
|
|
piOutputPins |
A pointer to an integer value that receives the
number of output pins. |
HRESULT get_SelectedInfoPin( [out, retval] int
*piActualPin );
Returns the currently selected info pin.
Parameter:
|
|
piActualPin |
A pointer to an integer value that receives the
currently selected info pin. |
HRESULT put_SelectedInfoPin( [in ] int iActualPin
);
Selects the current
info pin.
Parameter:
|
|
iActualPin |
The selected info pin number.. |
HRESULT get_InfoPinDirection( [out, retval] int
*piPinDirection );
Returns the direction of the selected info pin.
| Value
|
Description
|
| 0 |
Output pin. |
|
1 |
Input Pin |
Parameter:
|
|
piPinDirection |
A pointer to an integer value that receives the
number of input pins. |
HRESULT put_InfoPinDirection( [in ] int
iPinDirection );
Sets the direction of the selected info pin.
| Value
|
Description
|
| 0 |
Output pin. |
|
1 |
Input Pin |
Parameter:
|
|
iPinDirection |
The pin direction. |
HRESULT GetImageInfo( [out] int *piWidth, [out] int
*piHeight, [out] int *piChannel );
Returns the dimensions of the image of the selected info
pin.
Parameter:
|
|
piWidth |
A pointer to an integer value that receives the
image width. |
|
|
piHeight |
A pointer to an integer value that receives the
image height. |
|
|
piChannel |
A pointer to an integer value that receives the
number of color channels as MV_COLOR_CHANNEL. |
HRESULT GetImageWidth( [out, retval] int *piWidth
);
Returns the width of the image on the selected info pin.
Parameter:
|
|
piWidth |
A pointer to an integer value that receives the
image width. |
HRESULT GetImageHeight( [out,
retval] int *piHeight );
Returns the height of the image on the selected info
pin..
Parameter:
|
|
piHeight |
A pointer to an integer value that receives the
image height. |
HRESULT GetNumOfChannels(
[out, retval] int *piChannel );
Returns the number of color channels of the image of the
selected info pin.
Parameter:
|
|
piChannel |
A pointer to an integer value that receives the
number of color channels as MV_COLOR_CHANNEL. |
HRESULT GetSymbol16( [out, retval] byte **ppbySymbol
);
Returns the 16*16 picel icon of the filter.
Parameter:
|
|
ppbySymbol |
A pointer to a pointer that receives the filter
icon as Windows BITMAP structure. |
HRESULT GetSymbol32( [out, retval] byte **ppbySymbol
);
Returns the 32*32 pixel icon of the filter.
Parameter:
|
|
ppbySymbol |
A pointer to a pointer that receives the filter
icon as Windows BITMAP structure. |
The following sequence is used to receive information about the
image dimension of a pin.
int iNumOfInPins, iWidth, iHeight,
iChannel;
IMVFilterInfo *pIMVFilterInfo;
pIMVFilterInfo->GetNumOfInPins(
&iInputPins );
if( iNumOfInPins > 0 )
{
pIMVFilterInfo->put_InfoPinDirection( 1 );
pIMVFilterInfo->put_SelectedInfoPin ( 0 );
pIMVFilterInfo->GetImageInfo( &iWidth, &iHeight,
&iChannel );
}
|