#ifndef WEIGHTEDSUM_H #define WEIGHTEDSUM_H #include #include namespace icl { /// Accumulate weighted pixel values of all image channels /** Pixels of all channels in source image are weighted by a channel-wise weight and accumulated to the destination image. Performance: 1000x1000x10 image IPP C++ icl8u 175ms 86ms icl32f 165ms 85ms */ class WeightedSum : public Filter { public: void apply (ImgBase *poSrc, Img *poDst, const std::vector& weights); private: #if 0 && defined WITH_IPP_OPTIMIZATION std::vector m_oBuffer; #endif template void compute(const Img *src, Img *dst, const std::vector& weights); }; } // namespace icl #endif