[FFmpeg-trac] #1296(undetermined:new): Multi-thread decoding artifact for MTS H.264
FFmpeg
trac at avcodec.org
Sat May 12 01:56:56 CEST 2012
#1296: Multi-thread decoding artifact for MTS H.264
----------------------------------+----------------------------------------
Reporter: andreasg | Owner:
Type: defect | Status: new
Priority: normal | Component: undetermined
Version: 0.10.3 | Resolution:
Keywords: | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
----------------------------------+----------------------------------------
Comment (by andreasg):
git bisect does not seem to handle the ffmpeg git structure very well. I
checked by hand several revisions around the revision indicated by git
bisect and I believe that I found the revision that introduced the
problem. I have no idea how support for subtitles could produce this
problem.
{{{
commit d150a147dac67faeaf6b1f25a523ae330168ee1e
Author: David Mitchell <dave at fallingcanbedeadly.com>
Date: Thu Jan 19 07:31:01 2012 -0800
Improve support for PGS subtitles.
The previous implementation assumed that a new picture would always
supersede the previous picture. Similarly, presentation segments
were assumed to pertain to the most-recently-read picture.
However, each presentation segment may refer to 0 or more pictures
by their ID. Picture IDs may repeat, and a repeated picture ID
indicates that the old picture for that ID is no longer needed
and may be discarded.
The new implementation allocates a buffer with one slot for each
possible picture ID (the picture ID is a 16-bit field) and
properly decodes presentation segments so that all relevant
pictures are output upon encountering a display segment.
Given that most PGS streams are unlikely to use more than a small
fraction of the available picture IDs, it would probably be better
to use a more memory-efficient data structure. I'm lazy though, so
I leave this to a more motivated individual.
I've tested the code with MKV files in VLC (a recent revision from
their git repo) and with HandBrake (a version that I hacked up to
use ffmpeg's PGS subtitle decoder).
Review-by: Hendrik Leppkes <h.leppkes at gmail.com>
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
}}}
Here are the revisions that I tested.
{{{
b720915be103cc8b062405bf9f7765ce3ad679d1 bad
af21823ae0dc8f72446f9beb22563a72f485a57c bad
0bb57f8bf029427059be21a562527dcfa0e264c9 bad
b955d4072e3e563b230c9ab4d6575577a3dc7314 bad
f58d67000247eb8ac5029c3f16634d5851d4dfa9 bad
0fec2cb15cc6ff1fcc724c774ec36abadcb7b6ad good
2aadff2e44fa27664ccd1b0a63829e61bf82e939 bad
d150a147dac67faeaf6b1f25a523ae330168ee1e bad
cf7c7f13cdad07a174110625f8452c8e3444717b good
575d494de561049f36f9c5492e05c7d83dd78e75 good
feb997577b66367a0c4269100888640699ee890d good
9bf9c314a093db16a009829bfe874bf03ffaecc9 good
}}}
--
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/1296#comment:4>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list