
Hi, FWIW I'm considering boost GIL to implement the few image algorithms I need, and I need proper image I/O on top of that. As I'm using FreeImage in my current codebase, I thought about exposing FreeImage image memory layout to GIL. You can find the, quite simplistic, source code here : http://code.google.com/p/rotoglup-scratchpad/source/browse/trunk/rtgu/image_... http://code.google.com/p/rotoglup-scratchpad/source/browse/trunk/rtgu/image_... http://code.google.com/p/rotoglup-scratchpad/source/browse/trunk/rtgu/image_... I created a 'borrowed_image' class that mimics the behaviour of gil::image : it is not allocating memory itself, it takes an existing memory buffer and a 'deleter' (under the form of a boost::shared_ptr<void>) as input. This allows to use directly the memory allocated by FreeImage, avoiding extra copy, in case of file input. Feel free to use the code as a starting point, if you have similar needs, and I'd be glad to have comments about the concept of 'borrowed_image' class, and about its interface, as I feel I'm missing something. Cheers, Nicolas.