Expand Minimize

MF_MT_FRAME_SIZE attribute

Width and height of a video frame, in pixels.

Data type

UINT64

Remarks

The upper 32 bits contain the width and the lower 32 bits contain the height.

To set this attribute, use the MFSetAttributeSize function. To get this attribute, use the MFGetAttributeSize function.

The GUID constant for this attribute is exported from mfuuid.lib.

Examples


// Helper function to set the frame size on a video media type.
inline HRESULT SetFrameSize(IMFMediaType *pType, UINT32 width, UINT32 height)
{
    return MFSetAttributeSize(pType, MF_MT_FRAME_SIZE, width, height);
}

// Helper function to get the frame size from a video media type.
inline HRESULT GetFrameSize(IMFMediaType *pType, UINT32 *pWidth, UINT32 *pHeight)
{
    return MFGetAttributeSize(pType, MF_MT_FRAME_SIZE, pWidth, pHeight);
}


Requirements

Minimum supported client

Windows Vista [desktop apps | Windows Store apps]

Minimum supported server

Windows Server 2008 [desktop apps | Windows Store apps]

Header

Mfapi.h

See also

IMFMediaType
Media Type Attributes

 

 

Community Additions

ADD
Show:
© 2014 Microsoft