1 #ifndef CVD_BUILTIN_TRAITS_H_ 2 #define CVD_BUILTIN_TRAITS_H_ 7 #if defined(CVD_HAVE_TOON) 22 template <
class P,
int spp>
41 static const size_t count = 1;
43 static const P&
get(
const P& pixel, size_t)
48 static P&
get(P& pixel, size_t)
54 template <
class P,
int I>
58 static const size_t count = I;
60 static const P&
get(
const P pixel[I],
size_t i)
65 static inline P&
get(P pixel[I],
size_t i)
71 #if defined(CVD_HAVE_TOON) 72 template <
int N,
typename P>
76 static const size_t count = N;
78 static inline const P&
get(
const TooN::Vector<N, P>& pixel,
size_t i)
83 static inline P&
get(TooN::Vector<N, P>& pixel,
size_t i)
89 template <
int N,
int M,
typename P>
93 static const size_t count = N * M;
95 static const P&
get(
const TooN::Matrix<N, M, P>& pixel,
size_t i)
97 return pixel[i / M][i % M];
100 static inline P&
get(TooN::Matrix<N, M, P>& pixel,
size_t i)
102 return pixel[i / M][i % M];
Definition: builtin_components.h:26
All classes and functions are within the CVD namespace.
Definition: argb.h:6
Definition: builtin_components.h:23
Definition: builtin_components.h:38