The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information....



Class TRLEncoder


The component TRLEncoder is a run length encoder for the compression of data. Run length encoded files are especially suitable for moderate compression factors with high speed conversion between compressed and uncompressed version. Note that RL encoding is only efficient if the input data stream has long strains of equal bytes.

The principle of this particular implementation is as follows: the encoding routine (Encode method) is pushing its result into an internal buffer of a predefined length (property BufLeng) until the buffer contents exceed some limit. At this point the pending overflow condition is signaled to the encoding routine. The user should then empty the buffer by applying the method GetResult. This mechanism ensures that the encoding process is most efficient both in processing time and compression ratio.


Last Update: 2023-Feb-06