Mercurial > hg > beaglert
diff examples/d-box/render.cpp @ 301:e4392164b458 prerelease
RENAMED BeagleRT to Bela AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA, scripts probably not working
author | Giulio Moro <giuliomoro@yahoo.it> |
---|---|
date | Fri, 27 May 2016 14:34:41 +0100 |
parents | dbeed520b014 |
children | 421a69d42943 |
line wrap: on
line diff
--- a/examples/d-box/render.cpp Fri May 27 13:58:20 2016 +0100 +++ b/examples/d-box/render.cpp Fri May 27 14:34:41 2016 +0100 @@ -5,7 +5,7 @@ * Author: Victor Zappi */ -#include <BeagleRT.h> +#include <Bela.h> #include <PRU.h> #include "StatusLED.h" @@ -153,7 +153,7 @@ uint16_t *matrixIn, uint16_t *matrixOut); #endif -bool setup(BeagleRTContext *context, void *userData) { +bool setup(BelaContext *context, void *userData) { int oscBankHopSize = *(int *)userData; if(context->analogChannels != 8) { @@ -229,15 +229,15 @@ PeakBurst[1].setSustainLevel(0.0); // Initialise auxiliary tasks - if((gMediumPriorityRender = BeagleRT_createAuxiliaryTask(&render_medium_prio, BEAGLERT_AUDIO_PRIORITY - 10, "dbox-calculation-medium")) == 0) + if((gMediumPriorityRender = Bela_createAuxiliaryTask(&render_medium_prio, BEAGLERT_AUDIO_PRIORITY - 10, "dbox-calculation-medium")) == 0) return false; - if((gLowPriorityRender = BeagleRT_createAuxiliaryTask(&render_low_prio, BEAGLERT_AUDIO_PRIORITY - 15, "dbox-calculation-low")) == 0) + if((gLowPriorityRender = Bela_createAuxiliaryTask(&render_low_prio, BEAGLERT_AUDIO_PRIORITY - 15, "dbox-calculation-low")) == 0) return false; return true; } -void render(BeagleRTContext *context, void *userData) +void render(BelaContext *context, void *userData) { #ifdef DBOX_CAPE_TEST render_capetest(numMatrixFrames, numAudioFrames, audioIn, audioOut, matrixIn, matrixOut); @@ -323,7 +323,7 @@ gOscillatorBufferReadPointer = 0; gOscillatorNeedsRender = true; - BeagleRT_scheduleAuxiliaryTask(gMediumPriorityRender); + Bela_scheduleAuxiliaryTask(gMediumPriorityRender); } } #endif @@ -418,7 +418,7 @@ gFeedbackOscillatorTableLength = tableLength; gFeedbackOscillatorTable = gFeedbackOscillator.wavetable(); gDynamicWavetableNeedsRender = true; - BeagleRT_scheduleAuxiliaryTask(gLowPriorityRender); + Bela_scheduleAuxiliaryTask(gLowPriorityRender); } /* @@ -731,7 +731,7 @@ } // Clean up at the end of render -void cleanup(BeagleRTContext *context, void *userData) +void cleanup(BelaContext *context, void *userData) { free(gOscillatorBuffer1); free(gOscillatorBuffer2);