[cairo] [patch] gl: when using a surface as source/mask in drawing operation on GL surface target, we can avoid map_to_image()

Henry (Yu) Song - SISA hsong at sisa.samsung.com
Fri Mar 30 08:05:44 PDT 2012


Hi, Chris

Do you mean the patch is OK?  I don't see a need to download image from a newly created GL surface, it is just like you create a new image surface.  Am I right?

Thanks

Henry

-----Original Message-----
From: Chris Wilson [mailto:chris at chris-wilson.co.uk] 
Sent: Friday, March 30, 2012 8:01 AM
To: Henry (Yu) Song - SISA; cairo at cairographics.org
Subject: Re: [cairo] [patch] gl: when using a surface as source/mask in drawing operation on GL surface target, we can avoid map_to_image()

On Fri, 30 Mar 2012 14:55:17 +0000, "Henry (Yu) Song - SISA" <hsong at sisa.samsung.com> wrote:
> 
> commit 99d01460c93ae83c1eea5a221b34d7a990e60528
> Author: Henry (Yu) Song <hsong at sisa.samsung.com>
> Date:   Fri Mar 30 07:49:54 2012 -0700
> 
>     gl: when using a surface as a source or mask, there is no need to download
>     newly created gl surface to an image.  glReadPixels() can be slow.  We
>     can avoid that.

I intended for the backends to handle this condition (and also for when it knew the destination to be clear) as it would be generally useful. In this case it is shorthand for cairo_surface_create_similar_image() in case it is advantageous for the driver to prepare a PBO.
-Chris

--
Chris Wilson, Intel Open Source Technology Centre


More information about the cairo mailing list