heatshrink_config.h 782 B

12345678910111213141516171819202122232425262728
  1. #ifndef HEATSHRINK_CONFIG_H
  2. #define HEATSHRINK_CONFIG_H
  3. #include <furi.h>
  4. /* Should functionality assuming dynamic allocation be used? */
  5. #ifndef HEATSHRINK_DYNAMIC_ALLOC
  6. #define HEATSHRINK_DYNAMIC_ALLOC 1
  7. #endif
  8. #if HEATSHRINK_DYNAMIC_ALLOC
  9. /* Optional replacement of malloc/free */
  10. #define HEATSHRINK_MALLOC(SZ) malloc(SZ)
  11. #define HEATSHRINK_FREE(P, SZ) free(P)
  12. #else
  13. /* Required parameters for static configuration */
  14. #define HEATSHRINK_STATIC_INPUT_BUFFER_SIZE 1024
  15. #define HEATSHRINK_STATIC_WINDOW_BITS 8
  16. #define HEATSHRINK_STATIC_LOOKAHEAD_BITS 4
  17. #endif
  18. /* Turn on logging for debugging. */
  19. #define HEATSHRINK_DEBUGGING_LOGS 0
  20. /* Use indexing for faster compression. (This requires additional space.) */
  21. #define HEATSHRINK_USE_INDEX 1
  22. #endif