[FFmpeg-devel] [PATCH] RV40 Decoder - 1/3 - Loop Filter

Kostya kostya.shishkov
Fri Nov 28 08:03:04 CET 2008


On Thu, Nov 27, 2008 at 10:04:40PM +0100, Michael Niedermayer wrote:
> On Thu, Nov 27, 2008 at 09:23:21AM +0200, Kostya wrote:
> > $subj
> > 
> > Fixed several bugs in chroma loop filtering introduced during
> > refactoring, now it's bitexact again.
> 
> [...]
> 
> > +    for(s->mb_y = 0; s->mb_y < s->mb_height; s->mb_y++){
> > +        mb_pos = s->mb_y * s->mb_stride;
> > +        for(s->mb_x = 0; s->mb_x < s->mb_width; s->mb_x++, mb_pos++){
> > +            int mbtype = s->current_picture_ptr->mb_type[mb_pos];
> > +            if(IS_INTRA(mbtype) || IS_SEPARATE_DC(mbtype))
> > +                r->cbp_luma  [mb_pos] = 0xFFFF;
> > +            if(IS_INTRA(mbtype))
> > +                r->cbp_chroma[mb_pos] = 0xFF;
> > +        }
> > +    }
> > +    for(s->mb_y = 0; s->mb_y < s->mb_height; s->mb_y++){
> > +        mb_pos = s->mb_y * s->mb_stride;
> > +        for(s->mb_x = 0; s->mb_x < s->mb_width; s->mb_x++, mb_pos++){
> 
> loop filtering should be done after each block or row of blocks has been
> decoded to maximize the chance that things still are in the cache

I'd rather leave it as is since loop filter affects bottom macroblock edge
too so filtering the row above just decoded one is a bit strange.
 
> [...]
> -- 
> Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB




More information about the ffmpeg-devel mailing list