matroskamux and number of frames

Krutskikh Ivan stein.hak at gmail.com
Fri Apr 15 16:30:30 UTC 2016


Hi!


I'm recording real time h264 video from ip cams with gstreamer. After that
I analyze it with ffprobe for export. (ffprobe -i ...  -show_streams)

for matroskamux

rtspsrc name=source latency=0 ! rtph264depay name=demux  ! h264parse !
matroskamux name=mux  ! filesink name=sink

[STREAM]
index=0
codec_name=h264
codec_long_name=H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
profile=Main
codec_type=video
codec_time_base=1/2000
codec_tag_string=[0][0][0][0]
codec_tag=0x0000
width=1920
height=1080
coded_width=1920
coded_height=1088
has_b_frames=0
sample_aspect_ratio=1:1
display_aspect_ratio=16:9
pix_fmt=yuv420p
level=42
color_range=N/A
color_space=unknown
color_transfer=unknown
color_primaries=unknown
chroma_location=left
timecode=N/A
refs=1
is_avc=1
nal_length_size=4
id=N/A
r_frame_rate=2000/2
avg_frame_rate=0/0
time_base=1/1000
start_pts=416
start_time=0.416000
duration_ts=N/A
duration=N/A
bit_rate=N/A
max_bit_rate=N/A
bits_per_raw_sample=8
nb_frames=N/A
nb_read_frames=N/A
nb_read_packets=N/A
DISPOSITION:default=1
DISPOSITION:dub=0
DISPOSITION:original=0
DISPOSITION:comment=0
DISPOSITION:lyrics=0
DISPOSITION:karaoke=0
DISPOSITION:forced=0
DISPOSITION:hearing_impaired=0
DISPOSITION:visual_impaired=0
DISPOSITION:clean_effects=0
DISPOSITION:attached_pic=0
TAG:language=eng
TAG:title=Video
[/STREAM]

for mp4mux

rtspsrc name=source latency=0 ! rtph264depay name=demux  ! h264parse !
mp4mux name=mux  ! filesink name=sink

[STREAM]
index=0
codec_name=h264
codec_long_name=H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
profile=Main
codec_type=video
codec_time_base=1/20000
codec_tag_string=avc1
codec_tag=0x31637661
width=1920
height=1080
coded_width=1920
coded_height=1088
has_b_frames=0
sample_aspect_ratio=0:1
display_aspect_ratio=0:1
pix_fmt=yuv420p
level=42
color_range=N/A
color_space=unknown
color_transfer=unknown
color_primaries=unknown
chroma_location=left
timecode=N/A
refs=1
is_avc=1
nal_length_size=4
id=N/A
r_frame_rate=20000/2
avg_frame_rate=1345000/49069
time_base=1/10000
start_pts=-1223
start_time=-0.122300
duration_ts=98138
duration=9.813800
bit_rate=2537779
max_bit_rate=N/A
bits_per_raw_sample=8
nb_frames=269
nb_read_frames=N/A
nb_read_packets=N/A
DISPOSITION:default=1
DISPOSITION:dub=0
DISPOSITION:original=0
DISPOSITION:comment=0
DISPOSITION:lyrics=0
DISPOSITION:karaoke=0
DISPOSITION:forced=0
DISPOSITION:hearing_impaired=0
DISPOSITION:visual_impaired=0
DISPOSITION:clean_effects=0
DISPOSITION:attached_pic=0
TAG:creation_time=2016-04-15 16:26:10
TAG:language=eng
TAG:handler_name=VideoHandler
[/STREAM]

Both files are fine with vlc player, but with mkv file I cannot get number
of frames and therefore cannot determine the fps.

What is wrong with my setup here?

Thanks in advance!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20160415/26f9e515/attachment.html>


More information about the gstreamer-devel mailing list