Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Represents a collection of image format properties (e.g. FOURCC, width, height, stride, ...)
Members
Properties
Syntax: public FrameFormatProperties & Properties;
Gets a collection of additional FrameFormat properties.
~FrameFormat
Syntax: public inline virtual ~FrameFormat ( );
Destructs an instance of the FrameFormat class.
GetFourCC
Syntax: public inline std::string GetFourCC ( ) const;
Gets the image format's FOURCC value.
Returns
The FOURCC format code as a string
GetFourCC
Syntax: public inline void GetFourCC ( char * ch1 , char * ch2 , char * ch3 , char * ch4 ) const;
Gets the image format's FOURCC value.
Parameters
ch1Pointer to char to receive FOURCC character 1ch2Pointer to char to receive FOURCC character 2ch3Pointer to char to receive FOURCC character 3ch4Pointer to char to receive FOURCC character 4
GetWidth
Syntax: public inline int GetWidth ( ) const;
Gets the image format's pixel width.
Returns
The image pixel width.
GetHeight
Syntax: public inline int GetHeight ( ) const;
Gets the image format's pixel height.
Returns
The image pixel height.
GetStride
Syntax: public inline int GetStride ( ) const;
Gets the image format's pixel stride.
Returns
The image pixel stride.
SetBitsPerPixel
Syntax: public inline void SetBitsPerPixel ( int bitsPerPixel );
Sets the image format's bits per pixel value.
Parameters
bitsPerPixelThe image's bits per pixel value.
GetBitsPerPixel
Syntax: public inline int GetBitsPerPixel ( ) const;
Gets the image format's bits per pixel value.
Returns
The image's bits per pixel value.
CreateFourCCFormat
Syntax: public inline static std::shared_ptr< FrameFormat > CreateFourCCFormat ( char ch1 , char ch2 , char ch3 , char ch4 , int width , int height , int stride );
Initializes a new instance of the FrameFormat class based on a FourCC value.
Parameters
ch1FOURCC character 1ch2FOURCC character 2ch3FOURCC character 3ch4FOURCC character 4widthThe image format's pixel widthheightThe image format's pixel heightstrideThe image format's pixel stride
Returns
The newly created FrameFormat wrapped inside a std::shared_ptr
CreateRGBFormat
Syntax: public inline static std::shared_ptr< FrameFormat > CreateRGBFormat ( int bitsPerPixel , int width , int height , int stride );
Initializes a new instance of the FrameFormat class for uncompressed 32bit ARGB images.
Parameters
bitsPerPixelThe image format's bits per pixel (e.g. 8, 16, 24, 32, ...)widthThe image format's pixel width (e.g. 640)heightThe image format's pixel height (e.g. 480)strideThe image format's pixel stride
Returns
The newly created FrameFormat wrapped inside a std::shared_ptr
CreateGreyFormat
Syntax: public inline static std::shared_ptr< FrameFormat > CreateGreyFormat ( int bitsPerPixel , int width , int height , int stride );
Initializes a new instance of the FrameFormat class for uncompressed Grey images.
Parameters
bitsPerPixelThe image format's bits per pixel (e.g. 8, 16, 24, 32, ...)widthThe image format's pixel width (e.g. 640)heightThe image format's pixel height (e.g. 480)strideThe image format's pixel stride
Returns
The newly created FrameFormat wrapped inside a std::shared_ptr
CreateBGRFormat
Syntax: public inline static std::shared_ptr< FrameFormat > CreateBGRFormat ( int bitsPerPixel , int width , int height , int stride );
Initializes a new instance of the FrameFormat class for uncompressed BGR images.
Parameters
bitsPerPixelThe image format's bits per pixel (e.g. 8, 16, 24, 32, ...)widthThe image format's pixel width (e.g. 640)heightThe image format's pixel height (e.g. 480)strideThe image format's pixel stride
Returns
The newly created FrameFormat wrapped inside a std::shared_ptr
CreateBGRAFormat
Syntax: public inline static std::shared_ptr< FrameFormat > CreateBGRAFormat ( int bitsPerPixel , int width , int height , int stride );
Initializes a new instance of the FrameFormat class for uncompressed BGRA images.
Parameters
bitsPerPixelThe image format's bits per pixel (e.g. 8, 16, 24, 32, ...)widthThe image format's pixel width (e.g. 640)heightThe image format's pixel height (e.g. 480)strideThe image format's pixel stride
Returns
The newly created FrameFormat wrapped inside a std::shared_ptr