[mythtv] New MPEG2 commercial-cut code ready for testing

Geoffrey Hausheer mythtv0368 at phracturedblue.com
Mon Nov 14 22:31:29 EST 2005


On 11/14/05, Bryan Mayland wrote:
> Geoffrey Hausheer wrote:
> > I have found a couple of trivial fixes that may address the blockiness
> > and the hanging (and a segfault).  Go here:
> > http://www.pblue.org/myth/mpeg2fix-0.8.tgz
> >
>     I get segfaults right at the beginning of every stream I've tried
> (has occurred in 0.4, 0.7, 0.8, haven't tested other versions).
> Opening /mnt/store/1015_20051105183000.mpg
> Input #0, mpeg, from '/mnt/store/1015_20051105183000.mpg':
>   Duration: N/A, bitrate: N/A
>   Stream #0.0[0x1e0], 29.97 fps: Video: mpeg2video, yuv420p, 640x480,
> 9000 kb/s
>   Stream #0.1[0x1c0]: Audio: mp2, 48000 Hz, stereo, 384 kb/s
> #0 PTS:36036 Delta: 0.000000ms queue: 12
> #1 PTS:34684 Delta: 15.022222ms queue: 2
> Warning, QMAT_SHIFT is larger then 21, overflows possible
> Segmentation fault      (core dumped)
>
> Backtrace:
> #0  0xb7436fc6 in dsputil_init_mmx ()
>    from /usr/local/lib/libmythavcodec-0.18.so.0
> #1  0x083404d0 in ?? ()
>
You'd need to recompile with debug enabled, and might need a
thread-capable gdb.  make sure to always use 'thread apply all bt'
when debugging.  But this looks like a failure inside of libavcodec,
which makes little sense.  My guess is that the problem is happening
in build_frame.  running with debug set to '-d 3' would be interesting
 you could also set a break point at line 723, and step through until
you find the faulty instruction.  using imagemagik to display the
resulting yuv file might be useful too.
  You could also try with the static build here:
http://www.pblue.org/myth/mpeg2fix.bz2
This would at least help seperate problems with your env from problems
with the code.

capturing the fault in gdb with that version would help determine if
it is specific to your libav, or your streams.

> Bonus: Shell script to pull cutlist from DB and call mpeg2fix
Just be awate, this tool is still in the debugging stage. You
certainly won't want to replace the orginal files with processed ones
at this point.  As soon as I am convinced the code is working pretty
well, it will be added to myth, at which times such scripts won't be
needed.

.Geoff


More information about the mythtv-dev mailing list