I'd like to take screnshots of some .ts file I recorded from DVB-T.
I believe that ffmpeg is the most suitable software. However, most of my .ts files have a variable aspect ratio, varying from 16:9 to 4:3 and viceversa, and if I scale the picture with the 'scale' filter the 16/9 or 4/3 programs will not have the correct AR. I also tried some expressions in the scale filter, like using the "dar" variable, but it seems it's static and contains only the first aspect ratio in the video (the one in the header).
Can anyone help me to take correct AR screenshots?
Also extracting the list of the timings in which the AR changes would help
Thank you all!
+ Reply to Thread
Results 1 to 4 of 4
Do 1st pass w forced 16:9 dar, take all decent SS's.
Do 2nd pass w forced 4:3 dar, take all decent SS's.
Unless you have some other, weird dar, you should be finished.
Or if you're worried about wrong # ordering, take all SS's each time, batch rename/number w dar designation in there, and throw out the alternating bad ones.
Thank you very much for this good advice, however I'd like this process to be completely automatic and without need to rewatch all of the screens...
While thinking about your solution, I realized that if the video is cut in segments via ffmpeg, it will keep the change of 'dar', with the difference that in the header it will report the AR which it will start with (if the segment starts in 16:9 it will report 16:9, otherwise 4:3). So I solved it like this:
1) cut the video to the position where I want to take the screenshot (from the precise frame and forward 5 seconds)
2) retrieve the aspect ratio from the header of the cutted video with ffprobe
3) use the retrieved AR to correctly scale the screenshot
All the process is automatic (I use powershell) so I don't care about the mini-segments
Thanks again for the help