[Mp4-tech] why are there 4 bytes 0x00000001 instead of 3 bytes inevery NALU?

Shankar Manuel Aghito sma com.dtu.dk
Tue Oct 24 11:55:37 ESTEDT 2006


Hi Luqman,
I think there is something wrong in your results.
Since in the encoder.cfg you have
OutputFile            = "test.264_nskipped"
And in the decoder.cfg
test.264                 ........H.26L coded bitstream
I assume that you remove NALUS from the bitstream "test.264_nskipped"
and then you name "test.264" the damaged bitstream, right?
Then, since you select in decoder.cfg
test_dec.yuv             ........Output file, YUV/RGB
test_rec.yuv             ........Ref sequence (for SNR)
The PSNR calculations in the output from the decoder should show were
errors occurr ( 0 indicate infinite PSNR, while you should see some
finite values of PSNR, since you cannot expect the error concealment to
perfectly reconstruct test_rec.yuv )
Just looking at the first of your examples (reported below), since you
use 9 slices/picture and you remove NALUs 5,14,23,32,........ you should
start seeing errors from the beginning, while in your results it seems
that the video is perfectly reconstructed until frame picture 96, when
the decoder crashes.
So I don't think that you are decoding the corrupted bitstream, I think
that you are decoding the original, and the decoder crashes for some
other reason. It must be something wrong in you settings.
When you run the decoder, do you type explicitely "ldecod decoder.cfg" ?
Regards,
Manuel
skip_nalu ----------means output from dropping
utility-------------------------
        NALU 5: skipping NALU...
        NALU 14: skipping NALU...
        NALU 23: skipping NALU...
        NALU 32: skipping NALU...
        NALU 41: skipping NALU...
        NALU 50: skipping NALU...
        NALU 65: skipping NALU...
        NALU 73: skipping NALU...
        NALU 81: skipping NALU...
        NALU 88: skipping NALU...
        NALU 92: skipping NALU...
        NALU 95: skipping NALU...
        NALU 100: skipping NALU...
        NALU 108: skipping NALU...
        NALU 116: skipping NALU...
=============================================================
skipped / total NALUs: 15 / 900 (excl. 1 SPS + 1 PPS)
ldecod.dbg.exe -----means following is the output from
decoder-------------
----------------------------- JM 10.2 (FRExt)
-----------------------------
 Decoder config file                    : (null) 
------------------------------------------------------------------------
--
 Input H.264 bitstream                  : test.264 
 Output decoded YUV                     : test_dec.yuv 
 Output status file                     : log.dec 
 Input reference file                   : test_rec.yuv 
------------------------------------------------------------------------
--
POC must = frame# or field# for SNRs to be correct
------------------------------------------------------------------------
--
  Frame       POC   Pic#   QP   SnrY    SnrU    SnrV   Y:U:V  Time(ms)
------------------------------------------------------------------------
--
0000(I)         0     0    28  0.0000  0.0000  0.0000  4:2:0    75
0001(P)         2     1    28  0.0000  0.0000  0.0000  4:2:0    67
0002(P)         4     2    28  0.0000  0.0000  0.0000  4:2:0    67
0003(P)         6     3    28  0.0000  0.0000  0.0000  4:2:0    69
0004(P)         8     4    28  0.0000  0.0000  0.0000  4:2:0    74
0005(P)        10     5    28  0.0000  0.0000  0.0000  4:2:0    71
0006(P)        12     6    28  0.0000  0.0000  0.0000  4:2:0    72
0007(P)        14     7    28  0.0000  0.0000  0.0000  4:2:0    75
0008(P)        16     8    28  0.0000  0.0000  0.0000  4:2:0    72
....
0091(P)       182    91    28  0.0000  0.0000  0.0000  4:2:0    71
0092(P)       184    92    28  0.0000  0.0000  0.0000  4:2:0    74
0093(P)       186    93    28  0.0000  0.0000  0.0000  4:2:0    74
0094(P)       188    94    28  0.0000  0.0000  0.0000  4:2:0    77
0095(P)       190    95    28  0.0000  0.0000  0.0000  4:2:0    68
0096(P)       192    96    28  0.0000  0.0000  0.0000  4:2:0    72
ERROR: failed to find NumCoeff/TrailingOnes
( 96 P + 1 I + 1 SPS + 1 PPS = 96 + 3 = 99 Frames <<---- only 1 Frame
lost ) 


More information about the Mp4-tech mailing list