Could you please help me? Look this file below:
[Parsed_showinfo_0 @ 0x55d39a569e00] n:48591 pts:24878592 pts_time:2024.62 pos:120292092 fmt:yuv420p sar:1/1 s:640x360 i:P iskey:0 type:B checksum:292B9CE1 plane_checksum:[F3F98FB2 02828690 02828690] mean:[20 128 128 ] stdev:[27.0 0.0 0.0 ]
[Parsed_showinfo_0 @ 0x55d39a569e00] n:48592 pts:24879104 pts_time:2024.67 pos:120291950 fmt:yuv420p sar:1/1 s:640x360 i:P iskey:0 type:B checksum:0FB59CD7 plane_checksum:[6F918FA8 02828690 02828690] mean:[20 128 128 ] stdev:[27.0 0.0 0.0 ]
[Parsed_showinfo_0 @ 0x55d39a569e00] n:48593 pts:24879616 pts_time:2024.71 pos:120292235 fmt:yuv420p sar:1/1 s:640x360 i:P iskey:0 type:B checksum:292B9CE1 plane_checksum:[F3F98FB2 02828690 02828690] mean:[20 128 128 ] stdev:[27.0 0.0 0.0 ]
[Parsed_showinfo_0 @ 0x55d39a569e00] n:48594 pts:24880128 pts_time:2024.75 pos:120291807 fmt:yuv420p sar:1/1 s:640x360 i:P iskey:0 type:P checksum:7CF59CE1 plane_checksum:[47D28FB2 02828690 02828690] mean:[20 128 128 ] stdev:[27.0 0.0 0.0 ]
[Parsed_showinfo_0 @ 0x55d39a569e00] n:48595 pts:24880640 pts_time:2024.79 pos:120292664 fmt:yuv420p sar:1/1 s:640x360 i:P iskey:0 type:B checksum:292B9CE1 plane_checksum:[F3F98FB2 02828690 02828690] mean:[20 128 128 ] stdev:[27.0 0.0 0.0 ]
...
Using this command =>
grep showinfo file.txt | grep pts_time:[0-9.]* -o | grep '[0-9]*\.[0-9]*' -o > timestamps
I get correctly all pts_time values. But I want to capture "n:X" too! Using grep showinfo file.txt | grep pts_time:[0-9.]* -o | grep '[0-9]*\.[0-9]*' -o | grep n:[0-9.]* -o | grep '[0-9]*[0-9]*'
do not work! There are no errors.
The output should be something like this:
48591/2024.62
48592/2024.67
48593/2024.71
48594/2024.75
...
Also, to avoid creating a new thread, would be possible convert the second argument (2024.62, 2024.67, etc) to human readable? In this format => hours:minute:seconds.miliseconds? Thank you.