⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mtfll.hpp

📁 Octane v1.01.20 The Open Compression Toolkit for C++ . The Open Compression Toolkit is a set of mo
💻 HPP
字号:
/// @file mtfll.hpp
/// Move-to-front encoding
///
/// @remarks
/// Experimental move to front encoding using a linked list
///
/// @author loco
/// @date   2003.08.14
///
///

#ifndef mtfllH
#define mtfllH

#include "../compressor.hpp"

/// Experimental move to front encoding using a linked list instead of tracing the array.
/// Move to front moves the recently encoded byte to the front, so when it appears the next
/// time in the input stream it will be encoded with 00. If there comes another byte
/// to the front the previous byte will be moved back by 1 position, so it will be encoded
/// as 01.
///
/// @ingroup Compressors
///
class mtfllCompressor : public OctaneCompressor
{
public:
	mtfllCompressor(bool registerme = false);
	~mtfllCompressor() {;};

	virtual std::string GetClassName() {return "mtfll";}
	virtual std::string GetDescription() {return "Move To Front using linked list";}

	virtual OctaneCompressor *MakeCompressorInstantiation() {return new mtfllCompressor();};

protected:
	virtual bool DoProtectedCompress(bitreader &s, bitwriter &d);
	virtual bool DoProtectedDecompress(bitreader &s, bitwriter &d);
};

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -