Hi Mateusz,
On Wed, Dec 22, 2010 at 2:36 PM, Mateusz Loskot
Hi,
I'm implementing new image format support for Boost.GIL based on the new IO implementation which has been reviewed [1] lately.
[1] http://lists.boost.org/boost-announce/2010/11/0273.php
What would be the guidelines regarding custom Device implementation? Currently, only TIFF format implements it. When it is required to implement custom Device for the IO? When recommended as a good practice?
Right now, io_new is providing support for FILE*, std::istream, and std::ostream. For TIFF I had to add another device type for TIFF* since that's the one used in libtiff. All devices are registered using c++ metafunctions, like is_output_device<...> and is_input_device<...>. You would have to add another device if the your one is missing. For instance, boost::iostream is not there yet.
I think it would be good to have such details documented.
It should be. I'll add it to my todo list. Regards, Christian