[FFmpeg-devel] [PATCH] libswscale/swscale.c: Clarify what exactly 'data is not aligned' to

Franziska Thul franziskavon1999 at gmx.de
Sun Dec 27 10:36:13 EET 2020


Michael Niedermayer wrote:

> > libswscale/swscale.c emits a Warning that 'data is not aligned', but doesn't explain
> > why, leaving users without any clue on how to address this issue.
> > This patch simply adds that data is not aligned 'to 16 pixel boundaries'.

> all the alignment is by byte not by pixel

Well, another point clarified :) I based my assumption of pixel alignment on try-and-error
with ffmpeg's parameters, and while scaling an image the user is, of course, dealing with
pixels, not bytes.
Not sure if mentioning bytes in that warning might cause more confusion than it helps. If
"bytes" or "pixels" doesn't matter from the user's perspective, I'd stick with the latter,
even if it's not exactly right regarding the internal workings of ffmpeg.

In any case, the 16 is important.

Thanks, Franziska



More information about the ffmpeg-devel mailing list