TRVCamVideoMode, TRVColorModel types

<< Click to display table of contents >>

TRVCamVideoMode, TRVColorModel types

Contains information about webcam video mode.

Unit [VCL and LCL] MRVType;

Unit [FMX] fmxMRVType;

 

For Windows

type
  TRVColorModel = (rvcmARGB, rvcmRGB, rvcmYV, rvcmOther);
  TRVCamVideoMode = packed record
    Index:       Integer;

    Width:       Integer;

    Height:      Integer;

    ColorDepth:  byte;

    ColorModel:  TRVColorModel;

    VideoFormat: String;

    majortype:   TGUID;

    subtype:     TGUID;

    formattype:  TGUID;
  end;

Fields:

Width, Height – video frame size

ColorDepth – bytes per pixel

ColorModel – color mode

 

For Linux

type
  TRVCamVideoMode = record
    Width, Height: Integer;
    PixelFormat: Cardinal;
  end;

Width, Height – video frame size

PixelFormat is one of values returned by the functions from mrvlcl_lin_v4l2 unit:

ofunction V4L2_PIX_FMT_RGB24: int64;

ofunction V4L2_PIX_FMT_RGB32: int64;

ofunction V4L2_PIX_FMT_YUYV: int64;

If you want to display a format name in UI, you can use the function from mrvlcl_lin_WebCamera unit:

function GetWebCamPixelFormat(PixelFormat: Cardinal): String;

 

See also

TRVCamera's webcam video mode methods