[FFmpeg-devel] [PATCH] VP56: 32-byte align picture width
Aurelien Jacobs
aurel
Sun Jul 13 15:44:42 CEST 2008
On Sun, 13 Jul 2008 14:13:39 +0100
Mans Rullgard <mans at mansr.com> wrote:
> The VP5/6 decoder calls put_pixels16() on the chroma planes, so these
> need 16-byte alignment. Setting luma alignment to 32 achieves this,
> although alignment of 16 is sufficient for the luma plane.
> ---
> libavcodec/utils.c | 7 ++++++-
> 1 files changed, 6 insertions(+), 1 deletions(-)
>
> diff --git a/libavcodec/utils.c b/libavcodec/utils.c
> index 5d9ee33..819548c 100644
> --- a/libavcodec/utils.c
> +++ b/libavcodec/utils.c
> @@ -127,7 +127,12 @@ void avcodec_align_dimensions(AVCodecContext *s, int *width, int *height){
> case PIX_FMT_YUVJ422P:
> case PIX_FMT_YUVJ444P:
> case PIX_FMT_YUVA420P:
> - w_align= 16; //FIXME check for non mpeg style codecs and use less alignment
> + //FIXME check for non mpeg style codecs and use less alignment
> + if (s->codec_id == CODEC_ID_VP5 || s->codec_id == CODEC_ID_VP6 ||
> + s->codec_id == CODEC_ID_VP6F)
You could also add VP6A here.
Except that, this looks a bit ugly, but I have no better idea.
Aurel
More information about the ffmpeg-devel
mailing list