[MPlayer-dev-eng] [PATCH] mp_image flags in filters

Rich Felker dalias at aerifal.cx
Thu Jul 28 16:51:58 CEST 2005


On Wed, Jul 27, 2005 at 06:33:42PM +0200, Reimar Döffinger wrote:
> Hi,
> I think a lot of filters use the wrong flags in their vf_get_image
> calls, most of them use MP_IMAGETYPE_TEMP, to which mp_image.h says:
> > //codec just needs some WO memory, where it writes/copies the whole frame
> 
> But a lot of codecs also read from it, IMHO they should/must set
> MP_IMGFLAG_READABLE then (as it currently is this just gives horrible
> performance when doign dr directly into video ram).
> For others like softpulldown, telecine and tinterlace I really can't see why they
> set MP_IMGFLAG_PRESERVE, since they seem to never use that mp_image
> again.
> For tile I think MP_IMGTYPE_STATIC is not neccessary, as I understand it
> you'd only need that if you call vf_next_put_image more than once with
> the same mp_image, which is not the case here.
> Please tell me if I misunderstood something or if you have any
> comments/questions.
> Proposed patch attached.

I think you're correct on all these points. You should test several dr
setups and make sure the filters still work though.

Rich




More information about the MPlayer-dev-eng mailing list