Defines general useful formats and new data types Non-virtual, meaning no dynamic_cast as string comparison is as fast/faster.
More...
#include <formats.h>
|
size_t | getSizeInBytes () const |
|
size_t | getSize () const |
|
size_t | getComponents () const |
|
size_t | getPrecision () const |
|
NumericType | getNumericType () const |
|
double | getMax () const |
|
double | getMin () const |
|
double | getLowest () const |
|
std::string_view | getString () const |
|
DataFormatId | getId () const |
|
|
static const DataFormatBase * | get () |
|
static const DataFormatBase * | get (DataFormatId id) |
|
static const DataFormatBase * | get (std::string_view name) |
|
static const DataFormatBase * | get (NumericType type, size_t components, size_t precision) |
|
template<typename T> |
static constexpr DataFormatId | typeToId () noexcept |
|
|
DataFormatId | formatId_ |
|
size_t | components_ |
|
size_t | sizeInBytes_ |
|
NumericType | numericType_ |
|
double | max_ |
|
double | min_ |
|
double | lowest_ |
|
std::string_view | formatStr_ |
|
Defines general useful formats and new data types Non-virtual, meaning no dynamic_cast as string comparison is as fast/faster.
◆ getComponents()
size_t inviwo::DataFormatBase::getComponents |
( |
| ) |
const |
Returns the number of components in the format, 1 to 4.
◆ getPrecision()
size_t inviwo::DataFormatBase::getPrecision |
( |
| ) |
const |
Returns number of bits in each component in the format. can be 8, 16, 32 or 64.
◆ getSizeInBytes()
size_t inviwo::DataFormatBase::getSizeInBytes |
( |
| ) |
const |
Returns the size of the format in bytes. For all components.
The documentation for this class was generated from the following file: