History

lavc/mpegvideo_enc: allow low_delay for non MPEG2 codecs depending on strict_std_compliance

Forcing low_delay can be useful, even if not officially supported.

Stefano Sabatini committed 9 years ago

Commit dc70ea81 parent c1503cd1 file · +4 −2Browse files

Unified · Split

libavcodec/mpegvideo_enc.c+4−2
@@ -671,9 +671,11 @@ FF_ENABLE_DEPRECATION_WARNINGS · 670 unmodified lines
671671 }
672672
673673 if (s->avctx->flags & AV_CODEC_FLAG_LOW_DELAY) {
674− if (s->codec_id != AV_CODEC_ID_MPEG2VIDEO) {
674+ if (s->codec_id != AV_CODEC_ID_MPEG2VIDEO &&
675+ s->strict_std_compliance >= FF_COMPLIANCE_NORMAL) {
675676 av_log(avctx, AV_LOG_ERROR,
676− "low delay forcing is only available for mpeg2\n");
677+ "low delay forcing is only available for mpeg2, "
678+ "set strict_std_compliance to 'unofficial' or lower in order to allow it\n");
677679 return -1;
678680 }
679681 if (s->max_b_frames != 0) {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t