aihot  2017-05-16 22:10:24  OpenCV |   查看评论   
 _Tp, int chs> static int flipVert(const Mat_<_Tp, chs>& src, Mat_<_Tp, chs>& dst);  
  •   
  • // 在垂直,水平或两个轴上翻转2D阵列  
  • // flipCode:0表示在x轴周围翻转,正值表示围绕y轴翻转。  
  • //       负值表示在两个轴上翻转  
  • // 支持类型:uchar/float,多通道  
  • template <typename _Tp, int chs>  
  • int flip(const Mat_<_Tp, chs>& src, Mat_<_Tp, chs>& dst, int flipCode)  
  • {  
  •     FBC_Assert(typeid(uchar).name() == typeid(_Tp).name() || typeid(float).name() == typeid(_Tp).name()); // uchar || float  
  •     if (dst.empty()) {  
  •         dst = Mat_<_Tp, chs>(src.rows, src.cols);  
  •     } else {  
  •         FBC_Assert(src.rows == dst.rows && src.cols == dst.cols);  
  •     }  
  •  

    除特别注明外,本站所有文章均为 赢咖4注册 原创,转载请注明出处来自OpenCV代码提取:flip函数的实现

    留言与评论(共有 0 条评论)
       
    验证码:
    [lianlun]1[/lianlun]