如何分离两个轮廓(C ++,绘制轮廓)? [英] How to separate two contours (C++,Draw Contours) ?

查看:99
本文介绍了如何分离两个轮廓(C ++,绘制轮廓)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我能够在opencv中使用findcontour功能找到两只手,并且能够绘制轮廓。但是当我关闭我的两只手时,它变成一个轮廓。所以我不能单独绘制它们。我可以分开这两个轮廓?希望我的问题很清楚。需要提前指导......提前感谢...

i was able to find both the hands using findcontour function in opencv and able to draw the contours as well.but when i close my two hands it becomes one contour.so i cannot draw them separately.how can i separate these two contours? hope my question is clear.Need guidance...Thanks in advance...

推荐答案

除非你的代码知道人体解剖学,否则你不能这样做。



想象一下,来自外星文明的知识分子第一次看到人类,在纯净的光线条件下,人类紧紧握住两只手(如果你有很好的想象力,我想这很容易想象,不是吗?:-))。我担心生物也难以识别两个独立的肢体。



这个问题本来就没有明确定义,这不是你的错。它本来就很困难,类似于那些不适定问题之一。很抱歉没有给你一个解决方案。试想一下。



-SA
You cannot do it in general case, unless your code is aware of human anatomy.

Imagine an intellectual person from an extraterrestrial civilization who sees a human for the very first time, in pure lighting condition, and that human holds two hands close together (if you have a good imagination, I guess it''s easy to imagine, isn''t it? :-)). I''m afraid that creature also would have trouble to recognize two separate limbs.

The problem is inherently not well defined, and this is not your fault. It is inherently difficult, resembles one of those ill-posed problems. Sorry for not giving you a solution. Just think about it.

—SA


这篇关于如何分离两个轮廓(C ++,绘制轮廓)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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