MiniQuake

src/miniquake/render_evidence.ml

Package
miniquake.render_evidence
Reachable
Yes

Imports

Declarations

boolText

function boolText(value)

Implements the `boolText` operation for `miniquake.render_evidence` (bool text).

ParameterTypeDefaultDescription
valuedynamic—Value consumed by `boolText`.

View source

captured

function captured()

Implements the `captured` operation for `miniquake.render_evidence` (captured).

View source

captureDone

captureDone

Tracks the module-level capture done state owned by `miniquake.render_evidence`.

View source

captureIfRequested

function captureIfRequested(frameNumber, width, height)

Implements the `captureIfRequested` operation for `miniquake.render_evidence` (capture if requested).

ParameterTypeDefaultDescription
frameNumberdynamic—The frame number input consumed by `captureIfRequested`.
widthdynamic—Requested width in pixels or data units.
heightdynamic—Requested height in pixels or data units.

View source

capturePrefix

capturePrefix

Tracks the module-level capture prefix state owned by `miniquake.render_evidence`.

View source

captureRequested

captureRequested

Tracks the module-level capture requested state owned by `miniquake.render_evidence`.

View source

captureResult

captureResult

Tracks the module-level capture result state owned by `miniquake.render_evidence`.

View source

captureTargetFrame

captureTargetFrame

Tracks the module-level capture target frame state owned by `miniquake.render_evidence`.

View source

configure

function configure(prefix, targetFrame)

Implements the `configure` operation for `miniquake.render_evidence` (configure).

ParameterTypeDefaultDescription
prefixdynamic—The prefix input consumed by `configure`.
targetFramedynamic—The target frame input consumed by `configure`.

View source

EVIDENCE_SCHEMA

const EVIDENCE_SCHEMA = 1

Defines the evidence schema value used by `miniquake.render_evidence`.

View source

FNV_OFFSET

const FNV_OFFSET = 2166136261

Defines the fnv offset value used by `miniquake.render_evidence`.

View source

FNV_PRIME

const FNV_PRIME = 16777619

Defines the fnv prime value used by `miniquake.render_evidence`.

View source

hashByte

inline function hashByte(state, value)

Returns whether `miniquake.render_evidence` has h byte.

ParameterTypeDefaultDescription
statedynamic—Mutable `miniquake.render_evidence` state used by `hashByte`.
valuedynamic—Value consumed by `hashByte`.

View source

hashBytes

function hashBytes(data)

Fold bytes into the deterministic rolling hash.

ParameterTypeDefaultDescription
datadynamic—Input data consumed by the operation.

View source

lastResult

function lastResult()

Return last result for the active module state.

View source

nonBlackPixels

function nonBlackPixels(rgba)

Implements the `nonBlackPixels` operation for `miniquake.render_evidence` (non black pixels).

ParameterTypeDefaultDescription
rgbadynamic—The rgba input consumed by `nonBlackPixels`.

View source

reset

function reset()

Implements the `reset` operation for `miniquake.render_evidence` (reset).

View source

SAMPLE_GRID

const SAMPLE_GRID = 16

Defines the sample grid value used by `miniquake.render_evidence`.

View source

sampleCoordinate

function sampleCoordinate(cell, extent, gridSize)

Build deterministic test data for coordinate.

ParameterTypeDefaultDescription
celldynamic—The cell input consumed by `sampleCoordinate`.
extentdynamic—The extent input consumed by `sampleCoordinate`.
gridSizedynamic—Size of the requested data or resource.

View source

samplePixelHash

function samplePixelHash(rgba, width, height, gridSize)

Build deterministic test data for pixel hash.

ParameterTypeDefaultDescription
rgbadynamic—The rgba input consumed by `samplePixelHash`.
widthdynamic—Requested width in pixels or data units.
heightdynamic—Requested height in pixels or data units.
gridSizedynamic—Size of the requested data or resource.

View source

shouldCapture

function shouldCapture(frameNumber)

Report whether should capture.

ParameterTypeDefaultDescription
frameNumberdynamic—The frame number input consumed by `shouldCapture`.

View source

summaryJson

function summaryJson(frameNumber, width, height, pixelBytes, tgaBytes, pixelHash, tgaHash, sampleHash, nonBlack, imagePath)

Implements the `summaryJson` operation for `miniquake.render_evidence` (summary json).

ParameterTypeDefaultDescription
frameNumberdynamic—The frame number input consumed by `summaryJson`.
widthdynamic—Requested width in pixels or data units.
heightdynamic—Requested height in pixels or data units.
pixelBytesdynamic—Byte data consumed by the operation.
tgaBytesdynamic—Byte data consumed by the operation.
pixelHashdynamic—The pixel hash input consumed by `summaryJson`.
tgaHashdynamic—The tga hash input consumed by `summaryJson`.
sampleHashdynamic—The sample hash input consumed by `summaryJson`.
nonBlackdynamic—The non black input consumed by `summaryJson`.
imagePathdynamic—Filesystem path used by the operation.

View source

summaryPath

function summaryPath(prefix)

Return summary path derived from the active module state.

ParameterTypeDefaultDescription
prefixdynamic—The prefix input consumed by `summaryPath`.

View source

tgaPath

function tgaPath(prefix)

Return tga path derived from the active module state.

ParameterTypeDefaultDescription
prefixdynamic—The prefix input consumed by `tgaPath`.

View source