Hi,
I am having an application where currently 6 pictures are shown in a preview
with a size of 64x64 pixels. Most of my pics are 5M pixels and the generation
of the preview took too much time. Changing the function
IDirectFBImageProvider_JPEG_RenderTo solved my problem. Maybe some other users
are having similar problems. The change is:
jpeg_create_decompress(&cinfo);
jpeg_buffer_src(&cinfo, data->buffer);
jpeg_read_header(&cinfo, TRUE);
cinfo.out_color_space = JCS_RGB;
cinfo.output_components = 3;
if(cinfo.image_width > rect.w && cinfo.image_height > rect.h)
cinfo.scale_denom = cinfo.image_width / rect.w < cinfo.image_height /
rect.h ? cinfo.image_width / rect.w : cinfo.image_height / rect.h;
jpeg_start_decompress(&cinfo);
Best regards
/Dieter
_______________________________________________
directfb-dev mailing list
[email protected]
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-dev