Ask Your Question
0

Object detection on ipcamera is delayed as compared to webcam why ?

asked 2015-02-05 03:43:30 -0500

sid gravatar image

updated 2015-02-06 05:27:17 -0500

I have done facial detection and TLD(using OpenTLD) on opencv 2.4 C++ . To alter the code to stream ipcamera i did this.

VideoCapture captureDevice; string videoStreamAddress = "http://admin:admin@192.168.0.251:80/video/mjpg.cgi?&.mjpg"; captureDevice.open(videoStreamAddress); //in main loop captureDevice>>frame; //in main loop

It feels like it waits for each frame to process unlike webcam which maybe dropping frames . i have done ipcamera opencv video stream (without object detection code) using wired ethernet and its quite realtime like webcam , but when i run object detection on it , it delays much more than webcam .Video resolution of both are same.

please help.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2015-02-09 10:25:23 -0500

sid gravatar image

Finally solved the problem by my own .

using a 3 iteration loop in my main loop:

for(int i=0; i<2; i++) { captureDevice>>frame; } This lowered the frame rates to 14fps , but with no delays( caused due to buffering ), Other approach i found is to create seperate thread for capturing frames and processing it .

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2015-02-05 03:43:30 -0500

Seen: 495 times

Last updated: Feb 09 '15