[FFmpeg-devel] [PATCH 2/2] doc/faq: explain DAR/SAR preserving.

Michael Niedermayer michaelni at gmx.at
Mon Feb 9 17:32:25 CET 2015


On Mon, Feb 09, 2015 at 04:32:11PM +0100, Nicolas George wrote:
> Signed-off-by: Nicolas George <george at nsup.org>
> ---
>  doc/faq.texi | 23 +++++++++++++++++++++++
>  1 file changed, 23 insertions(+)
> 
> diff --git a/doc/faq.texi b/doc/faq.texi
> index 494da86..68e8a17 100644
> --- a/doc/faq.texi
> +++ b/doc/faq.texi
> @@ -467,6 +467,29 @@ point acceptable for your tastes. The most common options to do that are
>  @option{-qscale} and @option{-qmax}, but you should peruse the documentation
>  of the encoder you chose.
>  
> + at section I have a stretched video, why does scaling does not fix it?

i think theres a "does" too much


> +
> +A lot of video codecs and formats can store the @emph{aspect ratio} of the
> +video: this is the ratio between the width and the height of either the full
> +image (DAR, display aspect ratio) or individual pixels (SAR, sample aspect
> +ratio). For example, CGA screens at resolution 640×350 had 4:3 DAR and 35:48
> +SAR.
> +
> +Most still image processing work with square pixels, i.e. 1:1 SAR, but a lot
> +of video standards, especially from the analogic-numeric transition era, use
> +non-square pixels.
> +
> +Most processing filters in FFmpeg handle the aspect ratio to avoid
> +stretching the image: cropping adjusts the DAR to keep the SAR constant,
> +scaling adjusts the SAR to keep the DAR constant.
> +
> +If you want to stretch, or “unstretch”, the image, you need to override the
> +information with the
> + at url{http://ffmpeg.org/ffmpeg-filters.html#setdar_002c-setsar, @code{setdar or setsar filters}}.
> +

> +Do not forget to examine carefully the original video to check whether the
> +stretching comes from the image or from the aspect ratio information.

it might make sense to provide examples of how to correct either

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

I have often repented speaking, but never of holding my tongue.
-- Xenocrates
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150209/053096a9/attachment.asc>


More information about the ffmpeg-devel mailing list