easy_encoder_memusage.c File Reference

Easy .xz Stream encoder memory usage calculation. More...

`#include "easy_preset.h"`

## Functions

uint64_t | lzma_easy_encoder_memusage (uint32_t preset)
| Calculate approximate memory usage of easy encoder. More...

## Detailed Description

Easy .xz Stream encoder memory usage calculation.

## Function Documentation

## lzma_easy_encoder_memusage()

uint64_t lzma_easy_encoder_memusage | ( | uint32_t | preset | ) |

Calculate approximate memory usage of easy encoder.

This function is a wrapper for lzma_raw_encoder_memusage().

Parameters

  preset | Compression preset (level and possible flags)

Returns
  Number of bytes of memory required for the given preset when encoding. If an error occurs, for example due to unsupported preset, UINT64_MAX is returned.

References lzma_easy_preset().