rle

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RLE

type RLE struct {
	// contains filtered or unexported fields
}

RLE holds metadata that is used while reading and writing run length encoded data.

func New

func New(width int32, size int) (*RLE, error)

New creates an RLE struct based on the maximum bitwidth (width) of the data that is to be encoded/decoded.

func (*RLE) Bytes

func (r *RLE) Bytes() []byte

Bytes the raw run length encoded data.

func (*RLE) Read

func (r *RLE) Read(in io.Reader) ([]uint8, int, error)

Read reads the RLE encoded definition levels

func (*RLE) Write

func (r *RLE) Write(value uint8)

Write encodes 'value' to run length encoded data.

Jump to

Keyboard shortcuts

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