VideoHelp Forum
+ Reply to Thread
Results 1 to 6 of 6
Thread
  1. Hi. Anyone knew the .bat code for ffmpeg to printout fps for every sec of video info. Eg. If a 1 minutes video should output 60 lines in notepad of fps.

    Purpose of this to check any frame drop or lag at any timestamp without need to watching video physically to check video lagness.
    Quote Quote  
  2. You can modify bellow script to match your expectations
    Code:
    @set name=%1
    
    @echo entry,media_type,stream_index,key_frame,pkt_pts,pkt_pts_time,pkt_dts,pkt_dts_time,best_effort_timestamp,best_effort_timestamp_time,pkt_duration,pkt_duration_time,pkt_pos,pkt_size,width,height,pix_fmt,sample_aspect_ratio,pict_type,coded_picture_number,display_picture_number,interlaced_frame,top_field_first,repeat_pict,color_range,color_space,?,?,chroma_location > "%~n1.csv"
    @ffprobe.exe -v 32 -stats -y -hide_banner -i %name% -select_streams v -print_format csv -of csv -show_entries frame >> "%~n1.csv"
    @ffprobe.exe -v 32 -stats -y -hide_banner -i %name% -select_streams v -print_format json -of json -show_entries frame >> "%~n1.json"
    Most interesting to you seem to be pkt_pts_time and pkt_duration_time, for constant frame video rate pkt_pts_time will be growing monotonically by pkt_duration_time.
    Quote Quote  
  3. Member Bernix's Avatar
    Join Date
    Apr 2016
    Location
    Europe
    Search Comp PM
    Interesting, just curious how ffmpeg know, in what player with what setting will be used and how it can affect results. I think, that FFMPEG itself is most lightweight than any other players. In some players you can choose priority of player, different video renderers and so on. So my question is how is the results right when someone for example using MadVR with bit enhanced resizing algorithm. If is possible to somehow take in account in code for FFMPEG? Supposing not. Then how to setup player to be as close as possible to pure FFMPEG that created this csv output.
    Watching it in real time with overlayed info, there is not problem. Simplify my question is - Can I be sure if no lag reported, in real life using any players, that I can be sure it will be without any lag?



    Not sure if iam right, nor if anybody understand me.



    Bernix
    Quote Quote  
  4. Haha, my pandy, ffmpeg guru, ffmpeg audio guru. Don't ever leave the forums, even when you old and grey. You've helped me so much over the yesrs, not directly, always indirectly. I appreciate your input, thank you.
    Quote Quote  
  5. Bernix - ffmpeg has three major exe files, ffmpeg, ffprobe and ffplay. That last one plays video. So it is as close to ffmpeg as it could be.

    I guess those cvs or json outputs need to be evaluated afterwards to check for discrepancies. Using preferably better programming language than windows batch is.
    Quote Quote  
  6. Originally Posted by video.baba View Post
    Haha, my pandy, ffmpeg guru, ffmpeg audio guru. Don't ever leave the forums, even when you old and grey. You've helped me so much over the yesrs, not directly, always indirectly. I appreciate your input, thank you.
    Sorry for late reply, Thank you for a generous words, truly flattered - always happy to help and if someone find those tiny pieces of knowledge useful then i'm very glad.
    Quote Quote  



Similar Threads

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