jack2 codebase
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.

88 lines
2.7KB

  1. /*
  2. * Copyright (c) 2007 Dmitry S. Baikov
  3. *
  4. * This program 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. * This program 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 this program; if not, write to the Free Software
  16. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  17. */
  18. #ifndef __jack_alsa_midi_impl_h__
  19. #define __jack_alsa_midi_impl_h__
  20. #include "JackConstants.h"
  21. #ifdef JACKMP
  22. #include "types.h"
  23. #ifdef __cplusplus
  24. extern "C"
  25. {
  26. #endif
  27. int JACK_is_realtime(jack_client_t *client);
  28. int JACK_client_create_thread(jack_client_t *client, pthread_t *thread, int priority, int realtime, void *(*start_routine)(void*), void *arg);
  29. jack_port_t* JACK_port_register(jack_client_t *client, const char *port_name, const char *port_type, unsigned long flags, unsigned long buffer_size);
  30. int JACK_port_unregister(jack_client_t *, jack_port_t*);
  31. void* JACK_port_get_buffer(jack_port_t*, jack_nframes_t);
  32. int JACK_port_set_alias(jack_port_t* port, const char* name);
  33. int jack_port_set_default_metadata(jack_port_t* port, const char* pretty_name);
  34. jack_nframes_t JACK_get_sample_rate(jack_client_t *);
  35. jack_nframes_t JACK_frame_time(jack_client_t *);
  36. jack_nframes_t JACK_last_frame_time(jack_client_t *);
  37. #define jack_is_realtime JACK_is_realtime
  38. #define jack_client_create_thread JACK_client_create_thread
  39. #define jack_port_register JACK_port_register
  40. #define jack_port_unregister JACK_port_unregister
  41. #define jack_port_get_buffer JACK_port_get_buffer
  42. #define jack_port_set_alias JACK_port_set_alias
  43. #define jack_port_set_default_metadata jack_port_set_default_metadata
  44. #define jack_get_sample_rate JACK_get_sample_rate
  45. #define jack_frame_time JACK_frame_time
  46. #define jack_last_frame_time JACK_last_frame_time
  47. #ifdef __cplusplus
  48. } // extern "C"
  49. #endif
  50. #else // usual jack
  51. #include "jack.h"
  52. #include "thread.h"
  53. #endif
  54. #if defined(STANDALONE)
  55. #define MESSAGE(...) fprintf(stderr, __VA_ARGS__)
  56. #elif !defined(JACKMP)
  57. #include <jack/messagebuffer.h>
  58. #endif
  59. #define info_log(...) jack_info(__VA_ARGS__)
  60. #define error_log(...) jack_error(__VA_ARGS__)
  61. #ifdef ALSA_MIDI_DEBUG
  62. #define debug_log(...) jack_info(__VA_ARGS__)
  63. #else
  64. #define debug_log(...)
  65. #endif
  66. #include "alsa_midi.h"
  67. #endif /* __jack_alsa_midi_impl_h__ */