[MPlayer-dev-eng] [PATCH] Chroma plane copy in vf_expand

John Koleszar jkoleszar at on2.com
Tue Apr 11 16:27:40 CEST 2006


The attached patch fixes a bug in vf_expand when copying the image into
a destination buffer smaller than the source. This occurs when the
destination buffer is packed but the source buffer uses aligned h&w.

As I recall, this causes chroma problems on the top few rows in the best
case and worst case segfaults. Since mpi.chroma_height is based off of
mpi.height and not mpi.h, the padding data is copied into a buffer that
might not be big enough. Theoretically this should provide a  (small)
speedup in some cases, since the padding data isn't being copied around.

I can't reproduce this with mplayer CVS, since AFAIK my other pending
patches to ve_raw are the only case where packed images are used, so
this will have to be debated on its technical merits alone.

John

-------------- next part --------------
A non-text attachment was scrubbed...
Name: vf_expand_chroma_shift.diff
Type: text/x-patch
Size: 1063 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20060411/7fbe6e27/attachment.bin>


More information about the MPlayer-dev-eng mailing list