Go to file
Neil Roberts c5205c50d2 Try to avoid copying the GdkPixbuf when it is tightly packed
The docs for GdkPixbuf say that the last row of the image won't
necessarily be allocated to the size of the full rowstride. The rest
of Cogl and possibly GL assumes that we can copy the bitmap with
memcpy(height*rowstride) so we previously would copy the pixbuf data
to ensure this. However if the rowstride is the same as bpp*width then
there is no way for the last row to be under-allocated so in this case
we can just directly upload from the gdk pixbuf. Now that CoglBitmap
can be created with a destroy function we can make it keep a reference
to the pixbuf and unref it during its destroy callback. GdkPixbuf
seems to always pack the image with no padding between rows even if it
is RGB so this should end up always avoiding the memcpy.

The fallback code for when we do have to copy the pixbuf is now
simplified so that it copies all of the rows in a single loop. We only
copy the useful region of each row so this should be safe. The
rowstride of the CoglBitmap is now always allocated to bpp*width
regardless of the rowstride of the pixbuf.
2010-07-15 17:25:36 +01:00
cogl Try to avoid copying the GdkPixbuf when it is tightly packed 2010-07-15 17:25:36 +01:00
doc Make the material functions for setting the p wrap mode public 2010-07-13 14:29:07 +01:00
pango pango-render: set CLAMP_TO_EDGE wrap mode on glyph_material 2010-07-06 12:07:29 +01:00
Makefile.am [cogl] move clutter/pango to clutter/cogl/pango 2009-10-16 18:58:51 +01:00