bytedeco/javacv

AVFormatContext call_back()?

Open

#463 geöffnet am 25. Juli 2016

Auf GitHub ansehen
 (9 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Java (1.583 Forks)batch import
help wantedquestion

Repository-Metriken

Stars
 (6.985 Stars)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

i want to stop the av_read_frame(), but i do not know how to call the call_back() to interrupt, here is my code, but it don't work...

AVFormatContext pFormatCtx = new AVFormatContext(null);

 AVIOInterruptCB avioInterruptCB = pFormatCtx.interrupt_callback();
        avioInterruptCB.callback(new AVIOInterruptCB.Callback_Pointer() {
            public int call(Pointer p) {

                 try {
                    TimeUnit.SECONDS.sleep(10);
                }catch (Exception e) {
                    logger.info("TimeUnit Exception: {}" , e);
                }
               return 1;
             }
         });

Contributor Guide