Quoting Janne Grunau (2016-05-08 13:28:00)
> From: Anton Mitrofanov <[email protected]>
>
> ---
> libavcodec/h264_ps.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/libavcodec/h264_ps.c b/libavcodec/h264_ps.c
> index f6cd1ca..2ca53e0 100644
> --- a/libavcodec/h264_ps.c
> +++ b/libavcodec/h264_ps.c
> @@ -530,7 +530,7 @@ int ff_h264_decode_seq_parameter_set(GetBitContext *gb,
> AVCodecContext *avctx,
>
> /* if the maximum delay is not stored in the SPS, derive it based on the
> * level */
> - if (!sps->bitstream_restriction_flag) {
> + if (!sps->bitstream_restriction_flag && sps->ref_frame_count) {
I think you can in theory create compliant intra-only files with
reordering, so to be extra safe I'd make this into
if (!sps->bitstream_restriction_flag &&
(sps->ref_frame_count || avctx->strict_std_compliance >=
FF_COMPLIANCE_STRICT)) {
Otherwise should be ok.
--
Anton Khirnov
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel