igorcoroli / javacv

Automatically exported from code.google.com/p/javacv
GNU General Public License v2.0
0 stars 0 forks source link

Memory leak in MotionDetector.java #372

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hello to all.
I'm starting on javacv'm having problems with memory.
Sorry if the question has already been raised, but searched around and not 
found.
I am creating application to detect motion when using cvReleaseImage got the 
following error attached.

OS: XP SP3
JavaCV: javacv-0.6
OpenCV 2.4.6

Original issue reported on code.google.com by marc...@mftsoft.com.br on 10 Oct 2013 at 7:55

Attachments:

GoogleCodeExporter commented 8 years ago
What happens if you do NOT call cvReleaseImage()?

Original comment by samuel.a...@gmail.com on 13 Oct 2013 at 1:39

GoogleCodeExporter commented 8 years ago
An increase of system memory when it comes 800MB crashes.
I intend to clean every interaction, so that the system can spend hours 
monitoring.
I use the example of motion detection.

Original comment by marc...@mftsoft.com.br on 13 Oct 2013 at 12:31

GoogleCodeExporter commented 8 years ago
I don't see any calls to cvReleaseImage() in the MotionDetector.java sample 
file, so you must be talking about something else. What does your code look 
like?

Original comment by samuel.a...@gmail.com on 13 Oct 2013 at 2:48

GoogleCodeExporter commented 8 years ago
Dear Samuel,

I want to create an application to monitor my office at work using a webcam 
connected to your computer, know that there is software for this, however will 
not be as much fun to create.
The idea is inical:
1 - System monitors the room
2 - When there is movement, the system captures an image
3 - When you save the captured image in a directory

I am using the example set motion detection for this project is occurring 
almento consumption of computer memory reaching a point where the system stops 
working, then I think that is not mellho option.

Basically worked this way, but still want to do a facial recognition.

Sorry, I'm using google translate and grateful for the attention

Original comment by marc...@mftsoft.com.br on 15 Oct 2013 at 12:03

GoogleCodeExporter commented 8 years ago
Ah, I see where the memory leak was in MotionDetector.java. Here is a fixed 
version:
http://code.google.com/p/javacv/source/detail?r=284cd7acf75d55a1cd0c9dabfacbdfaf
698a3fb6
Let me know if this works well for you, and thanks for reporting!

Original comment by samuel.a...@gmail.com on 24 Oct 2013 at 12:13

GoogleCodeExporter commented 8 years ago
Fix included in JavaCV 0.7! Again, thanks for reporting

Original comment by samuel.a...@gmail.com on 7 Jan 2014 at 1:06