Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Michael Niedermayer authored on 2012/08/05 02:00:11... | ... |
@@ -1449,10 +1449,13 @@ void opt_output_file(void *optctx, const char *filename) |
1449 | 1449 |
/* video: highest resolution */ |
1450 | 1450 |
if (!o->video_disable && oc->oformat->video_codec != AV_CODEC_ID_NONE) { |
1451 | 1451 |
int area = 0, idx = -1; |
1452 |
+ int qcr = avformat_query_codec(oc->oformat, oc->oformat->video_codec, 0); |
|
1452 | 1453 |
for (i = 0; i < nb_input_streams; i++) { |
1453 | 1454 |
ist = input_streams[i]; |
1454 | 1455 |
if (ist->st->codec->codec_type == AVMEDIA_TYPE_VIDEO && |
1455 | 1456 |
ist->st->codec->width * ist->st->codec->height > area) { |
1457 |
+ if((qcr==MKTAG('A', 'P', 'I', 'C')) && !(ist->st->disposition & AV_DISPOSITION_ATTACHED_PIC)) |
|
1458 |
+ continue; |
|
1456 | 1459 |
area = ist->st->codec->width * ist->st->codec->height; |
1457 | 1460 |
idx = i; |
1458 | 1461 |
} |