[FFmpeg-devel] [PATCH] Musepack SV8 demuxer and decoder

Kostya kostya.shishkov
Sat Nov 3 20:10:50 CET 2007


On Sat, Nov 03, 2007 at 03:51:15PM +0100, Michael Niedermayer wrote:
> Hi
> 
> On Sat, Nov 03, 2007 at 12:42:22PM +0200, Kostya wrote:
> > On Sat, Nov 03, 2007 at 04:19:01AM +0100, Michael Niedermayer wrote:
> > > Hi
> > > 
> > > On Fri, Nov 02, 2007 at 09:58:59AM +0200, Kostya wrote:
> > > > Here is $subj. I will try to provide samples soon.
> > 
> > samples are at ftp://upload.mplayerhq.hu/incoming/mpc8_samples.tar (partially uploaded)
> > 
> >  
> > > [...]
> > > 
> > > > +	code = get_bits(gb, mpc8_cnk_len[k-1][n-1] - 1);
> > > > +
> > > > +	if (code >= mpc8_cnk_lost[k-1][n-1])
> > > > +		code = ((code << 1) | get_bits1(gb)) - mpc8_cnk_lost[k-1][n-1];
> > > 
> > > duplicate
> > 
> > what is duplicated? 
> 
> +    v = get_bits(gb, mpc8_log2[m]);
> +    if(v >= mpc8_log2_lost[m])
> +        v = (v << 1) + get_bits1(gb) - mpc8_log2_lost[m];
> [...]
> +       code = get_bits(gb, mpc8_cnk_len[k-1][n-1] - 1);
> +
> +       if (code >= mpc8_cnk_lost[k-1][n-1])
> +               code = ((code << 1) | get_bits1(gb)) - mpc8_cnk_lost[k-1][n-1];

Factored out and dropped mpc8_log2* tables 
 
> [...]
> > > [...]
> > > > +/* shamelessly stolen from nutdec.c */
> > > > +static uint64_t get_v(ByteIOContext *bc){
> > > 
> > > code duplication
> > 
> > I will prepare a patch to move it to avio.[ch]. Should it be
> > left as inline or prototype + function body?
> 
> id say prototype + function body?

It uses ff_get_v 
 
> [...]
> -- 
> Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mpc8.patch.gz
Type: application/x-gzip
Size: 11512 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20071103/4d9faa0b/attachment.bin>



More information about the ffmpeg-devel mailing list