pretty_effect.h 871 B

123456789101112131415161718192021222324252627282930
  1. /*
  2. This example code is in the Public Domain (or CC0 licensed, at your option.)
  3. Unless required by applicable law or agreed to in writing, this
  4. software is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
  5. CONDITIONS OF ANY KIND, either express or implied.
  6. */
  7. #pragma once
  8. #include <stdint.h>
  9. #include "esp_err.h"
  10. /**
  11. * @brief Calculate the effect for a bunch of lines.
  12. *
  13. * @param dest Destination for the pixels. Assumed to be LINECT * 320 16-bit pixel values.
  14. * @param line Starting line of the chunk of lines.
  15. * @param frame Current frame, used for animation
  16. * @param linect Amount of lines to calculate
  17. */
  18. void pretty_effect_calc_lines(uint16_t *dest, int line, int frame, int linect);
  19. /**
  20. * @brief Initialize the effect
  21. *
  22. * @return ESP_OK on success, an error from the jpeg decoder otherwise.
  23. */
  24. esp_err_t pretty_effect_init(void);