-ve reward decay
This commit is contained in:
parent
96cd070bc6
commit
1adff3b18b
3 changed files with 20 additions and 4 deletions
|
|
@ -26,7 +26,7 @@ public:
|
||||||
static constexpr size_t kN_Params = NPARAMS;
|
static constexpr size_t kN_Params = NPARAMS;
|
||||||
static constexpr size_t nFREQs = 17;
|
static constexpr size_t nFREQs = 17;
|
||||||
static constexpr float frequencies[nFREQs] = {100, 200, 400,800, 400, 800, 100,1600,100,400,100,50,1600,200,100,800,400};
|
static constexpr float frequencies[nFREQs] = {100, 200, 400,800, 400, 800, 100,1600,100,400,100,50,1600,200,100,800,400};
|
||||||
|
static constexpr size_t nVoiceSpaces=5;
|
||||||
|
|
||||||
using VoiceSpaceFn = std::function<void(const std::array<float, NPARAMS>&)>;
|
using VoiceSpaceFn = std::function<void(const std::array<float, NPARAMS>&)>;
|
||||||
struct VoiceSpace {
|
struct VoiceSpace {
|
||||||
|
|
@ -34,10 +34,24 @@ public:
|
||||||
VoiceSpaceFn mappingFunction = nullptr;
|
VoiceSpaceFn mappingFunction = nullptr;
|
||||||
};
|
};
|
||||||
|
|
||||||
std::array<VoiceSpace, 5> voiceSpaces;
|
std::array<VoiceSpace, nVoiceSpaces> voiceSpaces;
|
||||||
|
|
||||||
VoiceSpaceFn currentVoiceSpace;
|
VoiceSpaceFn currentVoiceSpace;
|
||||||
|
|
||||||
|
std::array<String, nVoiceSpaces> getVoiceSpaceNames() {
|
||||||
|
std::array<String, nVoiceSpaces> names;
|
||||||
|
for(size_t i=0; i < voiceSpaces.size(); i++) {
|
||||||
|
names[i] = voiceSpaces[i].name;
|
||||||
|
}
|
||||||
|
return names;
|
||||||
|
}
|
||||||
|
|
||||||
|
void setVoiceSpace(size_t i) {
|
||||||
|
if (i < voiceSpaces.size()) {
|
||||||
|
currentVoiceSpace = voiceSpaces[i];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
PAFSynthAudioApp() : AudioAppBase<NPARAMS>() {
|
PAFSynthAudioApp() : AudioAppBase<NPARAMS>() {
|
||||||
#if 1
|
#if 1
|
||||||
auto voiceSpace1 = [this](const std::array<float, NPARAMS>& params) {
|
auto voiceSpace1 = [this](const std::array<float, NPARAMS>& params) {
|
||||||
|
|
@ -491,6 +505,8 @@ public:
|
||||||
|
|
||||||
queue_t qMIDINoteOn, qMIDINoteOff;
|
queue_t qMIDINoteOn, qMIDINoteOff;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
maxiPAFOperator paf0;
|
maxiPAFOperator paf0;
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit fdce0a0335a2d29dd3089784450d44318a9ed989
|
Subproject commit 7e228dcee5f13ea5c8f1a13e7b0e68827ba77af6
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit dad7485a1c1b690e806ec917f7c75061baa4ad2b
|
Subproject commit a906e6caf394fa08c6a7442fc0132399c3d28e8b
|
||||||
Loading…
Reference in a new issue