#10894 closed defect (invalid)
FFmpeg can't handle h264 NAL units that are split between packets
Reported by: | Rokolell | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | undetermined |
Version: | 6.1 | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
When a NAL unit is split between AVPackets, FFmpeg fails to decode it properly, causing graphical glitching.
How to reproduce:
- Download the provided archive with example data.
- Compile test.c with
gcc -lavcodec -lavutil -g test.c -o test
- Run the test with
./test .
- View 420-440.yuv420p in your preferred raw image viewer to see the glitches. The resolution for each frame is shown by the example program.
Example result created by the Windows Media Foundation Decoder (which can handle these packets perfectly fine):
Change History (5)
comment:1 by , 10 months ago
comment:2 by , 10 months ago
Version: | unspecified → git-master |
---|
comment:3 by , 10 months ago
Version: | git-master → 6.1 |
---|
comment:4 by , 10 months ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Our decoders work on proper packets (for the H.264 decoder this means "access units", but generally proper NALUs (that don't span multiple packets) if the AV_CODEC_FLAG2_CHUNKS is set). If you don't have proper packets, use the parsing API to assemble them.
Note:
See TracTickets
for help on using tickets.
I preemptively uploaded the example to the videolan fileshare.