Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
1.0 KiB

  1. /*
  2. * encapi.h
  3. *
  4. * Definitions for calling LZX apis (encapi.c)
  5. */
  6. /*
  7. * Return codes for LZX_Encode()
  8. */
  9. #define ENCODER_SUCCESS 0
  10. #define ENCODER_READ_FAILURE 1
  11. #define ENCODER_WRITE_FAILURE 2
  12. #define ENCODER_CONSOLE_FAILURE 3
  13. bool LZX_EncodeInit(
  14. t_encoder_context * context,
  15. long compression_window_size,
  16. long second_partition_size,
  17. PFNALLOC pfnma,
  18. PFNFREE pfnmf,
  19. int FAR (DIAMONDAPI *pfnlzx_output_callback)(
  20. void * pfol,
  21. unsigned char * compressed_data,
  22. long compressed_size,
  23. long uncompressed_size
  24. ),
  25. void FAR * fci_data
  26. );
  27. void LZX_EncodeFree(t_encoder_context *context);
  28. void LZX_EncodeNewGroup(t_encoder_context *context);
  29. long LZX_Encode(
  30. t_encoder_context * context,
  31. byte * input_data,
  32. long input_size,
  33. long * bytes_compressed,
  34. long file_size_for_translation
  35. );
  36. bool LZX_EncodeFlush(t_encoder_context *context);
  37. unsigned char *LZX_GetInputData(
  38. t_encoder_context *context,
  39. unsigned long *input_position,
  40. unsigned long *bytes_available
  41. );