Closed Brozen closed 1 year ago
We can and should call close() on anything that implements AutoCloseable. If you still observe a "memory leak" after that, please let me know.
Also, please upgrade to JavaCV 1.5.8. There is no point in using an old version, if this is what you're trying to do.
Your code doesn't work because you're not calling recorder.start() anywhere, but I've tested with some similar code and memory usage isn't increasing, so I guess that the issue you're having has already been fixed in JavaCV 1.5.8. If you're still having issues with JavaCV 1.5.8 though, please provide a way to reproduce them! Thanks
OK, i will try 1.5.8, thanks for answering this question!
Hi, i'm using FFmpegFrameGrabber and FFmpegFrameRecorder to merge several videos, my code like this.
it did't cause any OOM, but i see memory of Java process is growing, I'm not sure if i use correct method to release FFmpegFrameRecorder\FFmpegFrameGrabber\Frame.
And i find this in FFmpegFrameGrabber#releaseUnsafe:
just set "null" to frame, and not close frame like Java2DFrameConverter#close, will this be a memory leak risk?