So, I tried to clarify a bit that we have display aspect ratio selectable, updated cingg team copyright year, added even more finegrained sar/dar reporting (guessed, container detected, codec detected). I tried to use libavutil function for reporting SAR in setformat.C but it need some dynamic gui subwindow/object, not static BCTitle... so just prototype that does not update as you update window, only calculated on window objects create time, so each time you reopen set format window. 3 new git diff patches hopefully for application 0003 should be applied on top of 0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch from another thread one plain diff patch just for showing where SAR info might surface if I ever learn now to create dynamic text subwindows :)
вт, 9 янв. 2024 г., 05:46 Andrew Randrianasulu <[email protected]>:
So, I tried to clarify a bit that we have display aspect ratio selectable, updated cingg team copyright year, added even more finegrained sar/dar reporting (guessed, container detected, codec detected).
I tried to use libavutil function for reporting SAR in setformat.C but it need some dynamic gui subwindow/object, not static BCTitle... so just prototype that does not update as you update window, only calculated on window objects create time, so each time you reopen set format window.
3 new git diff patches hopefully for application
0003 should be applied on top of
0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch
from another thread
one plain diff patch just for showing where SAR info might surface if I ever learn now to create dynamic text subwindows :)
oh, I calculated SAR wrongly in setformat patch, so this one should obviously only considered as placeholder/mockup. Still not sure to what exactly w/h ratio fields in setformat window relate - I thought about preset vs canvas size but this does not hold up in testing ...
Den 09.01.2024 05:31, skrev Andrew Randrianasulu via Cin:
вт, 9 янв. 2024 г., 05:46 Andrew Randrianasulu <[email protected]>:
So, I tried to clarify a bit that we have display aspect ratio selectable, updated cingg team copyright year, added even more finegrained sar/dar reporting (guessed, container detected, codec detected).
I tried to use libavutil function for reporting SAR in setformat.C but it need some dynamic gui subwindow/object, not static BCTitle... so just prototype that does not update as you update window, only calculated on window objects create time, so each time you reopen set format window.
3 new git diff patches hopefully for application
0003 should be applied on top of
0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch
from another thread
one plain diff patch just for showing where SAR info might surface if I ever learn now to create dynamic text subwindows :)
oh, I calculated SAR wrongly in setformat patch, so this one should obviously only considered as placeholder/mockup.
Still not sure to what exactly w/h ratio fields in setformat window relate - I thought about preset vs canvas size but this does not hold up in testing ...
According to the Cin-CV manual: http://cinelerra-cv.wikidot.com/cincv-manual-en:project-attributes#toc4 *W Ratio, H Ratio* Sets the ratio of the new canvas size (W, H) to the old (previous) canvas size (W, H). The new canvas size is recalculated based upon a certain factor in the W Ratio, H Ratio fields. A practical use-case: The current resolution is 640x480, and for some reason you want it to be 1.33 times wider. You don't have to calculate what 640x1.33 is; you type 1.33 into the "W" input instead, and Cinelerra calculates it for you. This tutorial <https://linuxvideoediting.blogspot.com/2023/08/canvas-w-ratio-h-ratio-cinelerra.html> explores in more detail these settings. It is in Russian but easily translatable with GoogleTranslator, DeepL or similar. The latter Tutorial can be translated ...... https://linuxvideoediting.blogspot.com/2023/08/canvas-w-ratio-h-ratio-cinele...
Den 09.01.2024 08:37, skrev Terje J. Hanssen:
Den 09.01.2024 05:31, skrev Andrew Randrianasulu via Cin:
вт, 9 янв. 2024 г., 05:46 Andrew Randrianasulu <[email protected]>:
So, I tried to clarify a bit that we have display aspect ratio selectable, updated cingg team copyright year, added even more finegrained sar/dar reporting (guessed, container detected, codec detected).
I tried to use libavutil function for reporting SAR in setformat.C but it need some dynamic gui subwindow/object, not static BCTitle... so just prototype that does not update as you update window, only calculated on window objects create time, so each time you reopen set format window.
3 new git diff patches hopefully for application
0003 should be applied on top of
0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch
from another thread
one plain diff patch just for showing where SAR info might surface if I ever learn now to create dynamic text subwindows :)
oh, I calculated SAR wrongly in setformat patch, so this one should obviously only considered as placeholder/mockup.
Still not sure to what exactly w/h ratio fields in setformat window relate - I thought about preset vs canvas size but this does not hold up in testing ...
According to the Cin-CV manual: http://cinelerra-cv.wikidot.com/cincv-manual-en:project-attributes#toc4
*W Ratio, H Ratio* Sets the ratio of the new canvas size (W, H) to the old (previous) canvas size (W, H). The new canvas size is recalculated based upon a certain factor in the W Ratio, H Ratio fields. A practical use-case: The current resolution is 640x480, and for some reason you want it to be 1.33 times wider. You don't have to calculate what 640x1.33 is; you type 1.33 into the "W" input instead, and Cinelerra calculates it for you. This tutorial <https://linuxvideoediting.blogspot.com/2023/08/canvas-w-ratio-h-ratio-cinelerra.html> explores in more detail these settings. It is in Russian but easily translatable with GoogleTranslator, DeepL or similar.
The latter Tutorial can be translated ...... https://linuxvideoediting.blogspot.com/2023/08/canvas-w-ratio-h-ratio-cinele...
Excuse me for the parlance used in the refered blogpost.. I was not aware it had been mentioned before on our mailinglist...
вт, 9 янв. 2024 г., 11:20 Terje J. Hanssen via Cin < [email protected]>:
Den 09.01.2024 08:37, skrev Terje J. Hanssen:
Den 09.01.2024 05:31, skrev Andrew Randrianasulu via Cin:
вт, 9 янв. 2024 г., 05:46 Andrew Randrianasulu <[email protected]>:
So, I tried to clarify a bit that we have display aspect ratio selectable, updated cingg team copyright year, added even more finegrained sar/dar reporting (guessed, container detected, codec detected).
I tried to use libavutil function for reporting SAR in setformat.C but it need some dynamic gui subwindow/object, not static BCTitle... so just prototype that does not update as you update window, only calculated on window objects create time, so each time you reopen set format window.
3 new git diff patches hopefully for application
0003 should be applied on top of
0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch
from another thread
one plain diff patch just for showing where SAR info might surface if I ever learn now to create dynamic text subwindows :)
oh, I calculated SAR wrongly in setformat patch, so this one should obviously only considered as placeholder/mockup.
Still not sure to what exactly w/h ratio fields in setformat window relate - I thought about preset vs canvas size but this does not hold up in testing ...
According to the Cin-CV manual: http://cinelerra-cv.wikidot.com/cincv-manual-en:project-attributes#toc4
*W Ratio, H Ratio* Sets the ratio of the new canvas size (W, H) to the old (previous) canvas size (W, H). The new canvas size is recalculated based upon a certain factor in the W Ratio, H Ratio fields. A practical use-case: The current resolution is 640x480, and for some reason you want it to be 1.33 times wider. You don't have to calculate what 640x1.33 is; you type 1.33 into the "W" input instead, and Cinelerra calculates it for you. This tutorial <https://linuxvideoediting.blogspot.com/2023/08/canvas-w-ratio-h-ratio-cinelerra.html> explores in more detail these settings. It is in Russian but easily translatable with GoogleTranslator, DeepL or similar.
The latter Tutorial can be translated ......
https://linuxvideoediting.blogspot.com/2023/08/canvas-w-ratio-h-ratio-cinele...
Excuse me for the parlance used in the refered blogpost.. I was not aware it had been mentioned before on our mailinglist...
no no it all good. May be we can add a bit more help (tooltips?) to window itself so ot will be a bit more obvious. Even if code is here to read I failed to do so spectacularly .....
-- Cin mailing list [email protected] https://lists.cinelerra-gg.org/mailman/listinfo/cin
int sar_num = (aspect_w/aspect_h)*w; int sar_den = (aspect_w/aspect_h)*h;
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? 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 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? (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?) PS: I tried to ask Igor Vladimirsky for clarification, but so far he has not replied.
чт, 11 янв. 2024 г., 17:51 Andrea paz <[email protected]>:
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.
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.
If I understand correctly: without deleting the files, without doing make clean; I install the 0003 patch and then go directly to make && make install?
чт, 11 янв. 2024 г., 18:21 Andrea paz <[email protected]>:
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.
If I understand correctly: without deleting the files, without doing make clean; I install the 0003 patch and then go directly to make && make install?
yeah, I tested them like this. I do not think any of them touch configure.ac or Makefile in thirdparty dir, so just recompile (or may be "touch *.C", and then make in cinelerra directory - due to our incomplete *.h file tracking ) should do it.
Have checked into GIT so that I do not get too far behind or something gets missed: 1) 0001-Fix-libvorbis-option.patch 2) 0001-Add-ffmpeg-rawdv-profiles-can-use-1440x1080-with-yuv.patch 3) 0004-Clarify-in-setformat.C-that-we-have-Display-aspect-r.patch (BUT I changed abbreviation of Disp. to Display because users who might have to translate from English will be able to do so easily without guessing). 4) 0006-Document-that-W-H-ratio-fields-mean-in-this-window.patch (also changed prev. to previous; same reason) 5) 0005-Update-cingg-team-copyright-info-for-2024.patch Much more understanding, testing, and "do we really want to do this?" is still required for: 1) 0001-Set-also-sample-aspect-ratio-for-encoded-ffmpeg-stre.patch 2) 0003-fix-guard-for-stream-sample-aspect-ratio-for-more-fm.patch 3) 0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch 4) setformat_static_diff.diff (ANDREW already said not to use yet) 5) 0003-Add-diff-between-codec-sar-dar-and-container-sar-dar.patch On Mon, Jan 8, 2024 at 7:47 PM Andrew Randrianasulu <[email protected]> wrote:
So, I tried to clarify a bit that we have display aspect ratio selectable, updated cingg team copyright year, added even more finegrained sar/dar reporting (guessed, container detected, codec detected).
I tried to use libavutil function for reporting SAR in setformat.C but it need some dynamic gui subwindow/object, not static BCTitle... so just prototype that does not update as you update window, only calculated on window objects create time, so each time you reopen set format window.
3 new git diff patches hopefully for application
0003 should be applied on top of
0001-Add-guessed-detected-SAR-DAR-values-to-ffmpeg-asset-.patch
from another thread
one plain diff patch just for showing where SAR info might surface if I ever learn now to create dynamic text subwindows :)
Patches work without errors. Good notes in the Set Format window. Thank you. Do I need to do any special testing?
чт, 11 янв. 2024 г., 23:35 Andrea paz <[email protected]>:
Patches work without errors. Good notes in the Set Format window. Thank you. Do I need to do any special testing?
just use normally, look at asset info -> details for ffmpeg decoded assets from time to time ( I think reduction factor of 1024*1024 was a bit too big, so some display aspect ratios in newly added lines will look unusually big ?)
Should the following note appear in Set Format? I don't see it. +/* W Ratio, H Ratio +Sets the ratio of the new canvas size (W, H) to the old (previous) canvas size (W, H). +The new canvas size is recalculated based upon a certain factor in the W Ratio, +H Ratio fields. A practical use-case: The current resolution is 640x480, and for some reason +you want it to be 1.33 times wider. You don't have to calculate what 640x1.33 is; +you type 1.33 into the "W" input instead, and Cinelerra calculates it for you. */ I don't understand what 1024*1024 means. I don't seem to notice any variation. Here is an example of the "Detail" window: https://postimg.cc/cg8Q6zQ4
пт, 12 янв. 2024 г., 00:40 Andrea paz <[email protected]>:
Should the following note appear in Set Format? I don't see it.
No, it just code comment you can put anything between /* and */ as human-readable note to future self (or anyone reading the file)
+/* W Ratio, H Ratio +Sets the ratio of the new canvas size (W, H) to the old (previous) canvas size (W, H). +The new canvas size is recalculated based upon a certain factor in the W Ratio, +H Ratio fields. A practical use-case: The current resolution is 640x480, and for some reason +you want it to be 1.33 times wider. You don't have to calculate what 640x1.33 is; +you type 1.33 into the "W" input instead, and Cinelerra calculates it for you. */
I don't understand what 1024*1024 means. I don't seem to notice any variation.
there is function av_reduce, in patch. You can see its last argument expressed as 1024*1024 - probably good for more exact result, but as Phyllis noticed can produce some ratios (m:n) we never saw before :)
Here is an example of the "Detail" window: https://postimg.cc/cg8Q6zQ4
just use normally, look at asset info -> details for ffmpeg decoded assets from time to time ( I think reduction factor of 1024*1024 was a bit too big, so some display aspect ratios in newly added lines will look unusually big ?)
Have tested at least 60 files -- these are from my set of test files so have been around awhile so are older files. Observations: 1) about "some display aspect ratios ... will look unusually big" - I did not see this as unusual AND whenever the display aspect ratio was big, it perfectly matched the results given by ffprobe outside CinGG. 2) "guessed" seemed to always match "codec" (although guessed would take the equivalent number of, for example, 72x72 as also shown by ffprobe and make it 1:1) AND whenever "guessed" was present, "codec" was too. So, could we eliminate "guessed" since it was the initial setting before "codec" and "container" were added as correct instead of just a guess?
Correction - on at least 1 file, when "guessed" was present, "codec" was not but "container" was. So still, "guessed" is redundant and looks icky. On Sat, Jan 13, 2024 at 11:33 AM Phyllis Smith <[email protected]> wrote:
just use normally, look at asset info -> details for ffmpeg decoded assets
from time to time ( I think reduction factor of 1024*1024 was a bit too big, so some display aspect ratios in newly added lines will look unusually big ?)
Have tested at least 60 files -- these are from my set of test files so have been around awhile so are older files.
Observations: 1) about "some display aspect ratios ... will look unusually big" - I did not see this as unusual AND whenever the display aspect ratio was big, it perfectly matched the results given by ffprobe outside CinGG. 2) "guessed" seemed to always match "codec" (although guessed would take the equivalent number of, for example, 72x72 as also shown by ffprobe and make it 1:1) AND whenever "guessed" was present, "codec" was too.
So, could we eliminate "guessed" since it was the initial setting before "codec" and "container" were added as correct instead of just a guess?
сб, 13 янв. 2024 г., 21:34 Phyllis Smith <[email protected]>:
just use normally, look at asset info -> details for ffmpeg decoded assets
from time to time ( I think reduction factor of 1024*1024 was a bit too big, so some display aspect ratios in newly added lines will look unusually big ?)
Have tested at least 60 files -- these are from my set of test files so have been around awhile so are older files.
Observations: 1) about "some display aspect ratios ... will look unusually big" - I did not see this as unusual AND whenever the display aspect ratio was big, it perfectly matched the results given by ffprobe outside CinGG. 2) "guessed" seemed to always match "codec" (although guessed would take the equivalent number of, for example, 72x72 as also shown by ffprobe and make it 1:1) AND whenever "guessed" was present, "codec" was too.
So, could we eliminate "guessed" since it was the initial setting before "codec" and "container" were added as correct instead of just a guess?
well, this av_guess function was used by me for guessing aspect ratio of loading assets -:) hopefully it will never glitch so there will be no need to debug THAT So, yeah ... you can comment out guessed report line ...
This is a nice addition to the Detailed Info in the Resources Window for Media. It was checked into GIT with the "guessed" sar/dar commented out since it seemed redundant. Thank you to Andrew. Observations:
1) about "some display aspect ratios ... will look unusually big" - I did not see this as unusual AND whenever the display aspect ratio was big, it perfectly matched the results given by ffprobe outside CinGG. 2) "guessed" seemed to always match "codec" (although guessed would take the equivalent number of, for example, 72x72 as also shown by ffprobe and make it 1:1) AND whenever "guessed" was present, "codec" was too.
So, could we eliminate "guessed" since it was the initial setting before "codec" and "container" were added as correct instead of just a guess?
well, this av_guess function was used by me for guessing aspect ratio of loading assets -:)
hopefully it will never glitch so there will be no need to debug THAT
So, yeah ... you can comment out guessed report line ...
participants (4)
-
Andrea paz -
Andrew Randrianasulu -
Phyllis Smith -
Terje J. Hanssen