Ask Your Question
0

How to Draw a box then detect if object just enter on it

asked 2017-09-24 12:24:57 -0600

Kanser gravatar image

Hello just like the title i just want to ask How to Draw a box then detect if object just enter on it. Using opencv and python hopefully some of you guys can help me thanksss

edit retag flag offensive close merge delete

Comments

what did you try so far ?

(we can help you with your program, but we won't write it)

berak gravatar imageberak ( 2017-09-25 00:23:05 -0600 )edit

im done doing the haar classifier now next is to count the detected object

Kanser gravatar imageKanser ( 2017-09-26 10:49:46 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2017-10-19 08:26:33 -0600

moHe gravatar image

updated 2017-10-21 23:34:15 -0600

You can use cv2.moments(cnt) to get the center of gravity of you object, and calculate the distance between it and the center of the box to decide if it's at the center of it.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2017-09-24 12:24:57 -0600

Seen: 320 times

Last updated: Oct 21 '17