[FFmpeg-devel] [PATCH 4/7] Ensure that the video dimension are a multiple of 16 in the 4xm decoder.
Michael Niedermayer
michaelni at gmx.at
Sun Oct 2 03:03:39 CEST 2011
On Sun, Oct 02, 2011 at 12:38:29AM +0200, fenrir at elivagar.org wrote:
> From: Laurent Aimar <fenrir at videolan.org>
>
> ---
> libavcodec/4xm.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/libavcodec/4xm.c b/libavcodec/4xm.c
> index 6335879..6ee9b34 100644
> --- a/libavcodec/4xm.c
> +++ b/libavcodec/4xm.c
> @@ -866,6 +866,8 @@ static av_cold int decode_init(AVCodecContext *avctx){
> return 1;
> }
>
> + avctx->width = FFALIGN(avctx->width, 16);
> + avctx->height = FFALIGN(avctx->height, 16);
> avcodec_get_frame_defaults(&f->current_picture);
This doesnt look correct.
If width/height must be a multiple of 16 then the decoder should fail
if its not so. Otherwise it should support it and not return a bigger
picture
also see avcodec_align_dimensions2()
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Incandescent light bulbs waste a lot of energy as heat so the EU forbids them.
Their replacement, compact fluorescent lamps, much more expensive, dont fit in
many old lamps, flicker, contain toxic mercury, produce a fraction of the light
that is claimed and in a unnatural spectrum rendering colors different than
in natural light. Ah and we now need to turn the heaters up more in winter to
compensate the lower wasted heat. Who wins? Not the environment, thats for sure
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20111002/b68b3e4b/attachment.asc>
More information about the ffmpeg-devel
mailing list