bytedeco/javacv

JVM crash error

Aperta

#2070 aperta il 24 lug 2023

 (6 commenti) (0 reazioni) (0 assegnatari)Java (1583 fork)batch import
help wantedquestion

Metriche repository

Star
 (6985 stelle)
Metriche merge PR
 (Metriche PR in attesa)

Descrizione

Pseudocode

public class Demo {
   private final static OpenCVFrameConverter.ToMat converter = new OpenCVFrameConverter.ToMat();
    public static void main(String[] args) throws Exception {
                      FFmpegFrameGrabber grabber = new FFmpegFrameGrabber("test.mp4")
                      grabber.start();
                      Frame img = null;
                      while((img = grabber.grabImage()) !=null ) {
                          Mat mat = converter.convert(img);
                          //todo do something
                      }
     }
}

description

It worked very well at first, and I would repeat this logic over and over again, and immediately after a while, the JVM crashed, and here is the screenshot

screenshots

Guida contributor