H264 Analysis Tools

From RidgeRun Developer Wiki
Revision as of 03:16, 17 November 2021 by Mgruner (talk | contribs) (Created page with "== Dependencies == The majority of tools presented in this wiki rely on the great FFMPEG toolkit. To install it run: <syntaxhighlight lang=bash> sudo apt install ffmpeg </sy...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Dependencies

The majority of tools presented in this wiki rely on the great FFMPEG toolkit. To install it run:

sudo apt install ffmpeg

Display Frame Information

In order to display per-frame information you may use the following command.

ffprobe -v trace -show_frames test.h264

Sample output:

[FRAME]
media_type=video
stream_index=0
key_frame=1
pkt_pts=N/A
pkt_pts_time=N/A
pkt_dts=N/A
pkt_dts_time=N/A
best_effort_timestamp=N/A
best_effort_timestamp_time=N/A
pkt_duration=48000
pkt_duration_time=0.040000
pkt_pos=0
pkt_size=1606
width=320
height=240
pix_fmt=yuv420p
sample_aspect_ratio=1:1
pict_type=I
coded_picture_number=0
display_picture_number=0
interlaced_frame=0
top_field_first=0
repeat_pict=0
color_range=tv
color_space=smpte170m
color_primaries=smpte170m
color_transfer=smpte170m
chroma_location=center
[SIDE_DATA]
side_data_type=H.26[45] User Data Unregistered SEI message
[/SIDE_DATA]
[/FRAME]
[h264 @ 0x7fd318813800] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7fd318813800] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 2
[FRAME]t message repeated 1 times
media_type=video
stream_index=0
key_frame=0
pkt_pts=N/A
pkt_pts_time=N/A
pkt_dts=N/A
pkt_dts_time=N/A
best_effort_timestamp=N/A
best_effort_timestamp_time=N/A
pkt_duration=40000
pkt_duration_time=0.033333
pkt_pos=1606
pkt_size=545
width=320
height=240
pix_fmt=yuv420p
sample_aspect_ratio=1:1
pict_type=P
coded_picture_number=1
display_picture_number=0
interlaced_frame=0
top_field_first=0
repeat_pict=0
color_range=tv
color_space=smpte170m
color_primaries=smpte170m
color_transfer=smpte170m
chroma_location=center
[/FRAME]