tjpgdcnf.h 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. /*----------------------------------------------*/
  2. /* TJpgDec System Configurations R0.03 */
  3. /*----------------------------------------------*/
  4. #include "luat_base.h"
  5. #ifndef LUA_USE_WINDOWS
  6. #include "luat_lcd.h"
  7. #endif
  8. #ifndef JD_SZBUF
  9. #define JD_SZBUF 512
  10. #endif
  11. /* Specifies size of stream input buffer */
  12. // #ifdef LUAT_USE_LVGL
  13. // #define JD_FORMAT 0
  14. // #else
  15. #if (LUAT_LCD_COLOR_DEPTH == 32)
  16. #define JD_FORMAT 0
  17. #elif (LUAT_LCD_COLOR_DEPTH == 16)
  18. #define JD_FORMAT 1
  19. #elif (LUAT_LCD_COLOR_DEPTH == 8)
  20. #define JD_FORMAT 2
  21. #else
  22. #error "no supprt color depth"
  23. #endif
  24. // #endif
  25. /* Specifies output pixel format.
  26. / 0: RGB888 (24-bit/pix)
  27. / 1: RGB565 (16-bit/pix)
  28. / 2: Grayscale (8-bit/pix)
  29. */
  30. #ifndef JD_USE_SCALE
  31. #define JD_USE_SCALE 1
  32. #endif
  33. /* Switches output descaling feature.
  34. / 0: Disable
  35. / 1: Enable
  36. */
  37. #ifndef JD_TBLCLIP
  38. #define JD_TBLCLIP 1
  39. #endif
  40. /* Use table conversion for saturation arithmetic. A bit faster, but increases 1 KB of code size.
  41. / 0: Disable
  42. / 1: Enable
  43. */
  44. #define JD_FASTDECODE 2
  45. /* Optimization level
  46. / 0: Basic optimization. Suitable for 8/16-bit MCUs.
  47. / 1: + 32-bit barrel shifter. Suitable for 32-bit MCUs.
  48. / 2: + Table conversion for huffman decoding (wants 6 << HUFF_BIT bytes of RAM)
  49. */