diff options
Diffstat (limited to 'meowpp/colors/YUV.h')
-rw-r--r-- | meowpp/colors/YUV.h | 63 |
1 files changed, 0 insertions, 63 deletions
diff --git a/meowpp/colors/YUV.h b/meowpp/colors/YUV.h deleted file mode 100644 index 0b48375..0000000 --- a/meowpp/colors/YUV.h +++ /dev/null @@ -1,63 +0,0 @@ -#ifndef colors_YUV_H_ -#define colors_YUV_H_ - -#include "RGB.h" - -#include <cstdlib> - -namespace meow{ - template<class T> - class YUV{ - protected: - T yuv_[3]; - YUV(); - YUV(T const& y, T const& u, T const& v); - YUV(T const* yuv); - public: - virtual ~YUV() { } - ///////////////// **# not force #** //////////////// - virtual T yMax() const = 0; - virtual T yMin() const = 0; - virtual T uMax() const = 0; - virtual T uMin() const = 0; - virtual T vMax() const = 0; - virtual T vMin() const = 0; - /////////////////// **# access #** ///////////////// - T y() const; - T u() const; - T v() const; - T yuv(size_t i) const; - T vuy(size_t i) const; - /////////////////// **# setting #** //////////////// - T y(T const& val); - T u(T const& val); - T v(T const& val); - T yuv(size_t i, T const& val); - T vuy(size_t i, T const& val); - }; - - class YUVf: public YUV<double>{ - public: - YUVf(); - ~YUVf(); - YUVf(double const& y, double const& u, double const& v); - YUVf(double const* yuv); - double yMin() const; - double yMax() const; - double uMin() const; - double uMax() const; - double vMin() const; - double vMax() const; - }; - - template<class YUV_T1, class YUV_T2> - inline void YUV_to_YUV(YUV<YUV_T1> const& a, YUV<YUV_T2>* b); - template<class RGB_T, class YUV_T> - inline void RGB_to_YUV(RGB<RGB_T> const& rgb, YUV<YUV_T>* yuv); - template<class YUV_T, class RGB_T> - inline void YUV_to_RGB(YUV<YUV_T> const& yuv, RGB<RGB_T>* rgb); -} - -#include "YUV.hpp" - -#endif // colors_YUV_H_ |