PixelFormat.hh
Provides supporting functions for PixelFormat enum.
Definition: PixelFormat.hh:64
STL class.
@ PF_BAYER_RGGB8
< Bayer RGGB, 1-byte per channel
Definition: PixelFormat.hh:43
static unsigned int MemorySize(PixelFormat _format, unsigned int _width, unsigned int _height)
Get total memory size in bytes for an image with the given format and dimensions. If an invalid forma...
@ PF_BAYER_GBGR8
< Bayer GBGR, 1-byte per channel
Definition: PixelFormat.hh:47
static PixelFormat Enum(const std::string &_name)
Get enum value by human-readable name. The given string should match watch is returned by GetName....
static unsigned int BytesPerPixel(PixelFormat _format)
Get number of bytes per pixel for given format. If an invalid format is given, 0 will be returned....
static unsigned int BytesPerChannel(PixelFormat _format)
Get number of bytes per channel for given format. If an invalid format is given, 0 will be returned.
static unsigned int ChannelCount(PixelFormat _format)
Get number of channels for given format. If an invalid format is given, 0 will be returned.
static std::string Name(PixelFormat _format)
Get human-readable name for pixel format value.
@ PF_BAYER_GRGB8
< Bayer GRGB, 1-byte per channel
Definition: PixelFormat.hh:49
static PixelFormat Sanitize(PixelFormat _format)
Sanitize given format. If the given value is invalid, PF_UNKNOWN will be returned,...
static bool IsValid(PixelFormat _format)
Determine if given format is valid PixelFormat enum.
@ PF_BAYER_BGGR8
< Bayer BGGR, 1-byte per channel
Definition: PixelFormat.hh:45