Data Fields

lzma_filter Struct Reference

Filter options. More...

#include <filter.h>

Data Fields

lzma_vli id
 Filter ID.
void * options
 Pointer to filter-specific options structure.

Detailed Description

Filter options.

This structure is used to pass Filter ID and a pointer filter's options to liblzma. A few functions work with a single lzma_filter structure, while most functions expect a filter chain.

A filter chain is indicated with an array of lzma_filter structures. The array is terminated with .id = LZMA_VLI_UNKNOWN. Thus, the filter array must have LZMA_FILTERS_MAX + 1 elements (that is, five) to be able to hold any arbitrary filter chain. This is important when using lzma_block_header_decode() from block.h, because too small array would make liblzma write past the end of the filters array.


Field Documentation

Filter ID.

Use constants whose name begin with `LZMA_FILTER_' to specify different filters. In an array of lzma_filter structures, use LZMA_VLI_UNKNOWN to indicate end of filters.

Note:
This is not an enum, because on some systems enums cannot be 64-bit.

Referenced by coder_add_filter(), lzma_easy_preset(), lzma_filters_update(), message_filters_to_str(), and parse_block_header().

Pointer to filter-specific options structure.

If the filter doesn't need options, set this to NULL. If id is set to LZMA_VLI_UNKNOWN, options is ignored, and thus doesn't need be initialized.

Referenced by coder_add_filter(), coder_set_preset(), is_format_lzma(), lzma_easy_preset(), lzmainfo(), and message_filters_to_str().


The documentation for this struct was generated from the following file: