[Cin] SD 16:9 missing among CinGG BD-Render Video Formats

Andrea paz gamberucci.andrea at gmail.com
Tue Jan 16 17:53:48 CET 2024


> I just installed the latest cin-x86_64 AppImage, started as root, loaded a HDV clip to test to create a BD iso/structure, without Blu-ray device connected (similar like testing create DVD).
> But I got the following error message; any idea what is wrong here?
>
>
> I think BD-Render currently is locked to AVCHD (h264) video and ac3 audio only.

The same mistake I had. To do a BD/DVD render we need to run CinGG
with root permissions.

@Terje
Thanks for the corrections. I put the new version of the text for the
manual (the third part). Can you check this as well? Plus I would like
to ask you if you could add a "Use Case" for BDs, since I have no
knowledge of it....
-------------- next part --------------

New paper for appendix:

DV, anamorphosis and non-square pixels

For a detailed discussion see: https://lurkertech.com/lg/pixelaspect/
To understand how \CGG{} treats anamorphic formats, with several useful examples, see Raffaella Traniello: http://www.g-raffa.eu/Cinelerra/HOWTO/anamorphic.html

Underlying the concept of anamorphic video is the following formula:

PAR = DAR / SAR

If PAR = 1 (square pixels) then SAR = DAR. With PAR different from 1, we have DAR different from SAR with distorted (anamorphic) video. We have the following definitions:

DAR= Display Aspect Ratio. It is a "frame" aspect ratio.
PAR= Pixel Aspect Ratio: horizontal pixel size : vertical pixel size; 1 or 1:1 is
square. It is a "pixel" aspect ratio.
SAR= Sample Aspect Ratio. It is the initial aspect ratio of the input, for example of the source media file. It is a "frame" aspect ratio.

Monitors and modern HD+ TVs have square pixels. Since most formats, sensors, digital video signals and displays have square pixels, then the reproduction will always be correct.
Older NTSC and PAL TVs have rectangular pixels. If we watch a video signal with rectangular (anamorphic) pixels on a monitor (which has square pixels) the frame is distorted. If we view the same signal on an older NTSC/PAL type TV the frame comes out correct.

PAR, being the ratio of single pixel sizes, is 1 (or 1:1) for square pixels while it is different from 1 for rectangular pixels. We have the following values (from Wikipedia: https://en.wikipedia.org/wiki/Pixel_aspect_ratio#Pixel_aspect_ratios_of_common_video_formats):

 [Table from Wikipedia] https://en.wikipedia.org/wiki/Pixel_aspect_ratio#Pixel_aspect_ratios_of_common_video_formats

So to display NTSC/PAL anamorphic pixels correctly on a monitor we have to make corrections via PAR. In \CGG{} we use W/H Ratio to make these corrections. Let's see the worflow:

From NTSC anamorphic 480i (720x486) to 480i std:

720 x 486 --> scale horizontally by 10/11 --> 654 x 486 --> crop to 640 --> 640 x 486 (square)
Scaling is set by W Ratio = 10 and H Ratio = 11 or as W Ratio = 10/11 = 0.909
In this way the DAR remains the same (4:3) but to have a correct display we changed the PAR. The pad/crop step may be necessary if we have to use other values of PAR, which may happen because of variability due to various video signals, various sensors, and various formats that can be used.

From PAL anamorphic 576i (720 x 576) to 576i std:

720 x 576 --> scale horizontally by 59/54 --> 786 x 576 --> crop to 768 --> 768 x 576


From NTSC square to NTSC anamorphic:

640 x 486 -->  scale horizontally by 11/10 --> 704 x 486 --> pad to 720 --> 720 x 720x486

From PAL square to PAL anamorphic:

768 x 576 -->  scale horizontally by 54/59 --> 702 x 576 --> pad to 720 --> 720 x 576

New project and Set Format windows have different presets for new projects or for changing one in use. These take into account square or non-square pixels.

Use case: Down-convert/scale between two standard 16:9 anamorphic video formats. HDV 1080i to DV 16:9, preset PAL 576i (16:9) -DV(D).

Source: HDV (mpegts) 1440x1080 SAR=4:3; DAR=16:9. The format is anamorphic with rectangular pixels stretched horizontally. PAR is calculated with: PAR = DAR / SAR = 1.7778 / 1.3333 = 1.3334 (= 4:3)

Step 1: We change the project from the initial one (of the source) to the preset "PAL 576i (16:9) -DV(D)".
Now we have:
720x576; W Ratio=0.5000; H Ratio=0.5333; DAR 16:9; the video is cropped.

Step2: Render with dv_pal.avi preset.
Now we have:
720x576; SAR = 64:45 (=1.4222); DAR = 16:9.
The difference in SAR, and consequently also in PAR, can be explained by taking into account that when Heigth=576 px, the width needs to be displayed horizontal (unsqeezed) with Wd=576x16/9=1024 px (square).
But the width needs to be stored (compressed, squeezed) within SD-DV(D)'s format Ws=720 px; therefore:
SAR=Wd/Ws=(576x16/9)/720=64/45=1.4222
PAR=DAR/SAR=(16/9)/(64/45)=5/4=1.25

The DVD/BD tool also has presets that take into account formats and PAR.

[...]

NOTE: DAR and PAR are changed in Set Format; while SAR can be changed in Resource window: Asset --> Info --> Resize; or in Program window/Timeline: RMB --> Resize track...; or with the Scale plugin.




More information about the Cin mailing list