mirror of
https://git.videolan.org/git/ffmpeg.git
synced 2024-08-03 01:39:58 +02:00
h264dec: drop a redundant check
Cropping parameters are already checked for validity during SPS parsing, no need to check them again.
This commit is contained in:
parent
3cba1ad76d
commit
e7de05f98f
@ -803,23 +803,6 @@ static int init_dimensions(H264Context *h)
|
||||
height = h->avctx->height;
|
||||
}
|
||||
|
||||
if (width <= 0 || height <= 0) {
|
||||
av_log(h->avctx, AV_LOG_ERROR, "Invalid cropped dimensions: %dx%d.\n",
|
||||
width, height);
|
||||
if (h->avctx->err_recognition & AV_EF_EXPLODE)
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
||||
av_log(h->avctx, AV_LOG_WARNING, "Ignoring cropping information.\n");
|
||||
sps->crop_bottom =
|
||||
sps->crop_top =
|
||||
sps->crop_right =
|
||||
sps->crop_left =
|
||||
sps->crop = 0;
|
||||
|
||||
width = h->width;
|
||||
height = h->height;
|
||||
}
|
||||
|
||||
h->avctx->coded_width = h->width;
|
||||
h->avctx->coded_height = h->height;
|
||||
h->avctx->width = width;
|
||||
|
Loading…
Reference in New Issue
Block a user