After some more digging, I think I will use gdk_pixbuf_loader, like

    GdkPixbufLoader* l = gdk_pixbuf_loader_new();
    GError* err = 0;
    gboolean ok = gdk_pixbuf_loader_write(l, my_buffer, my_buffer_len, &err);
    if( ! ok ) {

    GdkPixbuf*  b = gdk_pixbuf_loader_get_pixbuf(l);
    // Build image from pixbuf ...

Any comments?


Sven Neumann wrote:

Sven Neumann <[EMAIL PROTECTED]> writes:

(b) wouldn't work at all since you need to register a thumbnail
procedure from within your raw loader and you can't use the existing
JPEG load procedure since it doesn't have the right signature.

Thinking about it more, it would actually be possible. You'd have to
call the file_jpeg_load procedure on a temporary file from within your
file_dcraw_load_thumb procedure and pass the returned image_id back to
gimp. That would work but I still think using libjpeg makes more sense


Gimp-developer mailing list

Reply via email to