SLikeNet 0.1.3

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Static Public Member Functions | List of all members
SLNet::DataCompressor Class Reference

Does compression on a block of data. Not very good compression, but it's small and fast so is something you can compute at runtime. More...

`#include <slikenet/DataCompressor.h>`

## Static Public Member Functions

static void | Compress (unsigned char *userData, unsigned sizeInBytes, SLNet::BitStream *output)
static unsigned | DecompressAndAllocate (SLNet::BitStream *input, unsigned char **output)

## Detailed Description

Does compression on a block of data. Not very good compression, but it's small and fast so is something you can compute at runtime.

Definition at line 33 of file DataCompressor.h.

## Member Function Documentation

void DataCompressor::Compress | ( | unsigned char * | userData,
|  | unsigned | sizeInBytes,
|  | SLNet::BitStream * | output
| ) |  |

static

Definition at line 25 of file DataCompressor.cpp.

References SLNet::HuffmanEncodingTree::EncodeArray(), SLNet::HuffmanEncodingTree::GenerateFromFrequencyTable(), and RakAssert.

unsigned DataCompressor::DecompressAndAllocate | ( | SLNet::BitStream * | input,
|  | unsigned char ** | output
| ) |  |

static

Definition at line 53 of file DataCompressor.cpp.

References _FILE_AND_LINE_, SLNet::BitStream::AlignReadToByteBoundary(), SLNet::HuffmanEncodingTree::DecodeArray(), SLNet::HuffmanEncodingTree::GenerateFromFrequencyTable(), RakAssert, rakMalloc_Ex, SLNet::BitStream::Read(), and SLNet::BitStream::ReadCompressed().

The documentation for this class was generated from the following files:

- Source/include/slikenet/DataCompressor.h
- Source/src/DataCompressor.cpp