char args[255];
AVFilterContext *filter;
- snprintf(args, sizeof(args), "%d:%d:flags=0x%X",
+ snprintf(args, sizeof(args), "%d:%d:0x%X",
codec->width,
codec->height,
(unsigned)ost->sws_flags);
OutputStream *ost = ofilter->ost;
AVCodecContext *codec = ost->st->codec;
AVFilterContext *last_filter = out->filter_ctx;
+ OutputFile *of = output_files[ost->file_index];
int pad_idx = out->pad_idx;
char *sample_fmts, *sample_rates, *channel_layouts;
char name[255];
AUTO_INSERT_FILTER("-vol", "volume", args);
}
+ if (ost->apad && of->shortest) {
+ char args[256];
+ int i;
+
+ for (i=0; i<of->ctx->nb_streams; i++)
+ if (of->ctx->streams[i]->codec->codec_type == AVMEDIA_TYPE_VIDEO)
+ break;
+
+ if (i<of->ctx->nb_streams) {
+ snprintf(args, sizeof(args), "%s", ost->apad);
+ AUTO_INSERT_FILTER("-apad", "apad", args);
+ }
+ }
+
ret = insert_trim(ost, &last_filter, &pad_idx);
if (ret < 0)
return ret;