在OpenCV中移动(类似于Matlab函数)矩阵的行或列 [英] Shift (like Matlab function) rows or columns of a matrix in OpenCV

查看:111
本文介绍了在OpenCV中移动(类似于Matlab函数)矩阵的行或列的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Matlab中,具有移位功能,以便对矩阵的列或行执行循环移位. OpenCV中有类似的功能吗?

In Matlab there is a shift function in order to perform a circular shift of the columns or rows of a matrix. There is a similar function in OpenCV?

推荐答案

简短答案,不.

长答案,如果确实需要它,可以轻松实现它,例如使用cv::Mat::row(i)cv::Mat::(cv::Range(rowRange), cv::Range(cv::colRange))的临时对象.

Long answer, you can implement it easily if you really need it, for example using temporary objects using cv::Mat::row(i), cv::Mat::(cv::Range(rowRange), cv::Range(cv::colRange)).

这篇关于在OpenCV中移动(类似于Matlab函数)矩阵的行或列的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆