чт, 11 янв. 2024 г., 17:51 Andrea paz <gamberucci.andrea@gmail.com>:
> int sar_num = (aspect_w/aspect_h)*w;
> int sar_den = (aspect_w/aspect_h)*h;

if this part was from setformat_static_diff.diff then I reasoned wrong there ... please do not use (for now)


Are these the formulas that CinGG (and ffmpeg?) uses to calculate SAR?
aspect_w would be W Ratio of the Set Format window? The same for aspect_h?
While w and h would be Width and Height of the Canvas Size?
Are they integers?

in cinelerra/edlsession.h


Aspect ratio for video
        float aspect_w;
        float aspect_h;
 {..}
int output_w;
int output_h;


so aspect is float, w/h are integers.



These are the patches I have:

0001-Add-ffmpeg-rawdv-profiles-can-use-1440x1080-with-yuv.patch.patch
0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch
0001-Set-also-sample-aspect-ratio-for-encoded-ffmpeg-stre.patch
0002-Guard-ffmpeg.C-stream-sample-aspect-ratio-only-for-f.patch


0003-Add-diff-between-codec-sar-dar-and-container-sar-dar.patch
0003-fix-guard-for-stream-sample-aspect-ratio-for-more-fm.patch

I think you should apply them like 0003-fix-guard then 0003-add-diff-between

0004-Clarify-in-setformat.C-that-we-have-Display-aspect-r.patch
0005-Update-cingg-team-copyright-info-for-2024.patch
0006-Document-that-W-H-ratio-fields-mean-in-this-window.patch
setformat_static_diff.diff

Do I have to install all of them?


only up to 0006. setformat.diff is wrong, sorry.

(Should I install them all except 0003-Add-diff..., then give
autogen.sh and configure; then install 0003-Add-diff... and give a new
configure?)

I think even just recompile in cinelerra dir should be ok, (versioninfo.h included in few more files, I just touch them manually to trigger rebuild on make) but on fast machine you can do full recompile just in case, too.

PS: I tried to ask Igor Vladimirsky for clarification, but so far he
has not replied.