Sigrid Solveig Haflínudóttircompile stuff50243ce5 years agoHistory
49 lines · 996 B · C
RawDownload
/* this file is placed in the public domain */ #include <stdlib.h>#include <math.h>#include <stdint.h>#define SK_RLINE_PRIV#include "tangled/rline.h"#include "soundpipe.h" int sp_rline_create(sp_rline **p){    *p = malloc(sizeof(sp_rline));    return SP_OK;} int sp_rline_destroy(sp_rline **p){    sp_rline *pp;    pp = *p;    free(pp->rline);    free(*p);    return SP_OK;} int sp_rline_init(sp_data *sp, sp_rline *p){    p->rline = malloc(sizeof(sk_rline));    sk_rline_init(p->rline, sp->sr, sp_rand(sp));    p->min = 0;    p->max = 1;    p->cps = 3;     sk_rline_min(p->rline, p->min);    sk_rline_max(p->rline, p->max);    sk_rline_rate(p->rline, p->cps);    return SP_OK;} int sp_rline_compute(sp_data *sp, sp_rline *p,                         SPFLOAT *in, SPFLOAT *out){    USED(sp, in);     sk_rline_min(p->rline, p->min);    sk_rline_max(p->rline, p->max);    sk_rline_rate(p->rline, p->cps);    *out = sk_rline_tick(p->rline);    return SP_OK;}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t