aimstil  5.0.5
til::precision< T > Struct Template Reference

Numerical precision of the data for storage classes. More...

#include <til/traits.h>

Inheritance diagram for til::precision< T >:

Detailed Description

template<typename T>
struct til::precision< T >

Numerical precision of the data for storage classes.

Stores the precision of the class, i.e. the format in which ultimately the data is stored. E.g. precision<ImageC<double> >::type is double. precision<std::complex<float> > is float, not complex<float>. This allows to check whether data types are compatible, independently of the object itself. Mainly for performance reasons. E.g. when multiplying a matrix image with a constant vector, this could be used to check that the precision of matrices in the image and the constant vector are the same, to avoid to do a cast for every multiplication. Note that this is completely different from Container::value_type, which merely gives the type of the containee without cascading down to the encoding type.

Definition at line 48 of file traits.h.


The documentation for this struct was generated from the following file: