Audio plugin host https://kx.studio/carla
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.

46 lines
1.3KB

  1. /*
  2. * This file is part of Hylia.
  3. *
  4. * Hylia is free software: you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License as published by
  6. * the Free Software Foundation, either version 2 of the License, or
  7. * (at your option) any later version.
  8. *
  9. * Hylia is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License
  15. * along with Hylia. If not, see <http://www.gnu.org/licenses/>.
  16. */
  17. #ifndef MOD_LINK_H_INCLUDED
  18. #define MOD_LINK_H_INCLUDED
  19. #include <stdint.h>
  20. #ifdef __cplusplus
  21. extern "C" {
  22. #else
  23. #include <stdbool.h>
  24. #endif
  25. typedef struct _hylia_t hylia_t;
  26. typedef struct _hylia_time_info_t {
  27. double bpm, beats, phase;
  28. } hylia_time_info_t;
  29. hylia_t* hylia_create(double bpm, uint32_t buffer_size, uint32_t sample_rate);
  30. void hylia_enable(hylia_t* link, bool on, double bpm);
  31. void hylia_process(hylia_t* link, uint32_t frames, hylia_time_info_t* info);
  32. void hylia_set_tempo(hylia_t* link, double tempo);
  33. void hylia_cleanup(hylia_t* link);
  34. #ifdef __cplusplus
  35. }
  36. #endif
  37. #endif // MOD_LINK_H_INCLUDED