[MPlayer-dev-eng] [PATCH] DR support for vo_corevideo

Reimar Döffinger Reimar.Doeffinger at gmx.de
Wed Sep 5 09:00:40 CEST 2012


On 5 Sep 2012, at 02:49, Xidorn Quan <quanxunzhen at gmail.com> wrote:
> On Wed, Sep 5, 2012 at 4:06 AM, Reimar Döffinger
> <Reimar.Doeffinger at gmx.de>wrote:
> 
>> It's not so easy at all.
>> The decoder can request lots of buffers that are all in use
>> at the same time, if you can provide only one like here you
>> need to make sure you fail if you've already given out one.
>> I also don't think you should remove the DRAW_CALLBACK flag
>> in get_image, and the DRAW_CALLBACK flag is the better flag
>> to check to skip the memcpy.
>> 
> 
> Comment for MP_IMGFLAG_DRAW_CALLBACK in mp_image.h says that vo may
> clear this flag in get_image if draw_slice is not implemented, and
> vo_corevideo does not include an implementation of draw_slice, so I
> remove that flag. Is there any mistake? I don't exactly know what
> that flag means.

No, you're right, sorry.

>> vo_gl should be doing it _mostly_ right, but it's rather difficult.
>> In addition you would also have to handle the following sequence:
>> get_image for image A
>> data for image A is written
>> draw_image for image B
>> draw_image for image A
>> 
> 
> I'll follow the checkings other vo supporting dr do. I have examined
> vo_gl and vo_x11 and found that they both seem to have only one buffer
> and do not check if the sequence you gave happens.

vo_x11 supports only TEMP image type I think, that problematic behaviour at least for now is constrained to NUMBERED buffers I believe.
vo_gl doesn't need to specifically check for it, since get_image uses a separate buffer (the texture) that is not used for a draw_image that did not do a get_image first.


More information about the MPlayer-dev-eng mailing list