static char *choose_pixel_fmts(OutputStream *ost)

{

    if (ost->keep_pix_fmt) {

        if (ost->filter)

            avfilter_graph_set_auto_convert(ost->filter->graph->graph,

                                            AVFILTER_AUTO_CONVERT_NONE);

        if (ost->st->codec->pix_fmt == PIX_FMT_NONE)

            return NULL;

        ost->pix_fmts[0] = ost->st->codec->pix_fmt;

        return ost->pix_fmts;

    }

    if (ost->st->codec->pix_fmt != PIX_FMT_NONE) {

        return av_strdup(av_get_pix_fmt_name(choose_pixel_fmt(ost->st, ost->enc, ost->st->codec->pix_fmt)));

    } else if (ost->enc->pix_fmts) {

        const enum PixelFormat *p;

        AVIOContext *s = NULL;

        uint8_t *ret;

        int len;



        if (avio_open_dyn_buf(&s) < 0)

            exit_program(1);



        p = ost->enc->pix_fmts;

        if (ost->st->codec->strict_std_compliance <= FF_COMPLIANCE_UNOFFICIAL) {

            if (ost->st->codec->codec_id == CODEC_ID_MJPEG) {

                p = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUV420P, PIX_FMT_YUV422P, PIX_FMT_NONE };

            } else if (ost->st->codec->codec_id == CODEC_ID_LJPEG) {

                p = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUVJ444P, PIX_FMT_YUV420P,

                                                    PIX_FMT_YUV422P, PIX_FMT_YUV444P, PIX_FMT_BGRA, PIX_FMT_NONE };

            }

        }



        for (; *p != PIX_FMT_NONE; p++)

            avio_printf(s, "%s:", av_get_pix_fmt_name(*p));

        len = avio_close_dyn_buf(s, &ret);

        ret[len - 1] = 0;

        return ret;

    } else

        return NULL;

}

static char *choose_pixel_fmts(OutputStream *ost)

{

    if (ost->keep_pix_fmt) {

        if (ost->filter)

            avfilter_graph_set_auto_convert(ost->filter->graph->graph,

                                            AVFILTER_AUTO_CONVERT_NONE);

        if (ost->st->codec->pix_fmt == PIX_FMT_NONE)

            return NULL;

        ost->pix_fmts[0] = ost->st->codec->pix_fmt;

        return ost->pix_fmts;

    }

    if (ost->st->codec->pix_fmt != PIX_FMT_NONE) {

        return av_strdup(av_get_pix_fmt_name(choose_pixel_fmt(ost->st, ost->enc, ost->st->codec->pix_fmt)));

    } else if (ost->enc->pix_fmts) {

        const enum PixelFormat *p;

        AVIOContext *s = NULL;

        uint8_t *ret;

        int len;



        if (avio_open_dyn_buf(&s) < 0)

            exit_program(1);



        p = ost->enc->pix_fmts;

        if (ost->st->codec->strict_std_compliance <= FF_COMPLIANCE_UNOFFICIAL) {

            if (ost->st->codec->codec_id == CODEC_ID_MJPEG) {

                p = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUV420P, PIX_FMT_YUV422P, PIX_FMT_NONE };

            } else if (ost->st->codec->codec_id == CODEC_ID_LJPEG) {

                p = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUVJ444P, PIX_FMT_YUV420P,

                                                    PIX_FMT_YUV422P, PIX_FMT_YUV444P, PIX_FMT_BGRA, PIX_FMT_NONE };

            }

        }



        for (; *p != PIX_FMT_NONE; p++)

            avio_printf(s, "%s:", av_get_pix_fmt_name(*p));

        len = avio_close_dyn_buf(s, &ret);

        ret[len - 1] = 0;

        return ret;

    } else

        return NULL;

}

static char *choose_pixel_fmts(OutputStream *ost)     if (ost->keep_pix_fmt) {         for (; *p != PIX_FMT_NONE; p++)             avio_printf(s, "%s:", av_get_pix_fmt_name(*p));             exit_program(1);             exit_program(1);             exit_program(1);             exit_program(1);
static char *FUNC_0(OutputStream *VAR_0)

{

    if (VAR_0->keep_pix_fmt) {

        if (VAR_0->filter)

            avfilter_graph_set_auto_convert(VAR_0->filter->graph->graph,

                                            AVFILTER_AUTO_CONVERT_NONE);

        if (VAR_0->st->codec->pix_fmt == PIX_FMT_NONE)

            return NULL;

        VAR_0->pix_fmts[0] = VAR_0->st->codec->pix_fmt;

        return VAR_0->pix_fmts;

    }

    if (VAR_0->st->codec->pix_fmt != PIX_FMT_NONE) {

        return av_strdup(av_get_pix_fmt_name(choose_pixel_fmt(VAR_0->st, VAR_0->enc, VAR_0->st->codec->pix_fmt)));

    } else if (VAR_0->enc->pix_fmts) {

        const enum PixelFormat *VAR_1;

        AVIOContext *s = NULL;

        uint8_t *ret;

        int VAR_2;



        if (avio_open_dyn_buf(&s) < 0)

            exit_program(1);



        VAR_1 = VAR_0->enc->pix_fmts;

        if (VAR_0->st->codec->strict_std_compliance <= FF_COMPLIANCE_UNOFFICIAL) {

            if (VAR_0->st->codec->codec_id == CODEC_ID_MJPEG) {

                VAR_1 = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUV420P, PIX_FMT_YUV422P, PIX_FMT_NONE };

            } else if (VAR_0->st->codec->codec_id == CODEC_ID_LJPEG) {

                VAR_1 = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUVJ444P, PIX_FMT_YUV420P,

                                                    PIX_FMT_YUV422P, PIX_FMT_YUV444P, PIX_FMT_BGRA, PIX_FMT_NONE };

            }

        }



        for (; *VAR_1 != PIX_FMT_NONE; VAR_1++)

            avio_printf(s, "%s:", av_get_pix_fmt_name(*VAR_1));

        VAR_2 = avio_close_dyn_buf(s, &ret);

        ret[VAR_2 - 1] = 0;

        return ret;

    } else

        return NULL;

}

static char *FUNC_0(OutputStream *VAR_0)
{ if (VAR_0->keep_pix_fmt) { if (VAR_0->filter)
avfilter_graph_set_auto_convert(VAR_0->filter->graph->graph,
AVFILTER_AUTO_CONVERT_NONE); if (VAR_0->st->codec->pix_fmt == PIX_FMT_NONE)
return NULL; VAR_0->pix_fmts[0] = VAR_0->st->codec->pix_fmt; return VAR_0->pix_fmts; } if (VAR_0->st->codec->pix_fmt != PIX_FMT_NONE) { return av_strdup(av_get_pix_fmt_name(choose_pixel_fmt(VAR_0->st, VAR_0->enc, VAR_0->st->codec->pix_fmt))); } else if (VAR_0->enc->pix_fmts) { const enum PixelFormat *VAR_1; AVIOContext *s = NULL; uint8_t *ret; int VAR_2; if (avio_open_dyn_buf(&s) < 0)
exit_program(1); VAR_1 = VAR_0->enc->pix_fmts; if (VAR_0->st->codec->strict_std_compliance <= FF_COMPLIANCE_UNOFFICIAL) { if (VAR_0->st->codec->codec_id == CODEC_ID_MJPEG) { VAR_1 = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUV420P, PIX_FMT_YUV422P, PIX_FMT_NONE }; } else if (VAR_0->st->codec->codec_id == CODEC_ID_LJPEG) { VAR_1 = (const enum PixelFormat[]) { PIX_FMT_YUVJ420P, PIX_FMT_YUVJ422P, PIX_FMT_YUVJ444P, PIX_FMT_YUV420P, PIX_FMT_YUV422P, PIX_FMT_YUV444P, PIX_FMT_BGRA, PIX_FMT_NONE }; } } for (; *VAR_1 != PIX_FMT_NONE; VAR_1++) avio_printf(s, "%s:", av_get_pix_fmt_name(*VAR_1)); VAR_2 = avio_close_dyn_buf(s, &ret); ret[VAR_2 - 1] = 0; return ret; } else return NULL; }