
Thanks for the poniters.
From this example, how can I just pass not the whole file, but the file starting at the 5th byte to the end to zlib_decompressor()?
#include <fstream> #include <iostream> #include <boost/iostreams/filtering_streambuf.hpp> #include <boost/iostreams/copy.hpp> #include <boost/iostreams/filter/zlib.hpp> int main() { using namespace std; ifstream file("hello.z", ios_base::in | ios_base::binary); filtering_streambuf<input> in; in.push(zlib_decompressor()); in.push(file); boost::iostreams::copy(in, cout); } On 7/4/07, eg <egoots@gmail.com> wrote:
Meryl Silverburgh wrote:
Hi,
Can you please tell me how can I use boost iostream with zlib to inflate an byte stream? Where can I find an example?
The library docs have some examples in them. See: http://boost.org/libs/iostreams/doc/index.html
Navigate to the Quick Reference and click on the "basic_zlib_decompressor" filter link. At the bottom of the page you will see an example.
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users