diff options
Diffstat (limited to 'transcode.cpp')
-rw-r--r-- | transcode.cpp | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/transcode.cpp b/transcode.cpp deleted file mode 100644 index 394f604..0000000 --- a/transcode.cpp +++ /dev/null @@ -1,18 +0,0 @@ -#include "transcode.h" - -#include <boost/iostreams/device/file.hpp> -#include <boost/iostreams/filtering_stream.hpp> - -Transcoder::Transcoder(std::string p, HTTP::Connection::p r, DecoderFilter::p d, EncoderFilter::p e) : path(p), res(r), decoder(d), encoder(e) { -} - -void Transcoder::run() { - const std::streamsize buffer_size = 0x1000; - boost::iostreams::file_source is(path, std::ios::in | std::ios::binary); - boost::iostreams::filtering_istream s; - s.push(*encoder.get(), buffer_size); - s.push(*decoder.get(), buffer_size); - s.push(is, buffer_size); - - res->send_data(s); -} |