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 676296 - mpegtsdemux: no bitrate and wrong duration reported for MPEG-TS file
mpegtsdemux: no bitrate and wrong duration reported for MPEG-TS file
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
0.10.22
Other Linux
: Normal normal
: 0.10.24
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2012-05-18 08:33 UTC by Javier Jardón (IRC: jjardon)
Modified: 2012-05-18 23:19 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Javier Jardón (IRC: jjardon) 2012-05-18 08:33:10 UTC
Hi,

AFAIK for MPEG containers GStreamer can only create estimates of the duration based on the file size and bitrate. The problem is that I have a file here where gst-discoverer doesnt report any bitrate, and get a incorrect duration of 46:36 min.

So video player like totem work incorrectly (if you move the slice). Is there any way to fix this?

VLC and mplayer seems to not have problems with the file:
Comment 1 Tim-Philipp Müller 2012-05-18 09:04:41 UTC
> AFAIK for MPEG containers GStreamer can only create estimates of the duration
> based on the file size and bitrate

I don't think that's how it's done. For local files we should be able to find the exact duration (unless there are unusual things like discontinuities in the middle or so).

Please could you make the file available, then we can have a look.
Comment 2 Javier Jardón (IRC: jjardon) 2012-05-18 17:28:20 UTC
Sorry for the delay, I had internet connection problems:

http://dl.dropbox.com/u/55505240/%5BMPEGSys-Mpeg2-AC3%5D.mpeg
Comment 3 Tim-Philipp Müller 2012-05-18 23:17:59 UTC
Thanks for the file.

This issue seems to be fixed in git (0.10 branch anyway):


0$ gst-discoverer-0.10 -v ~/samples/676296-MPEGSys-Mpeg2-AC3.mpeg
Analyzing file:///home/tpm/samples/676296-MPEGSys-Mpeg2-AC3.mpeg
Done discovering file:///home/tpm/samples/676296-MPEGSys-Mpeg2-AC3.mpeg

Topology:
  container: video/mpegts, systemstream=(boolean)true, packetsize=(int)188
    audio: audio/x-ac3
      Codec:
        audio/x-ac3
      Additional info:
        None
      Language: <unknown>
      Channels: 2
      Sample rate: 44100
      Depth: 0
      Bitrate: 96000
      Max bitrate: 0
      Tags:
        taglist, audio-codec=(string)"AC-3\ \(ATSC\ A/52\)", bitrate=(uint)96000;
      
    video: video/mpeg, mpegversion=(int)2, systemstream=(boolean)false, parsed=(boolean)true, width=(int)1280, height=(int)720, framerate=(fraction)30/1, pixel-aspect-ratio=(fraction)1/1, codec_data=(buffer)000001b35002d015ffffe340000001b5146a00010000, profile=(string)main, level=(string)high-1440, interlaced=(boolean)false
      Codec:
        video/mpeg, mpegversion=(int)2, systemstream=(boolean)false, parsed=(boolean)true, width=(int)1280, height=(int)720, framerate=(fraction)30/1, pixel-aspect-ratio=(fraction)1/1, codec_data=(buffer)000001b35002d015ffffe340000001b5146a00010000, profile=(string)main, level=(string)high-1440, interlaced=(boolean)false
      Additional info:
        None
      Width: 1280
      Height: 720
      Depth: 0
      Frame rate: 30/1
      Pixel aspect ratio: 1/1
      Interlaced: false
      Bitrate: 10680168
      Max bitrate: 13673520
      Tags:
        taglist, video-codec=(string)"MPEG\ 2\ Video", minimum-bitrate=(uint)13673520, bitrate=(uint)10680168, maximum-bitrate=(uint)13673520;
      

Properties:
  Duration: 0:03:48.067900185
  Seekable: yes
  Tags: 
      video codec: MPEG 2 Video
      audio codec: AC-3 (ATSC A/52)
      bitrate: 96000
      minimum bitrate: 13673520
      maximum bitrate: 13673520