forked from PatternConsulting/opencv
-
-
Notifications
You must be signed in to change notification settings - Fork 100
Open
Description
While I was looping through frames of VideoCapture I executed this method to show frames on JavaFX image view:
private Image mat2Image(Mat frame) {
MatOfByte buffer = new MatOfByte();
Imgcodecs.imencode(".png", frame, buffer);
return new Image(new ByteArrayInputStream(buffer.toArray()));
}
for some reason it caused memory leak very rapidly like 5mb/s. After that I switch to opencv library from their official website and same code worked fine without any leaks.
Metadata
Metadata
Assignees
Labels
No labels