int avfilter_graph_send_command(AVFilterGraph *graph, const char *target, const char *cmd, const char *arg, char *res, int res_len, int flags)

{

    int i, r = AVERROR(ENOSYS);



    if(!graph)

        return r;



    if((flags & AVFILTER_CMD_FLAG_ONE) && !(flags & AVFILTER_CMD_FLAG_FAST)) {

        r=avfilter_graph_send_command(graph, target, cmd, arg, res, res_len, flags | AVFILTER_CMD_FLAG_FAST);

        if(r != AVERROR(ENOSYS))

            return r;

    }



    if(res_len && res)

        res[0]= 0;



    for (i = 0; i < graph->filter_count; i++) {

        AVFilterContext *filter = graph->filters[i];

        if(!strcmp(target, "all") || !strcmp(target, filter->name) || !strcmp(target, filter->filter->name)){

            r = avfilter_process_command(filter, cmd, arg, res, res_len, flags);

            if(r != AVERROR(ENOSYS)) {

                if((flags & AVFILTER_CMD_FLAG_ONE) || r<0)

                    return r;

            }

        }

    }



    return r;

}

int avfilter_graph_send_command(AVFilterGraph *graph, const char *target, const char *cmd, const char *arg, char *res, int res_len, int flags)

{

    int i, r = AVERROR(ENOSYS);



    if(!graph)

        return r;



    if((flags & AVFILTER_CMD_FLAG_ONE) && !(flags & AVFILTER_CMD_FLAG_FAST)) {

        r=avfilter_graph_send_command(graph, target, cmd, arg, res, res_len, flags | AVFILTER_CMD_FLAG_FAST);

        if(r != AVERROR(ENOSYS))

            return r;

    }



    if(res_len && res)

        res[0]= 0;



    for (i = 0; i < graph->filter_count; i++) {

        AVFilterContext *filter = graph->filters[i];

        if(!strcmp(target, "all") || !strcmp(target, filter->name) || !strcmp(target, filter->filter->name)){

            r = avfilter_process_command(filter, cmd, arg, res, res_len, flags);

            if(r != AVERROR(ENOSYS)) {

                if((flags & AVFILTER_CMD_FLAG_ONE) || r<0)

                    return r;

            }

        }

    }



    return r;

}

        if(!strcmp(target, "all") || !strcmp(target, filter->name) || !strcmp(target, filter->filter->name)){
int FUNC_0(AVFilterGraph *VAR_0, const char *VAR_1, const char *VAR_2, const char *VAR_3, char *VAR_4, int VAR_5, int VAR_6)

{

    int VAR_7, VAR_8 = AVERROR(ENOSYS);



    if(!VAR_0)

        return VAR_8;



    if((VAR_6 & AVFILTER_CMD_FLAG_ONE) && !(VAR_6 & AVFILTER_CMD_FLAG_FAST)) {

        VAR_8=FUNC_0(VAR_0, VAR_1, VAR_2, VAR_3, VAR_4, VAR_5, VAR_6 | AVFILTER_CMD_FLAG_FAST);

        if(VAR_8 != AVERROR(ENOSYS))

            return VAR_8;

    }



    if(VAR_5 && VAR_4)

        VAR_4[0]= 0;



    for (VAR_7 = 0; VAR_7 < VAR_0->filter_count; VAR_7++) {

        AVFilterContext *filter = VAR_0->filters[VAR_7];

        if(!strcmp(VAR_1, "all") || !strcmp(VAR_1, filter->name) || !strcmp(VAR_1, filter->filter->name)){

            VAR_8 = avfilter_process_command(filter, VAR_2, VAR_3, VAR_4, VAR_5, VAR_6);

            if(VAR_8 != AVERROR(ENOSYS)) {

                if((VAR_6 & AVFILTER_CMD_FLAG_ONE) || VAR_8<0)

                    return VAR_8;

            }

        }

    }



    return VAR_8;

}

int FUNC_0(AVFilterGraph *VAR_0, const char *VAR_1, const char *VAR_2, const char *VAR_3, char *VAR_4, int VAR_5, int VAR_6)
{ int VAR_7, VAR_8 = AVERROR(ENOSYS); if(!VAR_0)
return VAR_8; if((VAR_6 & AVFILTER_CMD_FLAG_ONE) && !(VAR_6 & AVFILTER_CMD_FLAG_FAST)) { VAR_8=FUNC_0(VAR_0, VAR_1, VAR_2, VAR_3, VAR_4, VAR_5, VAR_6 | AVFILTER_CMD_FLAG_FAST); if(VAR_8 != AVERROR(ENOSYS))
return VAR_8; } if(VAR_5 && VAR_4)
VAR_4[0]= 0; for (VAR_7 = 0; VAR_7 < VAR_0->filter_count; VAR_7++) { AVFilterContext *filter = VAR_0->filters[VAR_7]; if(!strcmp(VAR_1, "all") || !strcmp(VAR_1, filter->name) || !strcmp(VAR_1, filter->filter->name)){ VAR_8 = avfilter_process_command(filter, VAR_2, VAR_3, VAR_4, VAR_5, VAR_6); if(VAR_8 != AVERROR(ENOSYS)) { if((VAR_6 & AVFILTER_CMD_FLAG_ONE) || VAR_8<0)
return VAR_8; } } } return VAR_8; }