rle2

package
v0.0.0-...-ecf7a0d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 5, 2016 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package rle2 implements a form of run-length encoding.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Encode

func Encode(syms symbols.ReducedSet, src []byte) []uint16

Encode encodes src using the second run-length encoding form after the MTF transformation. The return type uses uint16 because it's possible to write values greater than 255 if the full byte range is used.

Types

type Frequencies

type Frequencies []int

Frequencies contains the number of times each symbol is used, the index being the symbol.

func GetFrequencies

func GetFrequencies(syms symbols.ReducedSet, data []uint16) Frequencies

GetFrequencies gets the frequencies for a slice of symbols

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL