Skip to content

Commit

Permalink
remove OSCsendA
Browse files Browse the repository at this point in the history
  • Loading branch information
jpffitch committed Dec 17, 2017
1 parent 454cfdd commit 63b19f6
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions Opcodes/OSC.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,25 +380,25 @@ uintptr_t OSCthread(void *pp) {
return 0;
}

static int osc_send_async_set(CSOUND *csound, OSCSEND *p) {
p->csound = csound;
return osc_send_set(csound, p);
}

static int osc_send_async(CSOUND *csound, OSCSEND *p) {
/*RTCLOCK t;
csound->InitTimerStruct(&t);*/
if (*p->kwhen != p->lasta) {
if (p->thread != NULL) {
csound->JoinThread(p->thread);
p->thread = NULL;
}
p->thread = csound->CreateThread(OSCthread, p);
p->lasta = *p->kwhen;
}
// printf("wait: %.13f \n", (csound->GetRealTime(&t))*1000.);
return OK;
}
/* static int osc_send_async_set(CSOUND *csound, OSCSEND *p) { */
/* p->csound = csound; */
/* return osc_send_set(csound, p); */
/* } */

/* static int osc_send_async(CSOUND *csound, OSCSEND *p) { */
/* /\*RTCLOCK t; */
/* csound->InitTimerStruct(&t);*\/ */
/* if (*p->kwhen != p->lasta) { */
/* if (p->thread != NULL) { */
/* csound->JoinThread(p->thread); */
/* p->thread = NULL; */
/* } */
/* p->thread = csound->CreateThread(OSCthread, p); */
/* p->lasta = *p->kwhen; */
/* } */
/* // printf("wait: %.13f \n", (csound->GetRealTime(&t))*1000.); */
/* return OK; */
/* } */


/* get pointer to globals structure, allocating it on the first call */
Expand Down Expand Up @@ -920,8 +920,8 @@ static OENTRY localops[] = {
(SUBR)OSC_list_init, (SUBR)OSC_list, NULL, NULL },
{ "OSClisten", S(OSCLISTEN),0, 3, "k", "iSS",
(SUBR)OSC_list_init, (SUBR)OSC_list, NULL, NULL },
{ "OSCsendA", S(OSCSEND), _QQ, 3, "", "kSkSS*",
(SUBR)osc_send_async_set, (SUBR)osc_send_async, NULL, NULL }
/* { "OSCsendA", S(OSCSEND), _QQ, 3, "", "kSkSS*", */
/* (SUBR)osc_send_async_set, (SUBR)osc_send_async, NULL, NULL } */
};

PUBLIC long csound_opcode_init(CSOUND *csound, OENTRY **ep)
Expand Down

0 comments on commit 63b19f6

Please sign in to comment.