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.

58 lines
1.9KB

  1. /*
  2. * Copyright (C) 2004 Rui Nuno Capela, Lee Revell
  3. *
  4. * This program is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU Lesser General Public License
  6. * as published by the Free Software Foundation; either version 2.1
  7. * of the License, or (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 GNU
  12. * Lesser General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU Lesser General Public
  15. * License along with this program; if not, write to the Free
  16. * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  17. * 02111-1307, USA.
  18. *
  19. */
  20. #ifndef __statistics_h__
  21. #define __statistics_h__
  22. #ifdef __cplusplus
  23. extern "C"
  24. {
  25. #endif
  26. #include <jack/types.h>
  27. /**
  28. * @return the maximum delay reported by the backend since
  29. * startup or reset. When compared to the period size in usecs, this
  30. * can be used to estimate the ideal period size for a given setup.
  31. */
  32. float jack_get_max_delayed_usecs (jack_client_t *client);
  33. /**
  34. * @return the delay in microseconds due to the most recent XRUN
  35. * occurrence. This probably only makes sense when called from a @ref
  36. * JackXRunCallback defined using jack_set_xrun_callback().
  37. */
  38. float jack_get_xrun_delayed_usecs (jack_client_t *client);
  39. /**
  40. * Reset the maximum delay counter. This would be useful
  41. * to estimate the effect that a change to the configuration of a running
  42. * system (e.g. toggling kernel preemption) has on the delay
  43. * experienced by JACK, without having to restart the JACK engine.
  44. */
  45. void jack_reset_max_delayed_usecs (jack_client_t *client);
  46. #ifdef __cplusplus
  47. }
  48. #endif
  49. #endif /* __statistics_h__ */