summaryrefslogtreecommitdiff
path: root/encoder.h
blob: 9949b5263647844e57a44d692ec99bfde5cc2015 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#ifndef ENCODER_H
#define ENCODER_H

#include <boost/cstdint.hpp>
#include <boost/function.hpp>
#include <boost/functional/factory.hpp>
#include <boost/functional/value_factory.hpp>

#include <string>

class EncoderBase {
	public:
		virtual size_t encode(uint8_t *input, size_t input_size, uint8_t *output, size_t output_size) = 0;
		virtual size_t flush(uint8_t *output, size_t output_size) = 0;
};

namespace encoder {
	void init();
	EncoderBase *get_encoder(const std::string& name);
};

#endif