Data type description for an image plane. More...
#include <cvb/data_type.hpp>
Public Member Functions | |
template<template< class > class T, class ACTION , class... CTORARGS> | |
auto | CallWithInstanceOf (ACTION action, CTORARGS... args) const -> decltype(action(T< int >{std::forward< CTORARGS >(args)...})) |
Calls action with T instance of native data type this value represents. More... | |
template<class T > | |
bool | Matches () const noexcept |
Gets whether the type T matches this data type. More... | |
int | NativeDescriptor () const noexcept |
Native data type descriptor. More... | |
int | BitsPerPixel () const noexcept |
Number of actually valid bits per pixel. More... | |
int | BytesPerPixel () const noexcept |
Number of bytes occupied by each pixel. More... | |
bool | IsFloat () const noexcept |
Gets whether the pixels of the plane have floating point values. More... | |
bool | IsSignedInteger () const noexcept |
Gets whether the pixels of the plane have signed integer values. More... | |
bool | IsUnsignedInteger () const noexcept |
Gets whether the pixels of the plane have unsigned integer values. More... | |
bool | IsSigned () const noexcept |
Gets whether the pixels of the plane have signed values. More... | |
bool | HasOverlayBit () const noexcept |
Gets whether bit 0 of the pixels of the plane are being used as an overlay indicator bit. More... | |
bool | IsComplexPacked () const noexcept |
Indicates whether or not the plane contains a complex packed image format. More... | |
double | MinVal () const noexcept |
Gets the minimum pixel value that fits this data type. More... | |
double | MaxVal () const noexcept |
Gets the maximum pixel value that fits this data type. More... | |
PixelDataType | NumericType () const noexcept |
Returns the basic numeric type of the pixels. More... | |
double | UndefinedVal () const noexcept |
Get the undefined value for this data type. More... | |
bool | operator== (const DataType &dataType) const noexcept |
Compares to an other data type. More... | |
bool | operator!= (const DataType &dataType) const noexcept |
Compares to an other data type. More... | |
Static Public Member Functions | |
static DataType | FromNativeDescriptor (int dataTypeDescriptor) noexcept |
Construct a data type descriptor from one of the native library's descriptor values. More... | |
static DataType | Int8BppUnsigned () noexcept |
Represents 8-bit unsigned integer pixels (bytes). More... | |
static DataType | Int8BppSigned () noexcept |
Represents 8-bit signed integer pixels. More... | |
static DataType | Int10BppUnsigned () noexcept |
Represents 10-bit unsigned integer pixels. More... | |
static DataType | Int12BppUnsigned () noexcept |
Represents 12-bit unsigned integer pixels. More... | |
static DataType | Int16BppUnsigned () noexcept |
Represents 16-bit unsigned integer pixels. More... | |
static DataType | Int16BppSigned () noexcept |
Represents 16-bit signed integer pixels. More... | |
static DataType | Int32BppUnsigned () noexcept |
Represents 32-bit unsigned integer pixels. More... | |
static DataType | Int32BppSigned () noexcept |
Represents 32-bit signed integer pixels. More... | |
static DataType | Int64BppUnsigned () noexcept |
Represents 64-bit unsigned integer pixels. More... | |
static DataType | Int64BppSigned () noexcept |
Represents 64-bit signed integer pixels. More... | |
static DataType | Float32Bpp () noexcept |
Represents single precision (32-bit) floating point pixels. More... | |
static DataType | Float64Bpp () noexcept |
Represents double precision (64-bit) floating point pixels. More... | |
template<typename T > | |
static DataType | FromNativeType () noexcept |
Construct a data type descriptor from one of the native data type value equivalents. More... | |
Data type description for an image plane.
|
inlinenoexcept |
Number of actually valid bits per pixel.
Does | not throw any exception. |
|
inlinenoexcept |
Number of bytes occupied by each pixel.
Does | not throw any exception. |
|
inline |
Calls action with T instance of native data type this value represents.
T | Template template that is instantiated with a data type like uint8_t. |
ACTION | Callable that accepts one T value as argument. |
CTORARGS | Types of arguments passed to the ctor of T . |
[in] | action | Callable accepting exactly one T instance by value. |
[in] | args | Optional arguments forwarded to the T constructor. |
T
value. CvbException | if there is no compatible native data type; except action throws |
|
inlinestaticnoexcept |
Represents single precision (32-bit) floating point pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents double precision (64-bit) floating point pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Construct a data type descriptor from one of the native library's descriptor values.
[in] | dataTypeDescriptor | Native descriptor value. |
Does | not throw any exception. |
|
inlinestaticnoexcept |
Construct a data type descriptor from one of the native data type value equivalents.
Does | not throw any exception. |
The usage is as follows:
|
inlinenoexcept |
Gets whether bit 0 of the pixels of the plane are being used as an overlay indicator bit.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 10-bit unsigned integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 12-bit unsigned integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 16-bit signed integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 16-bit unsigned integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 32-bit signed integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 32-bit unsigned integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 64-bit signed integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 64-bit unsigned integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 8-bit signed integer pixels.
Does | not throw any exception. |
|
inlinestaticnoexcept |
Represents 8-bit unsigned integer pixels (bytes).
Does | not throw any exception. |
|
inlinenoexcept |
Indicates whether or not the plane contains a complex packed image format.
Does | not throw any exception. |
Such a format that makes use of the hermitian symmetries in images resulting from Fourier transformation of a real-valued image.
|
inlinenoexcept |
Gets whether the pixels of the plane have floating point values.
Does | not throw any exception. |
|
inlinenoexcept |
Gets whether the pixels of the plane have signed values.
Does | not throw any exception. |
|
inlinenoexcept |
Gets whether the pixels of the plane have signed integer values.
Does | not throw any exception. |
|
inlinenoexcept |
Gets whether the pixels of the plane have unsigned integer values.
Does | not throw any exception. |
|
inlinenoexcept |
Gets whether the type T
matches this data type.
T
matches this data type if the BytesPerPixel() match its size and if the signed/integer/float traits match.
T | Numeric plain old data type. |
T
is compatible; false if not. Does | not throw any exception. |
|
inlinenoexcept |
Gets the maximum pixel value that fits this data type.
Does | not throw any exception. |
|
inlinenoexcept |
Gets the minimum pixel value that fits this data type.
Does | not throw any exception. |
|
inlinenoexcept |
Native data type descriptor.
Does | not throw any exception. |
|
inlinenoexcept |
Returns the basic numeric type of the pixels.
Does | not throw any exception. |
|
inlinenoexcept |
Compares to an other data type.
[in] | dataType | Other data type. |
Does | not throw any exception. |
|
inlinenoexcept |
Compares to an other data type.
[in] | dataType | Other data type. |
Does | not throw any exception. |
|
inlinenoexcept |
Get the undefined value for this data type.
Does | not throw any exception. |
Pixel value for those pixels whose value cannot be defined correctly. For example in scanning situations, where pixels outside the image are accessed.