diff options
author | Linjie Fu <linjie.fu@intel.com> | 2020-04-29 11:00:49 +0800 |
---|---|---|
committer | Martin Storsjö <martin@martin.st> | 2020-04-29 20:58:17 +0300 |
commit | 9310361252c88bcab74a7ccbe2c910c7a1a37397 (patch) | |
tree | e87d771fe4b5c5e7f5678c4ffdc1107572998304 | |
parent | 75fc3f97b0073d0ff57b4bd1e5ce8b36a5f9ac14 (diff) | |
download | ffmpeg-9310361252c88bcab74a7ccbe2c910c7a1a37397.tar.gz |
lavc/libopenh264enc: prompt slice number changing inside libopenh264
Libopenh264enc would set the slice according to the number of cpu cores
if uiSliceNum equals to 0 (auto) in SM_FIXEDSLCNUM_SLICE mode.
Prompt a warning for user to catch this.
Signed-off-by: Linjie Fu <linjie.fu@intel.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
-rw-r--r-- | libavcodec/libopenh264enc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/libopenh264enc.c b/libavcodec/libopenh264enc.c index dc3bd536a8..29269f9513 100644 --- a/libavcodec/libopenh264enc.c +++ b/libavcodec/libopenh264enc.c @@ -244,6 +244,8 @@ FF_ENABLE_DEPRECATION_WARNINGS param.sSpatialLayers[0].sSliceCfg.uiSliceMode = s->slice_mode; param.sSpatialLayers[0].sSliceCfg.sSliceArgument.uiSliceNum = avctx->slices; #endif + if (avctx->slices == 0 && s->slice_mode == SM_FIXEDSLCNUM_SLICE) + av_log(avctx, AV_LOG_WARNING, "Slice count will be set automatically\n"); if (s->slice_mode == SM_SIZELIMITED_SLICE) { if (s->max_nal_size) { |