MiniQuake2

src/miniquake2/format/cinematic.ml

Provides miniquake2 format cinematic facilities for this project.

Package
miniquake2.format.cinematic
Reachable
Yes

Imports

Declarations

buildTables

function buildTables(header)

Build tables.

ParameterTypeDefaultDescription
headerdynamic—header value consumed by this operation.

View source

buildTree

function buildTree(countRow)

Build tree.

ParameterTypeDefaultDescription
countRowdynamic—countRow value consumed by this operation.

View source

decompress

function decompress(compressed, tables, maximumOutput)

Decompress state.

ParameterTypeDefaultDescription
compresseddynamic—compressed value consumed by this operation.
tablesdynamic—tables value consumed by this operation.
maximumOutputdynamic—maximumOutput value consumed by this operation.

View source

HEADER_BYTES

const HEADER_BYTES = 20 + HUFFMAN_COUNT_BYTES

Defines the header bytes constant used by the miniquake2 format cinematic module.

View source

HUFFMAN_COUNT_BYTES

const HUFFMAN_COUNT_BYTES = 256 * 256

Defines the huffman count bytes constant used by the miniquake2 format cinematic module.

View source

parseHeader

function parseHeader(data)

Parse header.

ParameterTypeDefaultDescription
datadynamic—Input data consumed by the operation.

View source

readFrame

function readFrame(data, offset, frameNumber, header, tables)

Reads frame for the miniquake2 format cinematic workflow.

ParameterTypeDefaultDescription
datadynamic—Input data consumed by the operation.
offsetdynamic—Zero-based offset at which processing starts.
frameNumberdynamic—frameNumber value consumed by this operation.
headerdynamic—header value consumed by this operation.
tablesdynamic—tables value consumed by this operation.

View source

smallestNode

function smallestNode(counts, used, count)

Return the smallest node value.

ParameterTypeDefaultDescription
countsdynamic—counts value consumed by this operation.
useddynamic—used value consumed by this operation.
countdynamic—Number of items or units to process.

View source