[vlc-devel] rtp/h264 issue

Ilkka Ollakka ileoo at videolan.org
Sat Apr 24 10:28:02 CEST 2010


On Wed, Apr 21, 2010 at 09:18:55PM +0400, An L. Ber wrote:

> Hello, Developers!

Hi An,

> In previous versions of libx264 (git-snapshot 20100218) the
> x264_encoder_headers generates SEI/SPS/PPS with NAL unit separator "00
> 00 00 01", but new version stores the SEI block with short version "00
> 00 01". This short start code can not be detected by rtp.c module and
> PPS and SEI blocks are stored as one item (with invalid data and very
> long length).

> Because the short version is valid for SEI block i've added to rtp.c
> feature to detect it: "The start sequence is some zeros (atleast 2) and
> 01" (because more than 3 zeros is also valid)


> -                    {
> -                        p_64_sps = vlc_b64_encode_binary( &p_buffer[4], i_size - 4 );
> -                        sprintf_hexa( hexa, &p_buffer[5], 3 );
> -                    }
> +   	                {
> +       	                p_64_sps = vlc_b64_encode_binary( p_buffer, i_size );
> +           	            sprintf_hexa( hexa, &p_buffer[5], 3 );
> +   	                }
>                      else if( i_nal_type == 8 )
> -                    {
> -                        p_64_pps = vlc_b64_encode_binary( &p_buffer[4], i_size - 4 );
> -                    }
> -                    i_buffer -= i_size;
> -                    p_buffer += i_size;
> +   	                {
> +       	                p_64_pps = vlc_b64_encode_binary( p_buffer, i_size );
> +   	                }
> +
> +               	    i_buffer -= i_size;
> +                   	p_buffer += i_size;

Could you send patch without this much whitespace-changes? Otherwise it
looks reasonable.

-- 
Ilkka Ollakka
Jone's Motto:
	Friends come and go, but enemies accumulate.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 490 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20100424/8a5a1c58/attachment.sig>


More information about the vlc-devel mailing list