If you create an ImageSurface using create_for_data with the pixel format FORMAT_RGB24 and without specifying a stride value, the default stride is calculated as width * 3 However, the pixel format for RGB24 is padded to 32 bits, so the default stride should be width * 4 The obvious workaround is to specify the stride parameter explicitly. cheers, Scott
Fix applied to CVS. * cairo/pycairo-surface.c (image_surface_create_for_data): for CAIRO_FORMAT_RGB24 set stride = width * 4 (not 3), fixes bug #5633
Closing bug (forgot to close when added last message).
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.