Skip to main content

Module encode

Module encode 

Source
Expand description

The picture side of the stream: 64 px tiles, damage generations, and the per-client plan of which tiles to send in which codec.

Structs§

Held
What one client holds: per tile, the generation it was sent and whether that copy was lossy.
Screen
The latest frame, cut into tiles, with the generation each tile last changed in. Generations only grow, across sizes too, so a client’s record of what it holds stays comparable.

Constants§

CODEC_JPEG
CODEC_PNG
SETTLE
The 3D viewport counts as moving this long after its tiles last changed; after that its lossy tiles are re-sent lossless.
SLOW_REFRESH_TILES
On a slow link, at most this many lossless refresh tiles go in one frame: a frame that answers input never waits behind a large refresh.
TILE

Functions§

frame_message
The binary frame message.