#ifndef TCG_IMAGE_OPS_H #define TCG_IMAGE_OPS_H // tcg includes #include "pixel_ops.h" namespace tcg { //*********************************************************************** // Image Traits definition //*********************************************************************** template struct image_traits_types { typedef Img image_type; typedef typename Img::pixel_type pixel_type; typedef typename Img::pixel_ptr_type pixel_ptr_type; typedef typename Img::pixel_category pixel_category; }; //------------------------------------------------------------------- template class image_traits : public image_traits_types { typedef image_traits_types tr; public: static int width(const typename tr::image_type &img); static int height(const typename tr::image_type &img); static int wrap(const typename tr::image_type &img); static typename tr::pixel_ptr_type pixel(const typename tr::image_type &img, int x, int y); static typename tr::pixel_type outsideColor( const typename tr::image_type &img); }; namespace image_ops { //*********************************************************************** // Image Functions //*********************************************************************** template void blurRows(const ImgIn &imgIn, ImgOut &imgOut, int radius, Scalar = 0); template void blurRows(const ImgIn &imgIn, ImgOut &imgOut, int radius, SelectorFunc func, Scalar = 0); template void blurCols(const ImgIn &imgIn, ImgOut &imgOut, int radius, Scalar = 0); template void blurCols(const ImgIn &imgIn, ImgOut &imgOut, int radius, SelectorFunc func, Scalar = 0); template void blur(const Img &imgIn, Img &imgOut, int radius, Scalar = 0); template void blur(const Img &imgIn, Img &imgOut, int radius, SelectorFunc func, Scalar = 0); } } // namespace tcg::image_ops #endif // TCG_IMAGE_OPS_H //=================================================================== #ifdef INCLUDE_HPP #include "hpp/image_ops.hpp" #endif // INCLUDE_HPP