[FFmpeg-user] sntsc

Mark Filipak markfilipak.imdb at gmail.com
Wed Dec 27 00:53:35 EET 2023


On 12/26/23 15:30, Devin Heitmueller wrote:
> Hi Mark,
> 
> On Tue, Dec 26, 2023 at 2:58 PM Mark Filipak <markfilipak.imdb at gmail.com> wrote:
>> Oops. Sorry. SAR for 16:9 DVD is 32/27. PAR is 3/2.
>>
>> You brought up 40/33. That's a PAR? A PAR for what?
> 
> In this context SAR (Sample Aspect Ratio) and PAR (Pixel Aspect Ratio)
> are equivalent.

On what planet are SAR & PAR equivalent?

> Unfortunately the use of the term "SAR" is ambiguous
> as people sometimes mean "Storage Aspect Ratio" or "Screen Aspect
> Ratio".  Using PAR avoids that ambiguity.

Yes, people misuse terms, mainly because the terms are not defined. The H.262 definitions have no 
relevance in the real world.

"3.114 sample aspect ratio (SAR): This specifies the relative distance between samples. It is 
defined (for the purposes of ITU-T Rec. H.262 | ISO/IEC 13818-2), as the vertical displacement of 
the lines of luminance samples in a frame divided by the horizontal displacement of the luminance 
samples. Thus, its units are (metres per line) ÷ (metres per sample)."

That definition applies solely to flying-spot scanners -- note that it is vertical (line-to-line) 
spacing divided by horizontal (pixel-to-pixel) spacing. To everyone else, H/W is upside down.
H.262 then goes on to define a DAR that's upside down:

"3.44 display aspect ratio: The ratio height/width (in spatial measurement units such as 
centimeters) of the intended display."

H.262 avoids "PAR" and "pixel aspect" altogether. There's not a mention. That was intentional. So, 
to the ITU (and presumably to MPEG), PAR doesn't exist. Some call it 'pixel aspect' and some call it 
'picture aspect'. Curiously, the ITU (and presumably to MPEG) define a 'picture', thusly:

"3.97 picture: Source, coded or reconstructed image data. A source or reconstructed picture consists 
of three rectangular matrices of 8-bit numbers representing the luminance and two chrominance 
signals. A 'coded picture' is defined in 3.21 of ITU-T Rec. H.262 | ISO/IEC 13818-2. For progressive 
video, a picture is identical to a frame, while for interlaced video, a picture can refer to a 
frame, or the top field or the bottom field of the frame depending on the context."

So, to the ITU (and presumably to MPEG) data is a picture. Good grief...

> I would encourage you to review the following page, which has an
> entire section on non-square pixels, as well as common values for NTSC
> (which talks about the 10:11 and 40:33 commonly found with encoded
> NTSC video):

704x480 is illegal for DVD. It either gets padded out to 720x480, or cropped to 704x469, then scaled 
to 720x480, or some combination of the two methods. But 704x420 is not legal for DVDs -- there's no 
such aspect choice in PES headers.

> https://en.wikipedia.org/wiki/Pixel_aspect_ratio#Pixel_aspect_ratios_of_common_video_formats

Oh, no! Mister Billipedia!  Hahahaha... (where people who are as ill informed as you are, get to 
pontificate)

>> And my original question: What is "sntsc"?
>>
>> ‘ntsc’   720x480
>> ‘pal’    720x576
>> ‘sntsc’  640x480
>> ‘spal’   768x576
> 
> While I wouldn't have gone with the nomenclature that ffmpeg uses, it
> would appear the intent was for "ntsc" to be 720x480 with a DAR of 4:3
> (therefore the PAR is 11:10), and "sntsc" to be 640x480 with a DAR of
> 4:3 (therefore the PAR is 1:1).
> 
>> What ffmpeg is calling 'ntsc' & 'pal' are from film scanners targeting pseudo-NTSC DVDs and
>> pseudo-PAL DVDs.
>>
>> What ffmpeg is calling 'sntsc' & 'spal' don't have any relationship to NTSC and PAL, neither film
>> nor broadcast, or to DVDs.
>>
>> Why ffmpeg has put the letters 'ntsc' and 'pal' into 640x480 and 768x576 is a total mystery to me
>> and continues the confusion many people have.
>>
>> I'm sorry I brought it up. It was the marketing people who labeled DVDs as 'NTSC' or 'PAL'. FFmpeg
>> is just propagating that myth. I simply ran across 'sntsc' and asked myself, "What is that?"
> 
> Frankly, I think the shortcuts were well-intentioned, but not very
> well thought out.  If you know what you are doing I would discourage
> you from trying to use them and simply specify the real resolution and
> framerate using the fps filter and/or the scale filter as needed.

Indeed. '-s 1920x1080' etc. ...It's more readable. :-)
(And note, it's W/H, the inverse of how the ITU (and presumably MPEG) defines things.)

I'm done. ...Gee, I thought it was such a simple question: "What's 'sntsc'?"



More information about the ffmpeg-user mailing list