static int vda_h264_end_frame(AVCodecContext *avctx)
{
    H264Context *h                      = avctx->priv_data;
    struct vda_context *vda_ctx         = avctx->hwaccel_context;
    AVFrame *frame                      = &h->cur_pic_ptr->f;
    struct vda_buffer *context;
    AVBufferRef *buffer;
    int status;
    if (!vda_ctx->decoder || !vda_ctx->priv_bitstream)
    status = vda_sync_decode(vda_ctx);
    frame->data[3] = (void*)vda_ctx->cv_buffer;
    if (status)
        av_log(avctx, AV_LOG_ERROR, "Failed to decode frame (%d)\n", status);
static int vda_h264_end_frame(AVCodecContext *avctx)
{
    H264Context *h                      = avctx->priv_data;
    struct vda_context *vda_ctx         = avctx->hwaccel_context;
    AVFrame *frame                      = &h->cur_pic_ptr->f;
    struct vda_buffer *context;
    AVBufferRef *buffer;
    int status;
    if (!vda_ctx->decoder || !vda_ctx->priv_bitstream)
    status = vda_sync_decode(vda_ctx);
    frame->data[3] = (void*)vda_ctx->cv_buffer;
    if (status)
        av_log(avctx, AV_LOG_ERROR, "Failed to decode frame (%d)\n", status);
static int FUNC_0(AVCodecContext *VAR_0)
{
    H264Context *h                      = VAR_0->priv_data;
    struct vda_context *VAR_1         = VAR_0->hwaccel_context;
    AVFrame *frame                      = &h->cur_pic_ptr->f;
    struct vda_buffer *VAR_2;
    AVBufferRef *buffer;
    int VAR_3;
    if (!VAR_1->decoder || !VAR_1->priv_bitstream)
    VAR_3 = vda_sync_decode(VAR_1);
    frame->data[3] = (void*)VAR_1->cv_buffer;
    if (VAR_3)
        av_log(VAR_0, AV_LOG_ERROR, "Failed to decode frame (%d)\n", VAR_3);
static int FUNC_0(AVCodecContext *VAR_0)
{ H264Context *h                      = VAR_0->priv_data; struct vda_context *VAR_1         = VAR_0->hwaccel_context; AVFrame *frame                      = &h->cur_pic_ptr->f; struct vda_buffer *VAR_2; AVBufferRef *buffer; int VAR_3; if (!VAR_1->decoder || !VAR_1->priv_bitstream)
VAR_3 = vda_sync_decode(VAR_1); frame->data[3] = (void*)VAR_1->cv_buffer; if (VAR_3)
av_log(VAR_0, AV_LOG_ERROR, "Failed to decode frame (%d)\n", VAR_3);