8#ifndef GALAXY_MATH_ZLIB_HPP_
9#define GALAXY_MATH_ZLIB_HPP_
11#define MINIZ_HEADER_FILE_ONLY
53 static std::string
encode(
const std::string& input);
63 static std::string
decode(
const std::string& input);
81 std::string
compressor(
const std::string& input);
#define GALAXY_ZLIB_COMPLETE_CHUNK
Pragma.hpp galaxy.
char m_in[GALAXY_ZLIB_COMPLETE_CHUNK]
Input buffer.
static std::string decode(const std::string &input)
Decompresses string into ZLib.
std::string finish()
Completes the compression.
std::string compressor(const std::string &input)
Compresses string.
std::string decompressor(const std::string &input)
Decompresses a zlib string.
Mode
ZLib mode to start in.
@ COMPRESS
ZLib deflation.
@ DECOMPRESS
ZLib inflation.
z_stream m_stream
Stream object.
bool m_finished
Has the compression finished.
ZLib(const Mode mode)
Constructor.
char m_out[GALAXY_ZLIB_COMPLETE_CHUNK]
Output buffer.
static std::string encode(const std::string &input)
Compresses string into ZLib.