Mercurial > hg > beaglert
comparison include/render.h @ 0:8a575ba3ab52
Initial commit.
author | andrewm |
---|---|
date | Fri, 31 Oct 2014 19:10:17 +0100 |
parents | |
children | a6beeba3a648 |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:8a575ba3ab52 |
---|---|
1 /* | |
2 * render.h | |
3 * | |
4 * Created on: May 28, 2014 | |
5 * Author: Victor Zappi | |
6 */ | |
7 | |
8 #ifndef RENDER_H_ | |
9 #define RENDER_H_ | |
10 | |
11 // uint types | |
12 #include <stdint.h> | |
13 | |
14 // Mappings from pin numbers on PCB to actual DAC channels | |
15 // This gives the DAC and ADC connectors the same effective pinout | |
16 #define DAC_PIN0 6 | |
17 #define DAC_PIN1 4 | |
18 #define DAC_PIN2 2 | |
19 #define DAC_PIN3 0 | |
20 #define DAC_PIN4 1 | |
21 #define DAC_PIN5 3 | |
22 #define DAC_PIN6 5 | |
23 #define DAC_PIN7 7 | |
24 | |
25 #define ADC_PIN0 0 | |
26 #define ADC_PIN1 1 | |
27 #define ADC_PIN2 2 | |
28 #define ADC_PIN3 3 | |
29 #define ADC_PIN4 4 | |
30 #define ADC_PIN5 5 | |
31 #define ADC_PIN6 6 | |
32 #define ADC_PIN7 7 | |
33 | |
34 #define MATRIX_MAX 65535.0 | |
35 | |
36 bool initialise_render(int numChannels, int numMatrixFramesPerPeriod, | |
37 int numAudioFramesPerPeriod, | |
38 float matrixSampleRate, float audioSampleRate, | |
39 void *userData); | |
40 | |
41 void render(int numMatrixFrames, int numAudioFrames, float *audioIn, float *audioOut, | |
42 uint16_t *matrixIn, uint16_t *matrixOut); | |
43 | |
44 void render_medium_prio(); | |
45 void render_low_prio(); | |
46 | |
47 void schedule_render_medium_prio(); | |
48 void schedule_render_low_prio(); | |
49 | |
50 | |
51 void cleanup_render(); | |
52 | |
53 #endif /* RENDER_H_ */ |