2010/6/6 Reimar D?ffinger <Reimar.Doeffinger at gmx.de>: > On Sun, Jun 06, 2010 at 01:22:23PM +0200, Reimar D?ffinger wrote: >> On Sun, Jun 06, 2010 at 12:51:52PM +0200, Giorgio wrote: >> > I have a file with 4:4:4 chroma subsampling that doesn't decode >> > correctly with -vc fftheora. As you can see from the picture [2] the >> > colored rectangles in the top part of the picture aren't horizontal. >> > It's worth noting that ffplay displays the video perfectly. >> >> I think ffplay does not support slices. >> It works fine with -noslices, I guess the slice code was not updated >> properly for 4:4:4 With -noslices the problem goes away, and -vo md5sum reports the same checksum with "-vc fftheora" and "-vc theora" for all frames, although I see: [swscaler @ 0x183d970]BICUBIC scaler, from yuv444p to yuv420p using MMX2 VO: [md5sum] 1056x592 => 1056x592 Planar YV12 because md5sum vo doesn't support 444P. It would be nice to add it (looking at the code it shouldn't be too difficult). > This seems to fix it: > Index: libavcodec/vp3.c > =================================================================== > --- libavcodec/vp3.c ? ?(revision 23501) > +++ libavcodec/vp3.c ? ?(working copy) > @@ -1329,7 +1329,9 @@ > ? ? ? ? y = s->height - y - h; > ? ? } > > - ? ?cy = y >> 1; > + ? ?cy = y; > + ? ?if (s->avctx->pix_fmt == PIX_FMT_YUV420P) > + ? ? ? ?cy >>= 1; > ? ? offset[0] = s->current_frame.linesize[0]*y; > ? ? offset[1] = s->current_frame.linesize[1]*cy; > ? ? offset[2] = s->current_frame.linesize[2]*cy; This patch seems to solve the problem visually, but md5sums are still different from what I get with the theora decoder. Maybe the mantainer of the vp3 decoder can look into it? Giorgio Vazzana