Video Resizer DSP

Resizes a video stream.

CLSID

CLSID_CResizerDMO

Interfaces

Formats

The Video Resizer DSP supports the following input/output media subtypes when it is acting as a DirectX Media Object (DMO).

  • MEDIASUBTYPE_IYUV
  • MEDIASUBTYPE_YUY2
  • MEDIASUBTYPE_UYVY
  • MEDIASUBTYPE_I420
  • MEDIASUBTYPE_RGB32
  • MEDIASUBTYPE_RGB24
  • MEDIASUBTYPE_RGB565
  • MEDIASUBTYPE_RGB8
  • MEDIASUBTYPE_RGB555
  • MEDIASUBTYPE_AYUV
  • MEDIASUBTYPE_V216
  • MEDIASUBTYPE_YV12

The Video Resizer DSP supports the following input/output media subtypes when it is acting as a Media Foundation Transform (MFT).

  • MFVideoFormat_IYUV
  • MFVideoFormat_YUY2
  • MFVideoFormat_UYVY
  • MFVideoFormat_I420
  • MFVideoFormat_RGB32
  • MFVideoFormat_RGB24
  • MFVideoFormat_RGB565
  • MFVideoFormat_RGB8
  • MFVideoFormat_RGB555
  • MFVideoFormat_AYUV
  • MFVideoFormat_V216
  • MFVideoFormat_YV12

Properties

Remarks

The Video Resizer DSP is implemented as a COM object that can act as a DMO or an MFT. The object has a single class identifier (CLSID) regardless of whether it acts as a DMO or an MFT. For information about when a DSP acts as a DMO or an MFT, see Digital Signal Processors.

The globally unique identifiers (GUIDs) for RGB media subtypes differ depending on whether a DSP is acting as a DMO or an MFT. The GUIDs for non-RGB media subtypes are the same, regardless of whether a DSP is acting as a DMO or an MFT. For information about the GUIDs that represent media subtypes, see Video Subtype GUIDs.

This DSP can perform both cropping and scaling on the video image. The format of the output type must match the format of the input type. The DSP does not perform color-space conversions.

Before setting the output type, you can define any of the following regions by using the properties listed in this table.

Region Properties
Source rectangle MFPKEY_RESIZE_SRC_LEFT
MFPKEY_RESIZE_SRC_TOP
MFPKEY_RESIZE_SRC_WIDTH
MFPKEY_RESIZE_SRC_HEIGHT
Destination rectangle MFPKEY_RESIZE_DST_LEFT
MFPKEY_RESIZE_DST_TOP
MFPKEY_RESIZE_DST_WIDTH
MFPKEY_RESIZE_DST_HEIGHT
Geometric aperture MFPKEY_RESIZE_GEOMAPX
MFPKEY_RESIZE_GEOMAPY
MFPKEY_RESIZE_GEOMAPWIDTH
MFPKEY_RESIZE_GEOMAPHEIGHT
Minimum display aperture MFPKEY_RESIZE_MINAPX
MFPKEY_RESIZE_MINAPY
MFPKEY_RESIZE_MINAPWIDTH
MFPKEY_RESIZE_MINAPHEIGHT
Pan/scan region MFPKEY_RESIZE_PANSCANAPX
MFPKEY_RESIZE_PANSCANAPY
MFPKEY_RESIZE_PANSCANAPWIDTH
MFPKEY_RESIZE_PANSCANAPHEIGHT

 

In each case, you must set all of the associated properties for the setting to take effect.

The DSP copies the portion of the source image defined by source rectangle, and stretches or compresses it onto the destination rectangle on the output buffer. The source and destination rectangles do not need to be the same size. The frame size in the output media type must be large enough to hold the destination rectangle.

The geometric aperture, minimum display aperture, and pan/scan region do not affect how the DSP resizes the video. However, they might affect how the downstream component interprets the video frame. In particular, the enhanced video renderer (EVR) uses these values when it calculates the picture aspect ratio and the display area.

If you are using Media Foundation media types, you can set the geometric aperture, minimum display aperture, and pan/scan regions directly in the output media type. Otherwise, if you are using DMO media types, set them using the properties.

For more information, see the following topics:

Requirements

Minimum supported client
Windows Vista [desktop apps only]
Minimum supported server
Windows Server 2008 [desktop apps only]
Header
Wmcodecdsp.h
DLL
Vidreszr.dll

See also

Digital Signal Processors