Skip to content

Latest commit

 

History

History
9 lines (5 loc) · 991 Bytes

algorithm_uniformly_sampled.md

File metadata and controls

9 lines (5 loc) · 991 Bytes

Algorithm: uniformly sampled

The uniformly sampled algorithm is by far the simplest. A clip is sampled at a fixed internal (e.g. 30 FPS) and each sample is retained. Constant tracks are compacted to a single sample and default tracks are dropped.

Compression is achieved by storing the samples on a reduced number of bits using the various rotation and vector formats.

Decompression is very fast because the data is uniformly spaced. Each sample is sorted by time and by track to ensure that when we sample a specific point in time, all the relevant samples are contiguous in memory for optimal cache locality during decompression. This also means that the decompression performance is independent of the playback direction. It will be the same when playing forward, backward, and randomly.

Here is the code for the encoder and decoder.