使用openCV从另一个图像中减去一个图像 [英] subtract one image from another using openCV

查看:307
本文介绍了使用openCV从另一个图像中减去一个图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使用openCV从另一个图像中减去一个图像?

How can I subtract one image from another using openCV?

Ps:我不能使用python实现,因为我必须在C ++中这样做

Ps.: I coudn't use the python implementation because I'll have to do it in C++

推荐答案

使用 LoadImage 将图像加载到内存中,然后使用 Sub 方法。

Use LoadImage to load your images into memory, then use the Sub method.

此链接包含一些示例代码,如果有帮助: http:// permalink.gmane.org/gmane.comp.lib.opencv/36167

This link contains some example code, if that will help: http://permalink.gmane.org/gmane.comp.lib.opencv/36167

这篇关于使用openCV从另一个图像中减去一个图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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