In this case, no encoder specific options are filtered, only
options specific to that codec type in general.
Signed-off-by: Martin Storsjö <martin@martin.st>
... | ... |
@@ -1462,10 +1462,8 @@ AVDictionary *filter_codec_opts(AVDictionary *opts, enum AVCodecID codec_id, |
1462 | 1462 |
if (!codec) |
1463 | 1463 |
codec = s->oformat ? avcodec_find_encoder(codec_id) |
1464 | 1464 |
: avcodec_find_decoder(codec_id); |
1465 |
- if (!codec) |
|
1466 |
- return NULL; |
|
1467 | 1465 |
|
1468 |
- switch (codec->type) { |
|
1466 |
+ switch (st->codec->codec_type) { |
|
1469 | 1467 |
case AVMEDIA_TYPE_VIDEO: |
1470 | 1468 |
prefix = 'v'; |
1471 | 1469 |
flags |= AV_OPT_FLAG_VIDEO_PARAM; |