VideoHelp Forum




+ Reply to Thread
Results 1 to 22 of 22
  1. Member
    Join Date
    Jan 2006
    Location
    United Kingdom
    Search Comp PM
    I went through this old and informative thread:
    https://forum.videohelp.com/threads/407467-Vhs-capture-advice/page8#post2681667 where @Sharc are showing how to crop/pad and export the output as X264 and specific setting for SAR (Sample Aspect Ratio).

    I followed the steps shown in that thread and did some tests with clips from that thread and used the settings in VirtualDub2.

    The basic issue I see (and I mean literally) is that when setting SAR=12:11, the out is stretch compared to SAR=1:1

    E.g. SAR=1:1:
    Image
    [Attachment 89574 - Click to enlarge]


    with SAR=12:11:

    Image
    [Attachment 89575 - Click to enlarge]


    (the green padding colour was my choice to see padded areas)
    Now when played back, on a UHD TV, one cannot really tell the difference with people in the content but potentially can with objects.

    So I ran another test with a test pattern with squares and circles. Same results and the stretching is obvious:

    SAR=1:1
    Image
    [Attachment 89576 - Click to enlarge]


    SAR=12:11
    Image
    [Attachment 89577 - Click to enlarge]


    These are the settings I used:
    Image
    [Attachment 89578 - Click to enlarge]

    Image
    [Attachment 89580 - Click to enlarge]

    Image
    [Attachment 89579 - Click to enlarge]

    Image
    [Attachment 89583 - Click to enlarge]


    The clips are used are attached below

    So I am now confused as to why I would use SAR=12:11 if it produces a horizontally stretched and visually distorted output ?
    Image Attached Files
    Quote Quote  
  2. You are confusing yourself: Your Test-Pattern-04-5s.avi has a SAR of 1:1 (square pixels), so it should be encoded with SAR 1:1.
    Your clip.avi has non-square pixels with SAR 12:11. So it should be encoded with SAR 12:11 which stretches it horizontally correctly by 12/11= 1.0909..., which gives 768x576 including the padding bars. (I didn't check your Vdub settings).
    A source should always be encoded with its native SAR.

    SAR 12:11
    Image
    [Attachment 89589 - Click to enlarge]


    SAR 1:1
    Image
    [Attachment 89590 - Click to enlarge]
    Last edited by Sharc; 5th Nov 2025 at 17:58.
    Quote Quote  
  3. Member
    Join Date
    Jan 2006
    Location
    United Kingdom
    Search Comp PM
    Originally Posted by Sharc View Post
    You are confusing yourself: Your Test-Pattern-04-5s.avi has a SAR of 1:1 (square pixels), so it should be encoded with SAR 1:1.
    Your clip.avi has non-square pixels with SAR 12:11. So it should be encoded with SAR 12:11 which stretches it horizontally correctly by 12/11= 1.0909..., which gives 768x576 including the padding bars.
    A source should always be encoded with its native SAR.
    Understood but I am now more confused
    For Clip.avi, mediainfo states DAR=5:4 and a resolution of 720x576
    For Test-Pattern-04-5s.avi, mediainfo states DAR=5:4 and a resolution of 720x576

    I cannot see where SAR is defined or stored in the AVI's.
    How did you determine the SAR's for the two clips?
    Last edited by JollyDin; 5th Nov 2025 at 18:05. Reason: removed attachments
    Quote Quote  
  4. Originally Posted by JollyDin View Post
    I cannot see where SAR is defined or stored in the AVI's.
    It's not stored in the .avi. The .avi container does not provide this info.
    How did you determine the SAR's for the two clips?
    The test.avi: Watch it in square pixels, and knowing the shape of the object (circle) which displays as a circle the SAR must be 1:1.
    The clip.avi: This is a PAL tape capture with black bars left and right. From "catalog" one takes the value of 12:11 for properly captured PAL VHS tapes. For finding it out you would have to find a circle in the video and do the "circle test". How to do it has been explained in dozens of posts in this forum, just do a search for "circle test" for example. Otherwise just believe religiously that properly captured PAL VHS tapes have a SAR of 12:11.
    Last edited by Sharc; 5th Nov 2025 at 18:39.
    Quote Quote  
  5. Jolly Din:
    Avi does not carry any aspect ratio information's, except DVavi. Forget what other apps say about aspect ratio.

    Common sense: You do not need to remember any aspect ratios. Just remember that true 4/3 is in 704/576. (You have to always crop 16pixel total from left and right)

    Then using logic.

    704/576 * X = 4/3, so you get that X = 4/3 * 576/704 = 1 and 1/11 = 12/11
    (use app for calculations that shows fractions, on phone etc.)
    Quote Quote  
  6. Member
    Join Date
    May 2005
    Location
    Australia-PAL Land
    Search Comp PM
    For finding it out you would have to find a circle in the video and do the "circle test". How to do it has been explained in dozens of posts in this forum, just do a search for "circle test" for example.
    The first 3 hits on a search for "circle test" do not describe how to do it.

    I assume you are implying opening the video, find a perfect circle and the experimenting with various crops to find the values which give you as perfect circle, then working out the SAR from there. Obviously, virtually impossible if you don't have a perfect circle in your video.

    The test.avi: Watch it in square pixels
    How do you set up "square pixels"?
    Quote Quote  
  7. If you cannot find perfect circle, then you are screwed and your encoded video would blow up! Do not do that.

    What the heck is wrong with generations nowadays. Generation X humans live with a system error, setting acceptable boundaries from here to here, living like that nonstop. Using NLE and not knowing anything, we would just stretch video as pleased, so it would just "felt" right. Whatever works.
    Quote Quote  
  8. aBigMeanie aedipuss's Avatar
    Join Date
    Oct 2005
    Location
    666th portal
    Search Comp PM
    if it was shot in 4:3 pal then 720x576 in square pixels is 768/576. if it was shot in 16/9 widescreen it is in square pixels 1024/576. nothing else .
    --
    "a lot of people are better dead" - prisoner KSC2-303
    Quote Quote  
  9. Member
    Join Date
    Jan 2006
    Location
    United Kingdom
    Search Comp PM
    Originally Posted by Sharc View Post
    The test.avi: Watch it in square pixels, and knowing the shape of the object (circle) which displays as a circle the SAR must be 1:1.
    The clip.avi: This is a PAL tape capture with black bars left and right. From "catalog" one takes the value of 12:11 for properly captured PAL VHS tapes. For finding it out you would have to find a circle in the video and do the "circle test". How to do it has been explained in dozens of posts in this forum, just do a search for "circle test" for example..
    Interesting.
    The test pattern avi clip was a clip I had captured (like I capture outputs from camcorders). The clip was played on a laptop which has an S-Video output. I fed that output to the capture device (Matrox MXO2) connected on another PC and used VirtualDub to capture the clip.
    That is, the laptop was acting as a signal-generator/camcorder.
    From that, I guess the laptop was outputting video on the s-video output as square pixels ?

    Originally Posted by Sharc View Post
    Otherwise just believe religiously that properly captured PAL VHS tapes have a SAR of 12:11.
    So if I use the same camcorder and same capture device then I can religiously have faith that SAR with be 12:11 ?
    Quote Quote  
  10. aBigMeanie aedipuss's Avatar
    Join Date
    Oct 2005
    Location
    666th portal
    Search Comp PM
    s-video is never 1:1 it's pal or ntsc.
    --
    "a lot of people are better dead" - prisoner KSC2-303
    Quote Quote  
  11. Member
    Join Date
    Jan 2006
    Location
    United Kingdom
    Search Comp PM
    Originally Posted by _Al_ View Post
    Jolly Din:
    Avi does not carry any aspect ratio information's, except DVavi. Forget what other apps say about aspect ratio.

    Common sense: You do not need to remember any aspect ratios. Just remember that true 4/3 is in 704/576. (You have to always crop 16pixel total from left and right)

    Then using logic.

    704/576 * X = 4/3, so you get that X = 4/3 * 576/704 = 1 and 1/11 = 12/11
    (use app for calculations that shows fractions, on phone etc.)
    got the logic.
    There was a piece of info give by Mediainfo for the test clip:
    Bits/(Pixel*Frame) : 3.894

    For the other Clip.avi it showed:
    Bits/(Pixel*Frame) : 6.138

    Not sure if that correlates or gives a clue regarding SAR
    Quote Quote  
  12. Originally Posted by JollyDin View Post
    The clip was played on a laptop which has an S-Video output. I fed that output to the capture device (Matrox MXO2) connected on another PC and used VirtualDub to capture the clip.
    That is, the laptop was acting as a signal-generator/camcorder.
    From that, I guess the laptop was outputting video on the s-video output as square pixels ?
    Analog video (composite, s-video) is a continuous waveform and hence has no pixels -- so it has no SAR. SAR is determined by the digitization process. Analog scan lines can be digitized with as many or as few samples as you want. By convention, analog video is captured at a frequency and duration that results in 720 pixels on each scan line. The active picture in that capture is about 704 pixels (a little extra is captured in case the active picture isn't centered). NTSC video is captured as 480 scan lines, PAL video as 576 scan lines.

    The relationship between the three "aspect ratios" is:

    Code:
    DAR = FAR * SAR
    
    DAR = Display aspect ratio, the final shape of the displayed picture
    FAR = Frame Aspect Ratio, width:height in pixels
    SAR = Sample Aspect Ratio, the relative spacing between pixels horizontally:vertically
    The term SAR is used because pixels are points. They have no width or height. But the term PAR (Pixel Aspect Ratio) is often used because people think of them as little rectangles.

    So given a 704x576 4:3 PAL capture you have:
    Code:
    DAR = FAR * SAR
    4/3 = 704/576 * SAR
    (4/3) / (704/576) * SAR
    SAR = 1.09090909...
    SAR = 12/11, or 12:11
    Quote Quote  
  13. Originally Posted by JollyDin View Post
    Bits/(Pixel*Frame) : 3.894

    For the other Clip.avi it showed:
    Bits/(Pixel*Frame) : 6.138

    Not sure if that correlates or gives a clue regarding SAR
    google says:
    Code:
    BPP measures the average data applied to each pixel in a video.
    It's calculated by dividing the data rate (in kbps)
    by the product of the video's resolution (width × height) and frame rate (fps):
    BPP=Data Rate/(Resolution×Frame Rate)
    nothing to do with aspect ratio, just some density of bitrate distribution
    Quote Quote  
  14. What's there to be confused about ?
    except SAR, PAR, DAR and now FAR ..

    I vote to add JAR, TAR, and BAR to the list ..
    There is nothing wrong .. with my environment
    Quote Quote  
  15. Originally Posted by Alwyn View Post
    How do you set up "square pixels"?
    For example, open it in Vdub. Right click into the picture and set the tickmark at "1:1 pixel"

    I assume you are implying opening the video, find a perfect circle and the experimenting with various crops to find the values which give you as perfect circle,.....
    Not quite. Playing with crops does not change the shape of objects in the picture, it only changes the FAR (Frame Aspect Ratio) and DAR (Display Aspect Ratio). One has to play with resizing to change the shape of the objects. Resizing changes the SAR (aka PAR).
    You could also open it in Vdub, right click on the picture and try out which of the PAR in the list returns the shape of the objects correctly (circle=circle, no fat or slim people, etc.). Note that Vdub lists 59:54 instead of 12:11. These are virtually the same within 0.15%, depending on details how one derives the SAR (aka PAR) and rounding.

    jagabo has given the formulas in post#12. The "religious" part in there is that the 4:3 picture has a width of ~704. It is justified by the standard (Rec.601) sampling rate for ananlog video (13.5MHz) and the scanline duration.
    Last edited by Sharc; 6th Nov 2025 at 03:09. Reason: clarifications added
    Quote Quote  
  16. Originally Posted by JollyDin View Post
    So if I use the same camcorder and same capture device then I can religiously have faith that SAR with be 12:11 ?
    Yes for 4:3 PAL, provided your equipment is not flawed or any of your steps does not introduce some silent resizing (rescaling) under the hood.
    Last edited by Sharc; 6th Nov 2025 at 03:02.
    Quote Quote  
  17. @JollyDin: FWIW here some files you may want to practice with. These were prepared for the NTSC case (480 picture hight) but basically address the same subject.
    https://forum.videohelp.com/threads/406656-4-3-DVDs-with-Different-DARs/page2#post2665540
    Last edited by Sharc; 6th Nov 2025 at 03:31. Reason: typo
    Quote Quote  
  18. Member
    Join Date
    May 2005
    Location
    Australia-PAL Land
    Search Comp PM
    Originally Posted by Sharc
    Playing with crops does not change the shape of objects in the picture, it only changes the FAR (Frame Aspect Ratio) and DAR (Display Aspect Ratio). One has to play with resizing to change the shape of the objects. Resizing changes the SAR (aka PAR).
    Yes, sorry, I meant after cropping to resize to standard 4:3 ie 768x576, thereby bypassing the SAR stuff.

    And if you want to export at 1440x1080, as Dellsam suggests, all this SAR and PAR stuff is irrelevant, isn't it?
    Quote Quote  
  19. Originally Posted by Alwyn View Post
    And if you want to export at 1440x1080, as Dellsam suggests, all this SAR and PAR stuff is irrelevant, isn't it?
    It is always relevant. What is the 768x576 FAR for square pixels based on? It is based on the SAR of 12:11 and the 4:3 picture represented by the "inner" 704x576 of a PAL 720x576 capture.
    If you just ignore it your intended resizing to square pixels may be off by 2.3%, and so is the upscaled 1440x1080 possibly affected by the 2.3% error.
    Revisit the recent DV discussion. If your 720x576 DV has a SAR of 16:15 you resize correctly to 768x576 or 1440x1080, without any cropping. If the 720x576 source has a SAR of 12:11 (like VHS PAL captures acc. Rec.601) you need to crop it to 704x576 (irrespective of any black side bars) and resize it to square pixels as 768x576, or 1440x1080. Without cropping you would have to resize it to 786x576 (1.36 DAR) or 1470x1080 for preserving the objects shape. If your player squashes the 1470x1080 into a 4:3 (1.333...) frame of 1440x1080 you end up with the ~2% error (squashed).

    A lot of noise about ~2%

    But more important if one totally ignores it (playing the anamorphic PAL capture as stored, means without the player stretching it by the SAR or without you correctly resizing it to square pixels) the error is annoying ~9% (12/11=1.0909...).

    Bottom line: The SAR (aka PAR) is always relevant. Either as instruction to the player how to stretch the video for playback, or for you how to resize it correctly to square pixels.
    Last edited by Sharc; 6th Nov 2025 at 08:15. Reason: clarifications (hopefully) added
    Quote Quote  
  20. Originally Posted by Sharc View Post
    Originally Posted by JollyDin View Post
    So if I use the same camcorder and same capture device then I can religiously have faith that SAR with be 12:11 ?
    Yes for 4:3 PAL, provided your equipment is not flawed or any of your steps does not introduce some silent resizing (rescaling) under the hood.
    In his first post the VirtualDub video filter dialog image shows he resized the video, changing the SAR.
    Quote Quote  
  21. Originally Posted by jagabo View Post
    Originally Posted by Sharc View Post
    Originally Posted by JollyDin View Post
    So if I use the same camcorder and same capture device then I can religiously have faith that SAR with be 12:11 ?
    Yes for 4:3 PAL, provided your equipment is not flawed or any of your steps does not introduce some silent resizing (rescaling) under the hood.
    In his first post the VirtualDub video filter dialog image shows he resized the video, changing the SAR.
    Hmmm... as I understand it his last filter did not resize the video. It is only used to pad the cropped video (Clip.avi) back to 704x576, so the SAR didn't get changed, no?
    Last edited by Sharc; 6th Nov 2025 at 10:39.
    Quote Quote  
  22. Originally Posted by Sharc View Post
    as I understand it his last filter did not resize the video. It is only used to pad the cropped video (Clip.avi) back to 704x576, so the SAR didn't get changed, no?
    You may be right. I was looking at the filter list dialog where it only shows a resize. But I see a later image shows the resize dialog and it's set to letterbox/crop -- which would not change the SAR.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!