After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 615160 - Use of mpegvideoparse returns erroneous stream info
Use of mpegvideoparse returns erroneous stream info
Status: RESOLVED OBSOLETE
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
0.10.13
Other Windows
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2010-04-08 11:22 UTC by Albert Costa
Modified: 2011-05-24 08:16 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Albert Costa 2010-04-08 11:22:32 UTC
Using following test filestream :
gst-launch-0.10.exe videotestsrc num-buffers=100 ! videorate ! video/x-raw-rgb,framerate=15/1 ! queue ! ffmpegcolorspace ! ffenc_mpeg2video quantizer=4 pass=2 gop-size=0 ! mpegtsmux ! filesink location=test.ts sync=0

I expect to read the file and gets its framerate (15) and correct timestamps for buffers.
Using following reading pipeline:

gst-launch-0.10.exe filesrc location=test.ts ! decodebin ! fakesink -v
can be replaced (looking for created elements) by:

gst-launch-0.10.exe filesrc location=test.ts ! mpegtsdemux ! mpegvideoparse ! ffdec_mpeg2video ! fakesink -v

which gives as output:

/GstPipeline:pipeline0/GstFakeSink:fakesink0.GstPad:sink: caps = video/x-raw-yuv, width=(int)320, height=(int)240, framerate=(fraction)30/1, format=(fourcc)I420, interlaced=(boolean)false, pixel-aspect-ratio=(fraction)1/1
...
Setting pipeline to PLAYING ...
/GstPipeline:pipeline0/GstFakeSink:fakesink0: last-message = "chain   ******* < (115200 bytes, timestamp: none, duration: 0:00:00.000000000, offset: -1, offset_end: -1, flags: 0) 00BAB378"
New clock: GstSystemClock
/GstPipeline:pipeline0/GstFakeSink:fakesink0: last-message = "chain   ******* < (115200 bytes, timestamp: 0:00:00.000000000, duration: 0:00:00.000000000, offset: -1, offset_end: -1, flags: 0) 00BAB6E8"
...

One can see that framerate is seen as 30/1, not 15/1, and first buffer has no timestamp, second has timestamp 0...


Using exact inverse pipeline as writer gives:
gst-launch-0.10.exe filesrc location=test.ts ! mpegtsdemux ! ffdec_mpeg2video ! fakesink -v

/GstPipeline:pipeline0/GstFakeSink:fakesink0.GstPad:sink: caps = video/x-raw-yuv, width=(int)320, height=(int)240, framerate=(fraction)15/1, format=(fourcc)I420, interlaced=(boolean)false, pixel-aspect-ratio=(fraction)1/1
...
Setting pipeline to PLAYING ...
/GstPipeline:pipeline0/GstFakeSink:fakesink0: last-message = "chain   ******* < (115200 bytes, timestamp: 0:00:00.000000000, duration: 0:00:00.000000000, offset: -1, offset_end: -1, flags: 0) 00BAD4D0"
New clock: GstSystemClock
/GstPipeline:pipeline0/GstFakeSink:fakesink0: last-message = "chain   ******* < (115200 bytes, timestamp: 0:00:00.066655555, duration: 0:00:00.000000000, offset: -1, offset_end: -1, flags: 0) 00BAD528"
...

Here we can see that framerate and buffer timestamps are correct. There is thus a problem using mpegvideoparse elements (in decodebin or as pipeline element).
Comment 1 Sebastian Dröge (slomo) 2011-05-24 08:16:43 UTC
This seems to be fixed now somewhere, I get correct (and the same) timestamps and durations with and without mpegvideoparse pipelines.