lavc/encode: pick a sane default for bits_per_raw_sample if it's not set

Fixes #9563.
release/5.1
Anton Khirnov 3 years ago
parent ee26138e67
commit e663030267
  1. 3
      libavcodec/encode.c

@ -555,6 +555,9 @@ FF_DISABLE_DEPRECATION_WARNINGS
FF_ENABLE_DEPRECATION_WARNINGS
#endif
if (!avctx->bits_per_raw_sample)
avctx->bits_per_raw_sample = 8 * av_get_bytes_per_sample(avctx->sample_fmt);
return 0;
}

Loading…
Cancel
Save