21#ifndef __mia_internal_convert_hh
22#define __mia_internal_convert_hh
61 template <
template <
typename>
class Data,
typename T>
62 typename TConvert<Image>::result_type operator () (
const Data<T>& data)
const;
65 template <
template <
typename>
class Data,
typename S,
typename T>
66 typename TConvert<Image>::result_type convert(
const Data<S>& src)
const;
67 typename TConvert::result_type do_filter(
const Image& image)
const;
83 TConvertFilterPlugin();
86 virtual const std::string do_get_descr()
const;
102template <
typename T,
bool is_
float>
111struct __mia_round<T, false> {
112 static T apply(
long double x)
114 return static_cast<T
>(floor(x + 0.5));
118template <
typename T,
bool is_
float>
119struct __dispatch_minmax {
120 static std::pair<T, T> apply()
122 return std::pair<T, T>(std::numeric_limits<T>::min(), std::numeric_limits<T>::max());
127struct __dispatch_minmax<T, true> {
128 static std::pair<T, T> apply()
130 return std::pair<T, T>(-1.0f, 1.0f);
136 static std::pair<T, T> apply()
138 return __dispatch_minmax<T, std::is_floating_point<T>::value >::apply();
Generic image filter plugin base.
Generic interface class to data filters.
TFilter< std::shared_ptr< D > >::result_type result_type
result type of this filter
#define NS_MIA_BEGIN
conveniance define to start the mia namespace
#define NS_MIA_END
conveniance define to end the mia namespace