jack1 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.

31 lines
476B

  1. #include <stdio.h>
  2. #include <unistd.h>
  3. #include <jack/jack.h>
  4. int
  5. main (int argc, char *argv[])
  6. {
  7. jack_client_t *client;
  8. const char **ports;
  9. int i;
  10. /* try to become a client of the JACK server */
  11. if ((client = jack_client_new ("lsp")) == 0) {
  12. fprintf (stderr, "jack server not running?\n");
  13. return 1;
  14. }
  15. ports = jack_get_ports (client, NULL, NULL, 0);
  16. for (i = 0; ports[i]; ++i) {
  17. printf ("%s\n", ports[i]);
  18. }
  19. jack_client_close (client);
  20. exit (0);
  21. }