Export (0) Print
Expand All
Expand Minimize

KS_VIDEOINFO structure

The KS_VIDEOINFO structure describes the bitmap and color information for a video stream.

Syntax


typedef struct tagKS_VIDEOINFO {
  RECT                rcSource;
  RECT                rcTarget;
  DWORD               dwBitRate;
  DWORD               dwBitErrorRate;
  REFERENCE_TIME      AvgTimePerFrame;
  KS_BITMAPINFOHEADER bmiHeader;
  union {
    KS_RGBQUAD       bmiColors[KS_iPALETTE_COLORS];
    DWORD            dwBitMasks[KS_iMASK_COLORS];
    KS_TRUECOLORINFO TrueColorInfo;
  };
} KS_VIDEOINFO, *PKS_VIDEOINFO;

Members

rcSource

Specifies a clipping rectangle that selects the portion of the active video signal to use.

rcTarget

Specifies a rectangle that indicates which part of the target buffer to use.

dwBitRate

Specifies a value that indicates the video stream's approximate data rate, in bits per second.

dwBitErrorRate

Specifies a value that indicates the video stream's data error rate, in bit errors per second.

AvgTimePerFrame

Specifies the average time per frame in 100-nanosecond units.

bmiHeader

Describes a KS_BITMAPINFOHEADER structure that contains color and dimension information about the video image bitmap.

bmiColors

Array of KS_RGBQUAD structures that specifies the video's color palette. Each structure represents a single color, which is a combination of red, green, and blue intensities.

dwBitMasks

Array of DWORD values that specify true-color bitmasks.

TrueColorInfo

KS_TRUECOLORINFO structure that contains both a color palette and an array of color bitmasks.

Remarks

This structure must not be used unless the biSize member of the KS_BITMAPINFOHEADER member is set to sizeof(KS_BITMAPINFOHEADER).

A source filter can request that the sink filter take only a section of the video by providing values that effectively define a clipping rectangle in the rcSource member. However, if the sink filter does not check for the clipping rectangle on connection, the sink filter simply renders all of the video, effectively ignoring any clipping information passed from the source filter to the sink filter.

Ideally, a sink filter checks rcSource and if the sink filter does not support image extraction and the rectangle is not empty, then it rejects the connection. A filter should use the Win32 function SetRectEmpty to reset a rectangle to all zeros (and IsRectEmpty to later check the rectangle).

The rcTarget member specifies the destination rectangle for the video. Most source filters set this member to all zeros. A downstream filter can request that the video be placed in a particular area of the buffers it supplies. In this case, it calls the Win32 function QueryAccept with a nonempty target.

Requirements

Header

Ksmedia.h (include Ksmedia.h)

See also

KS_BITMAPINFOHEADER
KS_RGBQUAD
KS_TRUECOLORINFO

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft