Is posible create a png surface from a png buffer read from a zip file?

KiwiLib KiwiLib <[email protected]>
Newsgroups gmane.comp.lib.cairo
Message-ID <CAJrX=-6V8=0gWhF8ccWOEdaC0aKndyQqcuWavqYUoqLRV7c7uQ@mail.gmail.com>
thanks for your
​s​
answer
​s​
. The Png_data already contains png data. I 'm
looking for a
​simple ​
function
​ ​
like
​:​


sf:=cairo_image_surface_create_from_png_buffer(PNG_data);​

​I managed to load the buffer​ with my own code. Something like this.

dim as integer bytes
dim f as file
dim PNG_data as byte ptr

PNG_data = allocate(100000)

open "mypng.png", #f
read #f, PNG_data,bytes
sf:=cairo_image_surface_create_from_png_buffer(PNG_data,bytes)
close #f
​

-- 
cairo mailing list
[email protected]
http://lists.cairographics.org/mailman/listinfo/cairo
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.