Lines Matching defs:ret

419     int ret;
428 ret = av_fifo_write(q->pkt_list, &pkt1, 1);
429 if (ret < 0)
430 return ret;
442 int ret;
452 ret = packet_queue_put_private(q, pkt1);
455 if (ret < 0)
458 return ret;
533 int ret;
539 ret = -1;
551 ret = 1;
554 ret = 0;
561 return ret;
578 int ret = AVERROR(EAGAIN);
588 ret = avcodec_receive_frame(d->avctx, frame);
589 if (ret >= 0) {
598 ret = avcodec_receive_frame(d->avctx, frame);
599 if (ret >= 0) {
612 if (ret == AVERROR_EOF) {
617 if (ret >= 0)
619 } while (ret != AVERROR(EAGAIN));
645 ret = avcodec_decode_subtitle2(d->avctx, sub, &got_frame, d->pkt);
646 if (ret < 0) {
647 ret = AVERROR(EAGAIN);
652 ret = got_frame ? 0 : (d->pkt->data ? AVERROR(EAGAIN) : AVERROR_EOF);
895 int ret = 0;
917 ret = -1;
922 ret = SDL_UpdateYUVTexture(*tex, NULL, frame->data[0], frame->linesize[0],
926 ret = SDL_UpdateYUVTexture(*tex, NULL, frame->data[0] + frame->linesize[0] * (frame->height - 1), -frame->linesize[0],
936 ret = SDL_UpdateTexture(*tex, NULL, frame->data[0] + frame->linesize[0] * (frame->height - 1), -frame->linesize[0]);
938 ret = SDL_UpdateTexture(*tex, NULL, frame->data[0], frame->linesize[0]);
942 return ret;
1800 int ret, i;
1808 ret = AVERROR(ENOMEM);
1822 if ((ret = avfilter_graph_parse_ptr(graph, filtergraph, &inputs, &outputs, NULL)) < 0)
1825 if ((ret = avfilter_link(source_ctx, 0, sink_ctx, 0)) < 0)
1833 ret = avfilter_graph_config(graph, NULL);
1837 return ret;
1845 int ret;
1882 if ((ret = avfilter_graph_create_filter(&filt_src,
1888 ret = avfilter_graph_create_filter(&filt_out,
1891 if (ret < 0)
1894 if ((ret = av_opt_set_int_list(filt_out, "pix_fmts", pix_fmts, AV_PIX_FMT_NONE, AV_OPT_SEARCH_CHILDREN)) < 0)
1904 ret = avfilter_graph_create_filter(&filt_ctx, \
1907 if (ret < 0) \
1910 ret = avfilter_link(filt_ctx, 0, last_filter, 0); \
1911 if (ret < 0) \
1935 if ((ret = configure_filtergraph(graph, vfilters, filt_src, last_filter)) < 0)
1942 return ret;
1954 int ret;
1971 ret = snprintf(asrc_args, sizeof(asrc_args),
1976 ret = avfilter_graph_create_filter(&filt_asrc,
1979 if (ret < 0)
1983 ret = avfilter_graph_create_filter(&filt_asink,
1986 if (ret < 0)
1989 if ((ret = av_opt_set_int_list(filt_asink, "sample_fmts", sample_fmts, AV_SAMPLE_FMT_NONE, AV_OPT_SEARCH_CHILDREN)) < 0)
1991 if ((ret = av_opt_set_int(filt_asink, "all_channel_counts", 1, AV_OPT_SEARCH_CHILDREN)) < 0)
1996 if ((ret = av_opt_set_int(filt_asink, "all_channel_counts", 0, AV_OPT_SEARCH_CHILDREN)) < 0)
1998 if ((ret = av_opt_set(filt_asink, "ch_layouts", bp.str, AV_OPT_SEARCH_CHILDREN)) < 0)
2000 if ((ret = av_opt_set_int_list(filt_asink, "sample_rates" , sample_rates , -1, AV_OPT_SEARCH_CHILDREN)) < 0)
2005 if ((ret = configure_filtergraph(is->agraph, afilters, filt_asrc, filt_asink)) < 0)
2012 if (ret < 0)
2016 return ret;
2031 int ret = 0;
2061 ret = av_channel_layout_copy(&is->audio_filter_src.ch_layout, &frame->ch_layout);
2062 if (ret < 0)
2067 if ((ret = configure_audio_filters(is, afilters, 1)) < 0)
2071 if ((ret = av_buffersrc_add_frame(is->in_audio_filter, frame)) < 0)
2074 while ((ret = av_buffersink_get_frame_flags(is->out_audio_filter, frame, 0)) >= 0) {
2092 if (ret == AVERROR_EOF)
2096 } while (ret >= 0 || ret == AVERROR(EAGAIN) || ret == AVERROR_EOF);
2102 return ret;
2122 int ret;
2140 ret = get_video_frame(is, frame);
2141 if (ret < 0)
2143 if (!ret)
2161 ret = AVERROR(ENOMEM);
2165 if ((ret = configure_video_filters(graph, is, vfilters_list ? vfilters_list[is->vfilter_idx] : NULL, frame)) < 0) {
2182 ret = av_buffersrc_add_frame(filt_in, frame);
2183 if (ret < 0)
2186 while (ret >= 0) {
2189 ret = av_buffersink_get_frame_flags(filt_out, frame, 0);
2190 if (ret < 0) {
2191 if (ret == AVERROR_EOF)
2193 ret = 0;
2204 ret = queue_picture(is, frame, pts, duration, frame->pkt_pos, is->viddec.pkt_serial);
2212 if (ret < 0)
2565 int ret = 0;
2575 ret = avcodec_parameters_to_context(avctx, ic->streams[stream_index]->codecpar);
2576 if (ret < 0)
2594 ret = AVERROR(EINVAL);
2614 if ((ret = avcodec_open2(avctx, codec, &opts)) < 0) {
2619 ret = AVERROR_OPTION_NOT_FOUND;
2632 ret = av_channel_layout_copy(&is->audio_filter_src.ch_layout, &avctx->ch_layout);
2633 if (ret < 0)
2636 if ((ret = configure_audio_filters(is, afilters, 0)) < 0)
2640 ret = av_buffersink_get_ch_layout(sink, &ch_layout);
2641 if (ret < 0)
2646 ret = av_channel_layout_copy(&ch_layout, &avctx->ch_layout);
2647 if (ret < 0)
2652 if ((ret = audio_open(is, &ch_layout, sample_rate, &is->audio_tgt)) < 0)
2654 is->audio_hw_buf_size = ret;
2669 if ((ret = decoder_init(&is->auddec, avctx, &is->audioq, is->continue_read_thread)) < 0)
2675 if ((ret = decoder_start(&is->auddec, audio_thread, "audio_decoder", is)) < 0)
2683 if ((ret = decoder_init(&is->viddec, avctx, &is->videoq, is->continue_read_thread)) < 0)
2685 if ((ret = decoder_start(&is->viddec, video_thread, "video_decoder", is)) < 0)
2693 if ((ret = decoder_init(&is->subdec, avctx, &is->subtitleq, is->continue_read_thread)) < 0)
2695 if ((ret = decoder_start(&is->subdec, subtitle_thread, "subtitle_decoder", is)) < 0)
2709 return ret;
2746 int err, i, ret;
2758 ret = AVERROR(ENOMEM);
2768 ret = AVERROR(ENOMEM);
2774 ret = AVERROR(ENOMEM);
2786 ret = -1;
2794 ret = AVERROR_OPTION_NOT_FOUND;
2817 ret = -1;
2843 ret = avformat_seek_file(ic, -1, INT64_MIN, timestamp, INT64_MAX, 0);
2844 if (ret < 0) {
2903 ret = -1;
2905 ret = stream_component_open(is, st_index[AVMEDIA_TYPE_VIDEO]);
2908 is->show_mode = ret >= 0 ? SHOW_MODE_VIDEO : SHOW_MODE_RDFT;
2917 ret = -1;
2951 ret = avformat_seek_file(is->ic, -1, seek_min, seek_target, seek_max, is->seek_flags);
2952 if (ret < 0) {
2976 if ((ret = av_packet_ref(pkt, &is->video_st->attached_pic)) < 0)
3002 ret = AVERROR_EOF;
3006 ret = av_read_frame(ic, pkt);
3007 if (ret < 0) {
3008 if ((ret == AVERROR_EOF || avio_feof(ic->pb)) && !is->eof) {
3050 ret = 0;
3056 if (ret != 0) {