Re: cairocffi and GDK-PixBuf for decoding JPEG and other image formats
Simon Sapin <[email protected]>
| Newsgroups | gmane.comp.lib.cairo |
|---|---|
| Message-ID | <[email protected]> |
Le 02/03/2013 20:04, Bill Spitzak a écrit : > I may not have been very clear in my ImageMagic suggestion. > > Cairo needs to provide some sample code that shows how to use a > third-party library to read an image from disk and get it on-screen. > > The existence of such code for Pango has pretty much evaporated all the > requests to improve the toy font api to handle multiple fonts. > > It would be ideal if this is an already-popular library that can be > installed easily on a normal Linux distribution. > > I'm pretty certain if there was just some example code that read a file > using this library into a buffer and turned it into a cairo source, and > perhaps drew it onto a destination, everybody would copy it, everybody > would use this library, and people would stop using the png api. I don’t see why people should stop using the PNG API when it’s working for them (ie. the files are known to be PNG.) But I agree it would be great to have easy-to-use code for loading images in many formats into cairo. I hope cairocffi.pixbuf can be it, for Python. GDK-PixBuf is used in GTK+, and is thus packaged everywhere. (By the way, the code shouldn’t be too hard to adapt to pycairo, if compatibility with PyGTK or PyGObject is required.) -- Simon Sapin -- cairo mailing list [email protected] http://lists.cairographics.org/mailman/listinfo/cairo