Is there any chance to pull the previous decoded frame out before next frame in?

We’re using the parser/decoder api for a very special case. We have hundreds of very-low-frame-rate live video sources, currently 0.2 FPS. We don’t use the video source api, only parser and decoder. The parser/decoder seems only giving the decoded output of the last frame after the next frame input. This, in our case, will cause a 5 sec delay, which apparently undesirable. Is there any way to overcome this?

int CAVCDecoder::decoder_flush(void)

    pkt.flags = CUVID_PKT_ENDOFSTREAM;
    pkt.payload_size = 0;
    pkt.payload = NULL;
    pkt.timestamp = 0;  // not using timestamps
    cuvidParseVideoData(Session.cuParser, &pkt);

    // Flush display queue
    for (int i=0; i<DISPLAY_DELAY; i++)
        if (Session.DisplayQueue[Session.display_pos].picture_index >= 0)
            DisplayPicture(&Session, &Session.DisplayQueue[Session.display_pos]);
            Session.DisplayQueue[Session.display_pos].picture_index = -1;
        Session.display_pos = (Session.display_pos + 1) % DISPLAY_DELAY;

    return 0;

thanks, electrodynamics. But that doesn’t work for my scenario (The title is misleading indeed, sorry). After the CUVID_PKT_ENDOFSTREAM packet is fed, the parser will ignore all following data .