12-command-art #2

Merged
boomjacky merged 17 commits from 12-command-art into master 2026-05-10 06:42:12 -04:00
2 changed files with 6 additions and 4 deletions
Showing only changes of commit f7f18f9fa7 - Show all commits

View File

@@ -83,8 +83,7 @@ int process_callback(jack_nframes_t nframes, void *arg) {
const float *f_in = (const float *)in;
for (i = 0; i < nframes; i++) {
if (channels[c].record_pos < LOOP_BUF_SIZE)
channels[c].loop_buffer[channels[c].record_pos++] =
f_in[i];
channels[c].loop_buffer[channels[c].record_pos++] = f_in[i];
f_out[i] = f_in[i];
}
} else {

View File

@@ -3,8 +3,8 @@
#include <jack/jack.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <time.h>
#include <unistd.h>
int main(int argc, char *argv[]) {
(void)argc;
@@ -43,7 +43,10 @@ int main(int argc, char *argv[]) {
while (1) {
looper_process_commands(client);
{ struct timespec ts = { .tv_sec = 0, .tv_nsec = 50000000 }; nanosleep(&ts, NULL); } /* check commands every 50 ms */
{
struct timespec ts = {.tv_sec = 0, .tv_nsec = 50000000};
nanosleep(&ts, NULL);
} /* check commands every 50 ms */
}
jack_client_close(client);