fixing bugs in menu but still no sound

pull/495/head
Vincent GAUCHE 2 years ago
parent 9fd908b84d
commit fdd84b1d6d
  1. 55
      .vscode/c_cpp_properties.json
  2. 8
      .vscode/settings.json
  3. 2
      circle-stdlib
  4. 8
      src/fx_components.cpp
  5. 1
      src/fx_components.h
  6. 8
      src/kernel.cpp
  7. 1048
      src/minidexed.cpp
  8. 61
      src/minidexed.h
  9. 65
      src/mixing_console.hpp
  10. 224
      src/performance.ini
  11. 120
      src/performanceconfig.cpp
  12. 25
      src/performanceconfig.h
  13. 15
      src/test/test_fx_mixing_console.cpp
  14. 13
      src/test/test_fx_mixing_console_unitary.cpp
  15. 638
      src/uimenu.cpp
  16. 5
      src/uimenu.h
  17. 66
      src/userinterface.cpp
  18. 21
      src/userinterface.h

@ -1,56 +1,27 @@
{
"configurations": [
{
"name": "Win64",
"name": "Win32",
"includePath": [
"d:\\Documents\\dev\\OpenSource\\MiniDexed-fx2/CMSIS_5/CMSIS/Core/Include/",
"d:\\Documents\\dev\\OpenSource\\MiniDexed-fx2/CMSIS_5/CMSIS/DSP/Include/",
"d:\\Documents\\dev\\OpenSource\\MiniDexed-fx2/circle-stdlib/libs/circle/include",
"d:\\Documents\\dev\\OpenSource\\MiniDexed-fx2/circle-stdlib/libs/circle/addon"
"${workspaceFolder}/src/**",
"${workspaceFolder}/CMSIS_5/CMSIS/Core/Include/**",
"${workspaceFolder}/CMSIS_5/CMSIS/DSP/Include/**",
"${workspaceFolder}/circle-stdlib/include/**",
"${workspaceFolder}/circle-stdlib/libs/circle-newlib/include/**",
"${workspaceFolder}/circle-stdlib/libs/circle/include/**"
],
"defines": [
"ARM_ALLOW_MULTI_CORE",
"_DEBUG",
"UNICODE",
"_UNICODE",
"RPI=4",
"RASPPI=4",
"DEBUG"
"ARM_ALLOW_MULTI_CORE"
],
"intelliSenseMode": "msvc-x64",
"windowsSdkVersion": "10.0.19041.0",
"compilerPath": "cl.exe",
"cStandard": "c17",
"cppStandard": "c++20",
"configurationProvider": "ms-vscode.makefile-tools",
"rawCompilerPath": "cl.exe",
"mergeConfigurations": false,
"browse": {
"path": [
"${workspaceFolder}/CMSIS_5/CMSIS/Core/Include/",
"${workspaceFolder}/CMSIS_5/CMSIS/DSP/Include/",
"${workspaceFolder}/circle-stdlib/libs/circle/include",
"${workspaceFolder}/circle-stdlib/libs/circle/addon",
"${workspaceFolder}/src",
"${workspaceFolder}"
],
"limitSymbolsToIncludedHeaders": true
}
},
{
"name": "Linux",
"includePath": [
"${workspaceFolder}/CMSIS_5/CMSIS/Core/Include/",
"${workspaceFolder}/CMSIS_5/CMSIS/DSP/Include/",
"${workspaceFolder}/circle-stdlib/libs/circle/include",
"${workspaceFolder}/circle-stdlib/libs/circle/addon"
],
"defines": [
"ARM_ALLOW_MULTI_CORE",
"RPI=4",
"RASPPI=4",
"DEBUG"
],
"intelliSenseMode": "windows-gcc-arm64",
"compilerPath": "/usr/bin/g++",
"cStandard": "c17",
"cppStandard": "c++20",
"intelliSenseMode": "windows-msvc-x64",
"configurationProvider": "ms-vscode.makefile-tools"
}
],

@ -76,7 +76,13 @@
"thread": "cpp",
"cfenv": "cpp",
"variant": "cpp",
"semaphore": "cpp"
"semaphore": "cpp",
"forward_list": "cpp",
"slist": "cpp",
"span": "cpp",
"regex": "cpp",
"valarray": "cpp",
"shared_mutex": "cpp"
},
"C_Cpp.errorSquiggles": "disabled",
"C_Cpp.intelliSenseEngine": "Tag Parser",

@ -1 +1 @@
Subproject commit 61cf3a47bf93628039078b7c840e44432e52343e
Subproject commit e318f89932518e68b7e8fb4d55cdcd20d228f934

@ -276,6 +276,9 @@ float32_t InterpolatedSineOscillator::Sin(float32_t phase)
initialized = InterpolatedSineOscillator::ClassInitializer();
}
if(phase < 0.0f) while(phase < 0.0f) phase += Constants::M2PI;
else while(phase > Constants::M2PI) phase -= Constants::M2PI;
float32_t findex = phase / InterpolatedSineOscillator::DeltaTime;
size_t index1 = static_cast<size_t>(findex);
@ -288,6 +291,11 @@ float32_t InterpolatedSineOscillator::Sin(float32_t phase)
return f1 + (f2 - f1) * r * InterpolatedSineOscillator::DeltaTime;
}
float32_t InterpolatedSineOscillator::Cos(float32_t phase)
{
return InterpolatedSineOscillator::Sin(Constants::MPI_2 - phase);
}
bool InterpolatedSineOscillator::ClassInitializer()
{
static bool initialized = false;

@ -232,6 +232,7 @@ class InterpolatedSineOscillator : public FXBase
public:
static float32_t Sin(float32_t phase);
static float32_t Cos(float32_t phase);
InterpolatedSineOscillator(float32_t sampling_rate, float32_t min_frequency = LFO_MIN_FREQUENCY, float32_t max_frequency = LFO_MAX_FREQUENCY, float32_t initial_phase = 0.0f, bool centered = true);
virtual ~InterpolatedSineOscillator();

@ -64,8 +64,12 @@ bool CKernel::Initialize (void)
m_Config.Load ();
m_pDexed = new CMiniDexed (&m_Config, &mInterrupt, &m_GPIOManager, &m_I2CMaster,
&mFileSystem);
m_pDexed = new CMiniDexed (
&m_Config,
&mInterrupt,
&m_GPIOManager,
&m_I2CMaster,
&mFileSystem);
assert (m_pDexed);
if (!m_pDexed->Initialize ())

File diff suppressed because it is too large Load Diff

@ -57,8 +57,13 @@ class CMiniDexed
#endif
{
public:
CMiniDexed (CConfig *pConfig, CInterruptSystem *pInterrupt,
CGPIOManager *pGPIOManager, CI2CMaster *pI2CMaster, FATFS *pFileSystem);
CMiniDexed(
CConfig *pConfig,
CInterruptSystem *pInterrupt,
CGPIOManager *pGPIOManager,
CI2CMaster *pI2CMaster,
FATFS *pFileSystem
);
bool Initialize (void);
@ -94,6 +99,7 @@ public:
void setAftertouch (uint8_t value, unsigned nTG);
#if defined(MIXING_CONSOLE_ENABLE)
unsigned getMixingConsoleSendLevel(unsigned nTG, MixerOutput fx) const;
void setMixingConsoleSendLevel(unsigned nTG, MixerOutput fx, unsigned nFXSend);
void setMixingConsoleReturnLevel(MixerOutput ret, MixerOutput fx, unsigned nFXReturn);
#elif defined(PLATE_REVERB_ENABLE)
@ -151,8 +157,8 @@ public:
ParameterReverbLevel,
#endif
#ifdef MIXING_CONSOLE_ENABLE
// BEGIN FX global parameters definition
// BEGIN FX global parameters definition
#if defined(MIXING_CONSOLE_ENABLE)
// Tube parameters
ParameterFXTubeEnable,
@ -202,7 +208,7 @@ public:
ParameterFXTube_OrbitoneReturn,
ParameterFXTube_PhaserReturn,
ParameterFXTube_DelayReturn,
ParameterFXTube_ReverbReturn,
ParameterFXTube_PlateReverbReturn,
ParameterFXTube_ReverberatorReturn,
ParameterFXTube_MainOutput,
@ -212,7 +218,7 @@ public:
ParameterFXChorus_OrbitoneReturn,
ParameterFXChorus_PhaserReturn,
ParameterFXChorus_DelayReturn,
ParameterFXChorus_ReverbReturn,
ParameterFXChorus_PlateReverbReturn,
ParameterFXChorus_ReverberatorReturn,
ParameterFXChorus_MainOutput,
@ -222,7 +228,7 @@ public:
ParameterFXFlanger_OrbitoneReturn,
ParameterFXFlanger_PhaserReturn,
ParameterFXFlanger_DelayReturn,
ParameterFXFlanger_ReverbReturn,
ParameterFXFlanger_PlateReverbReturn,
ParameterFXFlanger_ReverberatorReturn,
ParameterFXFlanger_MainOutput,
@ -232,7 +238,7 @@ public:
ParameterFXOrbitone_FlangerReturn,
ParameterFXOrbitone_PhaserReturn,
ParameterFXOrbitone_DelayReturn,
ParameterFXOrbitone_ReverbReturn,
ParameterFXOrbitone_PlateReverbReturn,
ParameterFXOrbitone_ReverberatorReturn,
ParameterFXOrbitone_MainOutput,
@ -242,7 +248,7 @@ public:
ParameterFXPhaser_FlangerReturn,
ParameterFXPhaser_OrbitoneReturn,
ParameterFXPhaser_DelayReturn,
ParameterFXPhaser_ReverbReturn,
ParameterFXPhaser_PlateReverbReturn,
ParameterFXPhaser_ReverberatorReturn,
ParameterFXPhaser_MainOutput,
@ -252,19 +258,19 @@ public:
ParameterFXDelay_FlangerReturn,
ParameterFXDelay_OrbitoneReturn,
ParameterFXDelay_PhaserReturn,
ParameterFXDelay_ReverbReturn,
ParameterFXDelay_PlateReverbReturn,
ParameterFXDelay_ReverberatorReturn,
ParameterFXDelay_MainOutput,
// Reverb Return parameters
ParameterFXReverb_TubeReturn,
ParameterFXReverb_ChorusReturn,
ParameterFXReverb_FlangerReturn,
ParameterFXReverb_OrbitoneReturn,
ParameterFXReverb_PhaserReturn,
ParameterFXReverb_DelayReturn,
ParameterFXReverb_ReverberatorReturn,
ParameterFXReverb_MainOutput,
// Plate Reverb Return parameters
ParameterFXPlateReverb_TubeReturn,
ParameterFXPlateReverb_ChorusReturn,
ParameterFXPlateReverb_FlangerReturn,
ParameterFXPlateReverb_OrbitoneReturn,
ParameterFXPlateReverb_PhaserReturn,
ParameterFXPlateReverb_DelayReturn,
ParameterFXPlateReverb_ReverberatorReturn,
ParameterFXPlateReverb_MainOutput,
// Reverberator Return parameters
ParameterFXReverberator_TubeReturn,
@ -273,11 +279,11 @@ public:
ParameterFXReverberator_OrbitoneReturn,
ParameterFXReverberator_PhaserReturn,
ParameterFXReverberator_DelayReturn,
ParameterFXReverberator_ReverbReturn,
ParameterFXReverberator_PlateReverbReturn,
ParameterFXReverberator_MainOutput,
// END FX global parameters definition
#endif
// END FX global parameters definition
ParameterUnknown
};
@ -301,7 +307,7 @@ public:
TGParameterCutoff,
TGParameterResonance,
TGParameterMIDIChannel,
#ifdef PLATE_REVERB_ENABLE
#if defined(PLATE_REVERB_ENABLE)
TGParameterReverbSend,
#endif
TGParameterPitchBendRange,
@ -331,7 +337,7 @@ public:
TGParameterATAmplitude,
TGParameterATEGBias,
#ifdef MIXING_CONSOLE_ENABLE
#if defined(MIXING_CONSOLE_ENABLE)
TGParameterMixingSendFXTube,
TGParameterMixingSendFXChorus,
TGParameterMixingSendFXFlanger,
@ -415,8 +421,7 @@ private:
#ifdef MIXING_CONSOLE_ENABLE
unsigned m_nFXSendLevel[CConfig::ToneGenerators][MixerOutput::kFXCount];
unsigned m_nFXReturnLevel[MixerOutput::kFXCount - 1][MixerOutput::kFXCount];
#else
#elif defined(PLATE_REVERB_ENABLE)
unsigned m_nReverbSend[CConfig::ToneGenerators];
#endif
@ -448,11 +453,9 @@ private:
CPerformanceTimer m_GetChunkTimer;
bool m_bProfileEnabled;
#ifdef MIXING_CONSOLE_ENABLE
#if defined(MIXING_CONSOLE_ENABLE)
Mixer* mixing_console_;
#endif
#ifdef PLATE_REVERB_ENABLE
#elif defined(PLATE_REVERB_ENABLE)
AudioEffectPlateReverb* reverb;
AudioStereoMixer<CConfig::ToneGenerators>* tg_mixer;
AudioStereoMixer<CConfig::ToneGenerators>* reverb_send_mixer;

@ -49,6 +49,7 @@ public:
inline void setInputSample(size_t in, float32_t sampleL, float32_t sampleR);
inline void setInputSampleBuffer(size_t in, float32_t* samples);
inline void setInputSampleBuffer(size_t in, float32_t* samplesL, float32_t* samplesR);
inline void preProcessInputSampleBuffer(size_t in);
// Return section
inline void setReturnLevel(MixerOutput ret, MixerOutput dest, float32_t lvl);
@ -82,6 +83,7 @@ private:
float32_t channel_level_[nb_inputs];
float32_t pan_[StereoChannels::kNumChannels + 1][nb_inputs];
float32_t* tg_input_sample_buffer_[nb_inputs];
float32_t* input_sample_buffer_[StereoChannels::kNumChannels][nb_inputs];
float32_t input_samples_[StereoChannels::kNumChannels][nb_inputs + MixerOutput::kFXCount - 1];
float32_t levels_[MixerOutput::kFXCount][nb_inputs + MixerOutput::kFXCount - 1];
@ -319,6 +321,7 @@ MixingConsole<nb_inputs>::MixingConsole(float32_t sampling_rate, size_t buffer_s
{
for(size_t i = 0; i < nb_inputs; ++i)
{
this->tg_input_sample_buffer_[i] = nullptr;
this->input_sample_buffer_[StereoChannels::Left ][i] = new float32_t[this->BufferSize];
this->input_sample_buffer_[StereoChannels::Right][i] = new float32_t[this->BufferSize];
memset(this->input_sample_buffer_[StereoChannels::Left ][i], 0, sizeof(float32_t) * this->BufferSize);
@ -350,6 +353,7 @@ MixingConsole<nb_inputs>::~MixingConsole()
{
delete[] this->input_sample_buffer_[StereoChannels::Left ][i];
delete[] this->input_sample_buffer_[StereoChannels::Right][i];
this->tg_input_sample_buffer_[i] = nullptr;
}
}
@ -401,21 +405,13 @@ void MixingConsole<nb_inputs>::setInputSampleBuffer(size_t in, float32_t* sample
{
assert(in < nb_inputs);
if(samples != nullptr)
{
arm_scale_f32(samples, this->pan_[StereoChannels::Left ][in], this->input_sample_buffer_[StereoChannels::Left ][in], this->BufferSize);
arm_scale_f32(samples, this->pan_[StereoChannels::Right][in], this->input_sample_buffer_[StereoChannels::Right][in], this->BufferSize);
}
else
{
memset(this->input_sample_buffer_[StereoChannels::Left ][in], 0, this->BufferSize * sizeof(float32_t));
memset(this->input_sample_buffer_[StereoChannels::Right][in], 0, this->BufferSize * sizeof(float32_t));
}
this->tg_input_sample_buffer_[in] = samples;
}
template<size_t nb_inputs>
void MixingConsole<nb_inputs>::setInputSampleBuffer(size_t in, float32_t* samplesL, float32_t* samplesR)
{
// Only used to input stereo samples
assert(in < nb_inputs);
if(samplesL != nullptr)
{
@ -436,6 +432,39 @@ void MixingConsole<nb_inputs>::setInputSampleBuffer(size_t in, float32_t* sample
}
}
template<size_t nb_inputs>
void MixingConsole<nb_inputs>::preProcessInputSampleBuffer(size_t in)
{
assert(in < nb_inputs);
float32_t* samples = this->tg_input_sample_buffer_[in];
if(samples != nullptr)
{
if(this->pan_[StereoChannels::Left ][in] != 0.0f)
{
arm_scale_f32(samples, this->pan_[StereoChannels::Left ][in], this->input_sample_buffer_[StereoChannels::Left ][in], this->BufferSize);
}
else
{
memset(this->input_sample_buffer_[StereoChannels::Left ][in], 0, this->BufferSize * sizeof(float32_t));
}
if(this->pan_[StereoChannels::Right][in] != 0.0f)
{
arm_scale_f32(samples, this->pan_[StereoChannels::Right][in], this->input_sample_buffer_[StereoChannels::Right][in], this->BufferSize);
}
else
{
memset(this->input_sample_buffer_[StereoChannels::Right][in], 0, this->BufferSize * sizeof(float32_t));
}
}
else
{
memset(this->input_sample_buffer_[StereoChannels::Left ][in], 0, this->BufferSize * sizeof(float32_t));
memset(this->input_sample_buffer_[StereoChannels::Right][in], 0, this->BufferSize * sizeof(float32_t));
}
}
// Return section
template<size_t nb_inputs>
void MixingConsole<nb_inputs>::setReturnLevel(MixerOutput ret, MixerOutput dest, float32_t lvl)
@ -618,9 +647,19 @@ void MixingConsole<nb_inputs>::process(float32_t* outL, float32_t* outR)
template<size_t nb_inputs>
void MixingConsole<nb_inputs>::updatePan(size_t in)
{
float32_t pan = mapfloat(this->pan_[StereoChannels::kNumChannels][in], 0.0f, 1.0f, 0.0, Constants::MPI_2);
this->pan_[StereoChannels::Left ][in] = arm_cos_f32(pan) * this->channel_level_[in];
this->pan_[StereoChannels::Right][in] = arm_sin_f32(pan) * this->channel_level_[in];
float32_t pan = this->pan_[StereoChannels::kNumChannels][in] * Constants::MPI_2;
if(this->channel_level_[in] != 0.0f)
{
// this->pan_[StereoChannels::Left ][in] = arm_cos_f32(pan) * this->channel_level_[in];
// this->pan_[StereoChannels::Right][in] = arm_sin_f32(pan) * this->channel_level_[in];
this->pan_[StereoChannels::Left ][in] = InterpolatedSineOscillator::Cos(pan) * this->channel_level_[in];
this->pan_[StereoChannels::Right][in] = InterpolatedSineOscillator::Sin(pan) * this->channel_level_[in];
}
else
{
this->pan_[StereoChannels::Left ][in] =
this->pan_[StereoChannels::Right][in] = 0.0f;
}
}
template<size_t nb_inputs>

@ -275,6 +275,7 @@ AftertouchTarget8=0
# Effects
CompressorEnable=1
ReverbEnable=1
ReverbSize=70
ReverbHighDamp=50
@ -283,39 +284,190 @@ ReverbLowPass=30
ReverbDiffusion=65
ReverbLevel=99
# FXRack
FXChainEnable=1
FXChainWet=99
FXChainTubeEnable=0
FXChainTubeWet=50
FXChainTubeOverdrive=10
FXChainChorusEnable=0
FXChainChorusWet=50
FXChainChorusRate=40
FXChainChorusDepth=50
FXChainFlangerEnable=0
FXChainFlangerWet=50
FXChainFlangerRate=3
FXChainFlangerDepth=75
FXChainFlangerFeedback=50
FXChainOrbitoneEnable=0
FXChainOrbitoneWet=80
FXChainOrbitoneRate=40
FXChainOrbitoneDepth=50
FXChainPhaserEnable=0
FXChainPhaserWet=50
FXChainPhaserRate=5
FXChainPhaserDepth=99
FXChainPhaserFeedback=70
FXChainPhaserNbStages=12
FXChainDelayEnable=0
FXChainDelayWet=50
FXChainDelayLeftDelayTime=15
FXChainDelayRightDelayTime=22
FXChainDelayFeedback=35
FXChainReverberatorEnable=1
FXChainReverberatorWet=70
FXChainReverberatorInputGain=55
FXChainReverberatorTime=75
FXChainReverberatorDiffusion=75
FXChainReverberatorLP=80
# Mixing Console
FXTubeEnable=1
FXTubeOverdrive=10
FXChorusEnable=1
FXChorusRate=40
FXChorusDepth=50
FXFlangerEnable=1
FXFlangerRate=3
FXFlangerDepth=75
FXFlangerFeedback=50
FXOrbitoneEnable=1
FXOrbitoneRate=40
FXOrbitoneDepth=50
FXPhaserEnable=1
FXPhaserRate=5
FXPhaserDepth=99
FXPhaserFeedback=70
FXPhaserNbStages=12
FXDelayEnable=1
FXDelayLeftDelayTime=15
FXDelayRightDelayTime=22
FXDelayFeedback=35
FXDelayFlutterRate=0
FXDelayFlutterAmount=0
FXReverberatorEnable=1
FXReverberatorInputGain=55
FXReverberatorTime=75
FXReverberatorDiffusion=75
FXReverberatorLP=80
FXSendLevel_0_x_Tube=0
FXSendLevel_0_x_Chorus=0
FXSendLevel_0_x_Flanger=0
FXSendLevel_0_x_Orbitone=0
FXSendLevel_0_x_Phaser=0
FXSendLevel_0_x_Delay=0
FXSendLevel_0_x_PlateReverb=0
FXSendLevel_0_x_Reverberator=0
FXSendLevel_0_x_MainOutput=0
FXSendLevel_1_x_Tube=0
FXSendLevel_1_x_Chorus=0
FXSendLevel_1_x_Flanger=0
FXSendLevel_1_x_Orbitone=0
FXSendLevel_1_x_Phaser=0
FXSendLevel_1_x_Delay=0
FXSendLevel_1_x_PlateReverb=0
FXSendLevel_1_x_Reverberator=0
FXSendLevel_1_x_MainOutput=0
FXSendLevel_2_x_Tube=0
FXSendLevel_2_x_Chorus=0
FXSendLevel_2_x_Flanger=0
FXSendLevel_2_x_Orbitone=0
FXSendLevel_2_x_Phaser=0
FXSendLevel_2_x_Delay=0
FXSendLevel_2_x_PlateReverb=0
FXSendLevel_2_x_Reverberator=0
FXSendLevel_2_x_MainOutput=0
FXSendLevel_3_x_Tube=0
FXSendLevel_3_x_Chorus=0
FXSendLevel_3_x_Flanger=0
FXSendLevel_3_x_Orbitone=0
FXSendLevel_3_x_Phaser=0
FXSendLevel_3_x_Delay=0
FXSendLevel_3_x_PlateReverb=0
FXSendLevel_3_x_Reverberator=0
FXSendLevel_3_x_MainOutput=0
FXSendLevel_4_x_Tube=0
FXSendLevel_4_x_Chorus=0
FXSendLevel_4_x_Flanger=0
FXSendLevel_4_x_Orbitone=0
FXSendLevel_4_x_Phaser=0
FXSendLevel_4_x_Delay=0
FXSendLevel_4_x_PlateReverb=0
FXSendLevel_4_x_Reverberator=0
FXSendLevel_4_x_MainOutput=0
FXSendLevel_5_x_Tube=0
FXSendLevel_5_x_Chorus=0
FXSendLevel_5_x_Flanger=0
FXSendLevel_5_x_Orbitone=0
FXSendLevel_5_x_Phaser=0
FXSendLevel_5_x_Delay=0
FXSendLevel_5_x_PlateReverb=0
FXSendLevel_5_x_Reverberator=0
FXSendLevel_5_x_MainOutput=0
FXSendLevel_6_x_Tube=0
FXSendLevel_6_x_Chorus=0
FXSendLevel_6_x_Flanger=0
FXSendLevel_6_x_Orbitone=0
FXSendLevel_6_x_Phaser=0
FXSendLevel_6_x_Delay=0
FXSendLevel_6_x_PlateReverb=0
FXSendLevel_6_x_Reverberator=0
FXSendLevel_6_x_MainOutput=0
FXSendLevel_7_x_Tube=0
FXSendLevel_7_x_Chorus=0
FXSendLevel_7_x_Flanger=0
FXSendLevel_7_x_Orbitone=0
FXSendLevel_7_x_Phaser=0
FXSendLevel_7_x_Delay=0
FXSendLevel_7_x_PlateReverb=0
FXSendLevel_7_x_Reverberator=0
FXSendLevel_7_x_MainOutput=0
FXReturnLevel_Tube_x_Chorus=0
FXReturnLevel_Tube_x_Flanger=0
FXReturnLevel_Tube_x_Orbitone=0
FXReturnLevel_Tube_x_Phaser=0
FXReturnLevel_Tube_x_Delay=0
FXReturnLevel_Tube_x_PlateReverb=0
FXReturnLevel_Tube_x_Reverberator=0
FXReturnLevel_Tube_x_MainOutput=0
FXReturnLevel_Chorus_x_Tube=0
FXReturnLevel_Chorus_x_Flanger=0
FXReturnLevel_Chorus_x_Orbitone=0
FXReturnLevel_Chorus_x_Phaser=0
FXReturnLevel_Chorus_x_Delay=0
FXReturnLevel_Chorus_x_PlateReverb=0
FXReturnLevel_Chorus_x_Reverberator=0
FXReturnLevel_Chorus_x_MainOutput=0
FXReturnLevel_Flanger_x_Tube=0
FXReturnLevel_Flanger_x_Chorus=0
FXReturnLevel_Flanger_x_Orbitone=0
FXReturnLevel_Flanger_x_Phaser=0
FXReturnLevel_Flanger_x_Delay=0
FXReturnLevel_Flanger_x_PlateReverb=0
FXReturnLevel_Flanger_x_Reverberator=0
FXReturnLevel_Flanger_x_MainOutput=0
FXReturnLevel_Orbitone_x_Tube=0
FXReturnLevel_Orbitone_x_Chorus=0
FXReturnLevel_Orbitone_x_Flanger=0
FXReturnLevel_Orbitone_x_Phaser=0
FXReturnLevel_Orbitone_x_Delay=0
FXReturnLevel_Orbitone_x_PlateReverb=0
FXReturnLevel_Orbitone_x_Reverberator=0
FXReturnLevel_Orbitone_x_MainOutput=0
FXReturnLevel_Phaser_x_Tube=0
FXReturnLevel_Phaser_x_Chorus=0
FXReturnLevel_Phaser_x_Flanger=0
FXReturnLevel_Phaser_x_Orbitone=0
FXReturnLevel_Phaser_x_Delay=0
FXReturnLevel_Phaser_x_PlateReverb=0
FXReturnLevel_Phaser_x_Reverberator=0
FXReturnLevel_Phaser_x_MainOutput=0
FXReturnLevel_Delay_x_Tube=0
FXReturnLevel_Delay_x_Chorus=0
FXReturnLevel_Delay_x_Flanger=0
FXReturnLevel_Delay_x_Orbitone=0
FXReturnLevel_Delay_x_Phaser=0
FXReturnLevel_Delay_x_PlateReverb=0
FXReturnLevel_Delay_x_Reverberator=0
FXReturnLevel_Delay_x_MainOutput=0
FXReturnLevel_PlateReverb_x_Tube=0
FXReturnLevel_PlateReverb_x_Chorus=0
FXReturnLevel_PlateReverb_x_Flanger=0
FXReturnLevel_PlateReverb_x_Orbitone=0
FXReturnLevel_PlateReverb_x_Phaser=0
FXReturnLevel_PlateReverb_x_Delay=0
FXReturnLevel_PlateReverb_x_Reverberator=0
FXReturnLevel_PlateReverb_x_MainOutput=0
FXReturnLevel_Reverberator_x_Tube=0
FXReturnLevel_Reverberator_x_Chorus=0
FXReturnLevel_Reverberator_x_Flanger=0
FXReturnLevel_Reverberator_x_Orbitone=0
FXReturnLevel_Reverberator_x_Phaser=0
FXReturnLevel_Reverberator_x_Delay=0
FXReturnLevel_Reverberator_x_PlateReverb=0
FXReturnLevel_Reverberator_x_MainOutput=0

@ -152,36 +152,46 @@ bool CPerformanceConfig::Load (void)
m_bCompressorEnable = m_Properties.GetNumber ("CompressorEnable", 1) != 0;
m_bReverbEnable = m_Properties.GetNumber ("ReverbEnable", 1) != 0;
m_nReverbSize = m_Properties.GetNumber ("ReverbSize", 70);
m_nReverbHighDamp = m_Properties.GetNumber ("ReverbHighDamp", 50);
m_nReverbLowDamp = m_Properties.GetNumber ("ReverbLowDamp", 50);
m_nReverbLowPass = m_Properties.GetNumber ("ReverbLowPass", 30);
m_nReverbDiffusion = m_Properties.GetNumber ("ReverbDiffusion", 65);
m_nReverbLevel = m_Properties.GetNumber ("ReverbLevel", 99);
#if defined(PLATE_REVERB_ENABLE) || defined(MIXING_CONSOLE_ENABLE)
this->m_bReverbEnable = this->m_Properties.GetNumber ("ReverbEnable", 1) != 0;
this->m_nReverbSize = this->m_Properties.GetNumber ("ReverbSize", 70);
this->m_nReverbHighDamp = this->m_Properties.GetNumber ("ReverbHighDamp", 50);
this->m_nReverbLowDamp = this->m_Properties.GetNumber ("ReverbLowDamp", 50);
this->m_nReverbLowPass = this->m_Properties.GetNumber ("ReverbLowPass", 30);
this->m_nReverbDiffusion = this->m_Properties.GetNumber ("ReverbDiffusion", 65);
this->m_nReverbLevel = this->m_Properties.GetNumber ("ReverbLevel", 99);
#endif
#ifdef MIXING_CONSOLE_ENABLE
#if defined(MIXING_CONSOLE_ENABLE)
this->m_bFXTubeEnable = this->m_Properties.GetNumber("FXTubeEnable", 1);
this->m_nFXTubeOverdrive = this->m_Properties.GetNumber("FXTubeOverdrive", 10);
this->m_bFXChorusEnable = this->m_Properties.GetNumber("FXChorusEnable", 1);
this->m_nFXChorusRate = this->m_Properties.GetNumber("FXChorusRate", 50);
this->m_nFXChorusDepth = this->m_Properties.GetNumber("FXChorusDepth", 50);
this->m_bFXFlangerEnable = this->m_Properties.GetNumber("FXFlangerEnable", 1);
this->m_nFXFlangerRate = this->m_Properties.GetNumber("FXFlangerRate", 15);
this->m_nFXFlangerDepth = this->m_Properties.GetNumber("FXFlangerDepth", 10);
this->m_nFXFlangerFeedback = this->m_Properties.GetNumber("FXFlangerFeedback", 20);
this->m_bFXOrbitoneEnable = this->m_Properties.GetNumber("FXOrbitoneEnable", 1);
this->m_nFXOrbitoneRate = this->m_Properties.GetNumber("FXOrbitoneRate", 40);
this->m_nFXOrbitoneDepth = this->m_Properties.GetNumber("FXOrbitoneDepth", 50);
this->m_bFXPhaserEnable = this->m_Properties.GetNumber("FXPhaserEnable", 1);
this->m_nFXPhaserRate = this->m_Properties.GetNumber("FXPhaserRate", 5);
this->m_nFXPhaserDepth = this->m_Properties.GetNumber("FXPhaserDepth", 99);
this->m_nFXPhaserFeedback = this->m_Properties.GetNumber("FXPhaserFeedback", 50);
this->m_nFXPhaserNbStages = this->m_Properties.GetNumber("FXPhaserNbStages", 12);
this->m_bFXDelayEnable = this->m_Properties.GetNumber("FXDelayEnable", 1);
this->m_nFXDelayLeftDelayTime = this->m_Properties.GetNumber("FXDelayLeftDelayTime", 15);
this->m_nFXDelayRightDelayTime = this->m_Properties.GetNumber("FXDelayRightDelayTime", 22);
this->m_nFXDelayFeedback = this->m_Properties.GetNumber("FXDelayFeedback", 35);
this->m_nFXDelayFlutterRate = this->m_Properties.GetNumber("FXDelayFlutterRate", 0);
this->m_nFXDelayFlutterAmount = this->m_Properties.GetNumber("FXDelayFlutterAmount", 0);
this->m_bFXReverberatorEnable = this->m_Properties.GetNumber("FXReverberatorEnable", 1);
this->m_nFXReverberatorInputGain = this->m_Properties.GetNumber("FXReverberatorInputGain", 30);
this->m_nFXReverberatorTime = this->m_Properties.GetNumber("FXReverberatorTime", 30);
@ -193,7 +203,7 @@ bool CPerformanceConfig::Load (void)
for(unsigned fx = 0; fx < MixerOutput::kFXCount; ++fx)
{
std::ostringstream oss("FXSendLevel_");
oss << in << "_x_" << fx;
oss << in << "_x_" << toString(static_cast<MixerOutput>(fx));
unsigned defaultLevel = 0;
if(fx == MixerOutput::MainOutput) defaultLevel = 50;
else if(fx == MixerOutput::FX_PlateReverb) defaultLevel = 50;
@ -207,7 +217,7 @@ bool CPerformanceConfig::Load (void)
for(size_t fx = 0; fx < MixerOutput::kFXCount; ++fx)
{
std::ostringstream oss("FXReturnLevel_");
oss << ret << "_x_" << fx;
oss << toString(static_cast<MixerOutput>(ret)) << "_x_" << toString(static_cast<MixerOutput>(fx));
unsigned defaultLevel = 0;
if(ret == MixerOutput::FX_PlateReverb && fx == MixerOutput::MainOutput) defaultLevel = 50;
this->m_nFXReturnLevel[ret][fx] = this->m_Properties.GetNumber(oss.str().c_str(), defaultLevel);
@ -334,50 +344,58 @@ bool CPerformanceConfig::Save (void)
m_Properties.SetNumber ("ReverbLevel", m_nReverbLevel);
#ifdef MIXING_CONSOLE_ENABLE
this->m_Properties.SetNumber("FXTubeEnable", m_bFXTubeEnable ? 1 : 0);
this->m_Properties.SetNumber("FXTubeOverdrive", m_nFXTubeOverdrive);
this->m_Properties.SetNumber("FXChorusEnable", m_bFXChorusEnable ? 1 : 0);
this->m_Properties.SetNumber("FXChorusRate", m_nFXChorusRate);
this->m_Properties.SetNumber("FXChorusDepth", m_nFXChorusDepth);
this->m_Properties.SetNumber("FXFlangerEnable", m_bFXFlangerEnable ? 1 : 0);
this->m_Properties.SetNumber("FXFlangerRate", m_nFXFlangerRate);
this->m_Properties.SetNumber("FXFlangerDepth", m_nFXFlangerDepth);
this->m_Properties.SetNumber("FXFlangerFeedback", m_nFXFlangerFeedback);
this->m_Properties.SetNumber("FXOrbitoneEnable", m_bFXOrbitoneEnable ? 1 : 0);
this->m_Properties.SetNumber("FXOrbitoneRate", m_nFXOrbitoneRate);
this->m_Properties.SetNumber("FXOrbitoneDepth", m_nFXOrbitoneDepth);
this->m_Properties.SetNumber("FXPhaserEnable", m_bFXPhaserEnable ? 1 : 0);
this->m_Properties.SetNumber("FXPhaserRate", m_nFXPhaserRate);
this->m_Properties.SetNumber("FXPhaserDepth", m_nFXPhaserDepth);
this->m_Properties.SetNumber("FXPhaserFeedback", m_nFXPhaserFeedback);
this->m_Properties.SetNumber("FXPhaserNbStages", m_nFXPhaserNbStages);
this->m_Properties.SetNumber("FXDelayEnable", m_bFXDelayEnable ? 1 : 0);
this->m_Properties.SetNumber("FXDelayLeftDelayTime", m_nFXDelayLeftDelayTime);
this->m_Properties.SetNumber("FXDelayRightDelayTime", m_nFXDelayRightDelayTime);
this->m_Properties.SetNumber("FXDelayFeedback", m_nFXDelayFeedback);
this->m_Properties.SetNumber("FXReverberatorEnable", m_bFXReverberatorEnable ? 1 : 0);
this->m_Properties.SetNumber("FXReverberatorInputGain", m_nFXReverberatorInputGain);
this->m_Properties.SetNumber("FXReverberatorTime", m_nFXReverberatorTime);
this->m_Properties.SetNumber("FXReverberatorDiffusion", m_nFXReverberatorDiffusion);
this->m_Properties.SetNumber("FXReverberatorLP", m_nFXReverberatorLP);
this->m_Properties.SetNumber("FXTubeEnable", this->m_bFXTubeEnable ? 1 : 0);
this->m_Properties.SetNumber("FXTubeOverdrive", this->m_nFXTubeOverdrive);
this->m_Properties.SetNumber("FXChorusEnable", this->m_bFXChorusEnable ? 1 : 0);
this->m_Properties.SetNumber("FXChorusRate", this->m_nFXChorusRate);
this->m_Properties.SetNumber("FXChorusDepth", this->m_nFXChorusDepth);
this->m_Properties.SetNumber("FXFlangerEnable", this->m_bFXFlangerEnable ? 1 : 0);
this->m_Properties.SetNumber("FXFlangerRate", this->m_nFXFlangerRate);
this->m_Properties.SetNumber("FXFlangerDepth", this->m_nFXFlangerDepth);
this->m_Properties.SetNumber("FXFlangerFeedback", this->m_nFXFlangerFeedback);
this->m_Properties.SetNumber("FXOrbitoneEnable", this->m_bFXOrbitoneEnable ? 1 : 0);
this->m_Properties.SetNumber("FXOrbitoneRate", this->m_nFXOrbitoneRate);
this->m_Properties.SetNumber("FXOrbitoneDepth", this->m_nFXOrbitoneDepth);
this->m_Properties.SetNumber("FXPhaserEnable", this->m_bFXPhaserEnable ? 1 : 0);
this->m_Properties.SetNumber("FXPhaserRate", this->m_nFXPhaserRate);
this->m_Properties.SetNumber("FXPhaserDepth", this->m_nFXPhaserDepth);
this->m_Properties.SetNumber("FXPhaserFeedback", this->m_nFXPhaserFeedback);
this->m_Properties.SetNumber("FXPhaserNbStages", this->m_nFXPhaserNbStages);
this->m_Properties.SetNumber("FXDelayEnable", this->m_bFXDelayEnable ? 1 : 0);
this->m_Properties.SetNumber("FXDelayLeftDelayTime", this->m_nFXDelayLeftDelayTime);
this->m_Properties.SetNumber("FXDelayRightDelayTime", this->m_nFXDelayRightDelayTime);
this->m_Properties.SetNumber("FXDelayFeedback", this->m_nFXDelayFeedback);
this->m_Properties.SetNumber("FXDelayFlutterRate", this->m_nFXDelayFlutterRate);
this->m_Properties.SetNumber("FXDelayFlutterAmount", this->m_nFXDelayFlutterAmount);
this->m_Properties.SetNumber("FXReverberatorEnable", this->m_bFXReverberatorEnable ? 1 : 0);
this->m_Properties.SetNumber("FXReverberatorInputGain", this->m_nFXReverberatorInputGain);
this->m_Properties.SetNumber("FXReverberatorTime", this->m_nFXReverberatorTime);
this->m_Properties.SetNumber("FXReverberatorDiffusion", this->m_nFXReverberatorDiffusion);
this->m_Properties.SetNumber("FXReverberatorLP", this->m_nFXReverberatorLP);
for(unsigned in = 0; in < CConfig::ToneGenerators; ++in)
{
for(unsigned fx = 0; fx < MixerOutput::kFXCount; ++fx)
for(size_t fx = 0; fx < MixerOutput::kFXCount; ++fx)
{
std::ostringstream oss("FXSendLevel_");
oss << in << "_x_" << fx;
oss << in << "_x_" << toString(static_cast<MixerOutput>(fx));
this->m_Properties.SetNumber(oss.str().c_str(), this->m_nFXSendLevel[in][fx]);
}
}
size_t end = MixerOutput::kFXCount - 1;
for(unsigned ret = 0; ret < end; ++ret)
for(size_t ret = 0; ret < end; ++ret)
{
for(unsigned fx = 0; fx < MixerOutput::kFXCount; ++fx)
for(size_t fx = 0; fx < MixerOutput::kFXCount; ++fx)
{
std::ostringstream oss("FXReturnLevel_");
oss << ret << "_x_" << fx;
oss << toString(static_cast<MixerOutput>(ret)) << "_x_" << toString(static_cast<MixerOutput>(fx));
this->m_Properties.SetNumber(oss.str().c_str(), this->m_nFXReturnLevel[ret][fx]);
}
}
@ -1137,6 +1155,16 @@ unsigned CPerformanceConfig::GetFXDelayFeedback(void) const
return this->m_nFXDelayFeedback;
}
unsigned CPerformanceConfig::GetFXDelayFlutterRate(void) const
{
return this->m_nFXDelayFlutterRate;
}
unsigned CPerformanceConfig::GetFXDelayFlutterAmount(void) const
{
return this->m_nFXDelayFlutterAmount;
}
bool CPerformanceConfig::GetFXReverberatorEnable(void) const
{
return this->m_bFXReverberatorEnable;
@ -1281,6 +1309,16 @@ void CPerformanceConfig::SetFXDelayFeedback(unsigned nValue)
this->m_nFXDelayFeedback = nValue;
}
void CPerformanceConfig::SetFXDelayFlutterRate(unsigned nValue)
{
this->m_nFXDelayFlutterRate = nValue;
}
void CPerformanceConfig::SetFXDelayFlutterAmount(unsigned nValue)
{
this->m_nFXDelayFlutterAmount = nValue;
}
void CPerformanceConfig::SetFXReverberatorEnable(unsigned bValue)
{
this->m_bFXReverberatorEnable = bValue;

@ -121,25 +121,33 @@ public:
#ifdef MIXING_CONSOLE_ENABLE
bool GetFXTubeEnable(void) const;
unsigned GetFXTubeOverdrive(void) const;
bool GetFXChorusEnable(void) const;
unsigned GetFXChorusRate(void) const;
unsigned GetFXChorusDepth(void) const;
bool GetFXFlangerEnable(void) const;
unsigned GetFXFlangerRate(void) const;
unsigned GetFXFlangerDepth(void) const;
unsigned GetFXFlangerFeedback(void) const;
bool GetFXOrbitoneEnable(void) const;
unsigned GetFXOrbitoneRate(void) const;
unsigned GetFXOrbitoneDepth(void) const;
bool GetFXPhaserEnable(void) const;
unsigned GetFXPhaserRate(void) const;
unsigned GetFXPhaserDepth(void) const;
unsigned GetFXPhaserFeedback(void) const;
unsigned GetFXPhaserNbStages(void) const;
bool GetFXDelayEnable(void) const;
unsigned GetFXDelayLeftDelayTime(void) const;
unsigned GetFXDelayRightDelayTime(void) const;
unsigned GetFXDelayFeedback(void) const;
unsigned GetFXDelayFlutterRate(void) const;
unsigned GetFXDelayFlutterAmount(void) const;
bool GetFXReverberatorEnable(void) const;
unsigned GetFXReverberatorInputGain(void) const;
unsigned GetFXReverberatorTime(void) const;
@ -150,30 +158,39 @@ public:
void SetFXTubeEnable(bool bValue);
void SetFXTubeOverdrive(unsigned nValue);
void SetFXChorusEnable(bool bValue);
void SetFXChorusRate(unsigned nValue);
void SetFXChorusDepth(unsigned nValue);
void SetFXFlangerEnable(bool bValue);
void SetFXFlangerRate(unsigned nValue);
void SetFXFlangerDepth(unsigned nValue);
void SetFXFlangerFeedback(unsigned nValue);
void SetFXOrbitoneEnable(bool bValue);
void SetFXOrbitoneRate(unsigned nValue);
void SetFXOrbitoneDepth(unsigned nValue);
void SetFXPhaserEnable(bool bValue);
void SetFXPhaserRate(unsigned nValue);
void SetFXPhaserDepth(unsigned nValue);
void SetFXPhaserFeedback(unsigned nValue);
void SetFXPhaserNbStages(unsigned nValue);
void SetFXDelayEnable(unsigned nValue);
void SetFXDelayLeftDelayTime(unsigned nValue);
void SetFXDelayRightDelayTime(unsigned nValue);
void SetFXDelayFeedback(unsigned nValue);
void SetFXDelayFlutterRate(unsigned nValue);
void SetFXDelayFlutterAmount(unsigned nValue);
void SetFXReverberatorEnable(unsigned nValue);
void SetFXReverberatorInputGain(unsigned nValue);
void SetFXReverberatorTime(unsigned nValue);
void SetFXReverberatorDiffusion(unsigned nValue);
void SetFXReverberatorLP(unsigned nValue);
void SetFXSendLevel(unsigned in, MixerOutput fx, unsigned nValue);
void SetFXReturnLevel(MixerOutput ret, MixerOutput fx, unsigned nValue);
#endif
@ -249,25 +266,33 @@ private:
bool m_bFXTubeEnable;
unsigned m_nFXTubeWet;
unsigned m_nFXTubeOverdrive;
bool m_bFXChorusEnable;
unsigned m_nFXChorusRate;
unsigned m_nFXChorusDepth;
bool m_bFXFlangerEnable;
unsigned m_nFXFlangerRate;
unsigned m_nFXFlangerDepth;
unsigned m_nFXFlangerFeedback;
bool m_bFXOrbitoneEnable;
unsigned m_nFXOrbitoneRate;
unsigned m_nFXOrbitoneDepth;
bool m_bFXPhaserEnable;
unsigned m_nFXPhaserRate;
unsigned m_nFXPhaserDepth;
unsigned m_nFXPhaserFeedback;
unsigned m_nFXPhaserNbStages;
bool m_bFXDelayEnable;
unsigned m_nFXDelayLeftDelayTime;
unsigned m_nFXDelayRightDelayTime;
unsigned m_nFXDelayFeedback;
unsigned m_nFXDelayFlutterRate;
unsigned m_nFXDelayFlutterAmount;
bool m_bFXReverberatorEnable;
unsigned m_nFXReverberatorInputGain;
unsigned m_nFXReverberatorTime;

@ -205,7 +205,8 @@ void setupMixingConsoleFX(Mixer* mixer, int scenarioId)
TEST(MixingConsole, ZeroSamplesTest)
{
const size_t length = 4;
static const size_t length = 4;
Mixer mixer(SAMPLING_FREQUENCY, length);
ASSERT_EQ(0, FULL_INSPECT((&mixer), true));
@ -223,6 +224,7 @@ TEST(MixingConsole, ZeroSamplesTest)
float32_t samples[] = {0.0f, 0.0f, 0.0f, 0.0f};
mixer.setInputSampleBuffer(0, samples);
mixer.preProcessInputSampleBuffer(0);
ASSERT_EQ(0, FULL_INSPECT((&mixer), true));
mixer.setSendLevel(0, MixerOutput::MainOutput, 1.0f);
@ -247,8 +249,8 @@ TEST(MixingConsole, ZeroSamplesTest)
TEST(MixingConsole, DryProcessing)
{
const float32_t epsilon = 1e-7;
const size_t length = 2;
static const float32_t epsilon = 1e-4;
static const size_t length = 2;
Mixer mixer(SAMPLING_FREQUENCY, length);
mixer.reset();
@ -277,6 +279,7 @@ TEST(MixingConsole, DryProcessing)
for(size_t i = 0; i < StereoChannels::kNumChannels; ++i) memset(out[i], 0, length * sizeof(float32_t));
mixer.setInputSampleBuffer(0, in);
mixer.preProcessInputSampleBuffer(0);
ASSERT_EQ(0, INSPECT((&mixer), fullInspector));
mixer.process(
@ -293,8 +296,8 @@ TEST(MixingConsole, DryProcessing)
TEST(MixingConsole, ReverberatorProcessing)
{
const float32_t epsilon = 1e-7;
const size_t length = 2;
static const float32_t epsilon = 1e-7;
static const size_t length = 2;
Mixer mixer(SAMPLING_FREQUENCY, length);
mixer.reset();
@ -340,7 +343,7 @@ TEST(MixingConsole, ReverberatorProcessing)
TEST(MixingConsole, ReverberatorNoiseProcessing)
{
const size_t length = 1024;
static const size_t length = 1024;
Mixer mixer(SAMPLING_FREQUENCY, length);
mixer.reset();

@ -7,6 +7,7 @@ typedef MixingConsole<1> Mixer;
TEST(MixingConsole, ShortBuffer)
{
static const float32_t SINPI_4 = std::sqrt(2.0f) / 2.0f;
static const float32_t epsilon = 1e-4;
const testing::TestInfo* test_info = testing::UnitTest::GetInstance()->current_test_info();
std::string full_test_name = test_info->test_case_name();
@ -28,14 +29,15 @@ TEST(MixingConsole, ShortBuffer)
memset(outSamples[1], 0, size * sizeof(float32_t));
mixer->setInputSampleBuffer(0, inSamples);
mixer->preProcessInputSampleBuffer(0);
ASSERT_EQ(0, FULL_INSPECT(mixer, true)) << full_test_name << " Mixer.setInputSampleBuffer";
mixer->process(outSamples[0], outSamples[1]);
ASSERT_EQ(0, FULL_INSPECT(mixer, true)) << full_test_name << " Mixer.process";
for(size_t s = 0; s < size; ++s)
{
EXPECT_FLOAT_EQ(outSamples[0][s], outSamples[1][s]);
EXPECT_FLOAT_EQ(outSamples[0][s], inSamples[s] * SINPI_4);
EXPECT_NEAR(outSamples[0][s], outSamples[1][s], epsilon);
EXPECT_NEAR(outSamples[0][s], inSamples[s] * SINPI_4, epsilon);
}
delete mixer;
@ -70,6 +72,7 @@ TEST(MixingConsole, ReverberatorShortBuffer)
memset(outSamples[1], 0, size * sizeof(float32_t));
mixer->setInputSampleBuffer(0, inSamples);
mixer->preProcessInputSampleBuffer(0);
ASSERT_EQ(0, FULL_INSPECT(mixer, true)) << full_test_name << " Mixer.setInputSampleBuffer";
mixer->process(outSamples[0], outSamples[1]);
@ -86,7 +89,7 @@ TEST(MixingConsole, DrySamplesBoundariesTest)
full_test_name += test_info->name();
size_t size;
float32_t** inSamples =readWaveFile(AUDIO_SOURCE_FILE, size);
float32_t** inSamples = readWaveFile(AUDIO_SOURCE_FILE, size);
Mixer* mixer = new Mixer(SAMPLING_FREQUENCY, size);
mixer->reset();
@ -97,6 +100,7 @@ TEST(MixingConsole, DrySamplesBoundariesTest)
mixer->setSendLevel(0, MixerOutput::MainOutput, 1.0f);
mixer->setInputSampleBuffer(0, inSamples[0]);
mixer->preProcessInputSampleBuffer(0);
float32_t** outSamples = new float32_t*[2];
outSamples[0] = new float32_t[size];
@ -133,7 +137,7 @@ TEST(MixingConsole, ReverberatorSamplesBoundariesTest)
full_test_name += test_info->name();
size_t size;
float32_t** inSamples =readWaveFile(AUDIO_SOURCE_FILE, size);
float32_t** inSamples = readWaveFile(AUDIO_SOURCE_FILE, size);
float32_t** outSamples = new float32_t*[2];
outSamples[0] = new float32_t[size];
@ -157,6 +161,7 @@ TEST(MixingConsole, ReverberatorSamplesBoundariesTest)
mixer->getReverberator()->setLP(0.7f);
mixer->setInputSampleBuffer(0, inSamples[0]);
mixer->preProcessInputSampleBuffer(0);
mixer->process(outSamples[0], outSamples[1]);
ASSERT_EQ(0, FULL_INSPECT2(mixer, true, full_test_name + "Mixer.process")) << full_test_name << " Mixer.process";

@ -34,112 +34,119 @@ using namespace std;
const CUIMenu::TMenuItem CUIMenu::s_MenuRoot[] =
{
{"MiniDexed", MenuHandler, CUIMenu::s_MainMenu},
{"MiniDexed", CUIMenu::MenuHandler, CUIMenu::s_MainMenu},
{0}
};
// inserting menu items before "TG1" affect TGShortcutHandler()
const CUIMenu::TMenuItem CUIMenu::s_MainMenu[] =
{
{"TG1", MenuHandler, CUIMenu::s_TGMenu, 0},
{"TG1", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 0},
#ifdef ARM_ALLOW_MULTI_CORE
{"TG2", MenuHandler, CUIMenu::s_TGMenu, 1},
{"TG3", MenuHandler, CUIMenu::s_TGMenu, 2},
{"TG4", MenuHandler, CUIMenu::s_TGMenu, 3},
{"TG5", MenuHandler, CUIMenu::s_TGMenu, 4},
{"TG6", MenuHandler, CUIMenu::s_TGMenu, 5},
{"TG7", MenuHandler, CUIMenu::s_TGMenu, 6},
{"TG8", MenuHandler, CUIMenu::s_TGMenu, 7},
{"TG2", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 1},
{"TG3", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 2},
{"TG4", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 3},
{"TG5", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 4},
{"TG6", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 5},
{"TG7", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 6},
{"TG8", CUIMenu::MenuHandler, CUIMenu::s_TGMenu, 7},
#endif
{"Effects", MenuHandler, CUIMenu::s_EffectsMenu},
{"Performance", MenuHandler, CUIMenu::s_PerformanceMenu},
{"Effects", CUIMenu::MenuHandler, CUIMenu::s_EffectsMenu},
{"Performance", CUIMenu::MenuHandler, CUIMenu::s_PerformanceMenu},
{0}
};
#if defined(MIXING_CONSOLE_ENABLE)
const CUIMenu::TMenuItem CUIMenu::s_TGFXMenu[] =
{
{"Tube-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXTube},
{"Chorus-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXChorus},
{"FlangR-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXFlanger},
{"Orb-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXOrbittone},
{"Phaser-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXPhaser},
{"Delay-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXDelay},
{"Plate-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXPlateReverb},
{"Rev-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXReverberator},
{"Main Out", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXMainOutput},
{0}
};
#endif
const CUIMenu::TMenuItem CUIMenu::s_TGMenu[] =
{
{"Voice", EditProgramNumber},
{"Bank", EditVoiceBankNumber},
{"Volume", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterVolume},
{"Voice", CUIMenu::EditProgramNumber},
{"Bank", CUIMenu::EditVoiceBankNumber},
{"Volume", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterVolume},
#ifdef ARM_ALLOW_MULTI_CORE
{"Pan", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterPan},
{"Pan", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterPan},
#endif
#if defined(MIXING_CONSOLE_ENABLE)
{"Tube-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXTube},
{"Chorus-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXChorus},
{"FlangR-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXFlanger},
{"Orb-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXOrbittone},
{"Phaser-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXPhaser},
{"Delay-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXDelay},
{"Plate-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXPlateReverb},
{"Rev-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXReverberator},
{"Main Out", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMixingSendFXMainOutput},
{"FX-Send", CUIMenu::MenuHandler, CUIMenu::s_TGFXMenu},
#elif defined(PLATE_REVERB_ENABLE)
{"Reverb-Send", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterReverbSend},
#endif
#if defined(PLATE_REVERB_ENABLE)
{"Reverb-Send", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterReverbSend},
#endif
{"Detune", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMasterTune},
{"Cutoff", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterCutoff},
{"Resonance", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterResonance},
{"Pitch Bend", MenuHandler, CUIMenu::s_EditPitchBendMenu},
{"Portamento", MenuHandler, CUIMenu::s_EditPortamentoMenu},
{"Poly/Mono", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMonoMode},
{"Modulation", MenuHandler, CUIMenu::s_ModulationMenu},
{"Channel", EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMIDIChannel},
{"Edit Voice", MenuHandler, CUIMenu::s_EditVoiceMenu},
{"Detune", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMasterTune},
{"Cutoff", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterCutoff},
{"Resonance", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterResonance},
{"Pitch Bend", CUIMenu::MenuHandler, CUIMenu::s_EditPitchBendMenu},
{"Portamento", CUIMenu::MenuHandler, CUIMenu::s_EditPortamentoMenu},
{"Poly/Mono", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMonoMode},
{"Modulation", CUIMenu::MenuHandler, CUIMenu::s_ModulationMenu},
{"Channel", CUIMenu::EditTGParameter, 0, CMiniDexed::TTGParameter::TGParameterMIDIChannel},
{"Edit Voice", CUIMenu::MenuHandler, CUIMenu::s_EditVoiceMenu},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_EffectsMenu[] =
{
{"Compress", EditGlobalParameter, 0, CMiniDexed::ParameterCompressorEnable},
{"Compress",CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterCompressorEnable},
#if defined(MIXING_CONSOLE_ENABLE)
{"Tube", MenuHandler, CUIMenu::s_FXTube},
{"Chorus", MenuHandler, CUIMenu::s_FXChorus},
{"FlangR", MenuHandler, CUIMenu::s_FXFlanger},
{"Orb", MenuHandler, CUIMenu::s_FXOrbitone},
{"PhasR", MenuHandler, CUIMenu::s_FXPhaser},
{"Delay", MenuHandler, CUIMenu::s_FXDelay},
{"Tube", CUIMenu::MenuHandler, CUIMenu::s_FXTube},
{"Chorus", CUIMenu::MenuHandler, CUIMenu::s_FXChorus},
{"FlangR", CUIMenu::MenuHandler, CUIMenu::s_FXFlanger},
{"Orb", CUIMenu::MenuHandler, CUIMenu::s_FXOrbitone},
{"PhasR", CUIMenu::MenuHandler, CUIMenu::s_FXPhaser},
{"Delay", CUIMenu::MenuHandler, CUIMenu::s_FXDelay},
#endif
#if defined(PLATE_REVERB_ENABLE)
{"Reverb", MenuHandler, CUIMenu::s_FXPlateReverb},
{"Reverb", CUIMenu::MenuHandler, CUIMenu::s_FXPlateReverb},
#elif defined(MIXING_CONSOLE_ENABLE)
{"Plate Reverb", MenuHandler, CUIMenu::s_FXPlateReverb},
{"Reverberator", MenuHandler, CUIMenu::s_FXReverberator},
{"Plt Rvb", CUIMenu::MenuHandler, CUIMenu::s_FXPlateReverb},
{"Rvbrtor", CUIMenu::MenuHandler, CUIMenu::s_FXReverberator},
#endif
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_EditPitchBendMenu[] =
{
{"Bend Range", EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPitchBendRange},
{"Bend Step", EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPitchBendStep},
{"Bend Range", CUIMenu::EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPitchBendRange},
{"Bend Step", CUIMenu::EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPitchBendStep},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_EditPortamentoMenu[] =
{
{"Mode", EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPortamentoMode},
{"Glissando", EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPortamentoGlissando},
{"Time", EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPortamentoTime},
{"Mode", CUIMenu::EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPortamentoMode},
{"Glissando", CUIMenu::EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPortamentoGlissando},
{"Time", CUIMenu::EditTGParameter2, 0, CMiniDexed::TTGParameter::TGParameterPortamentoTime},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_ModulationMenu[] =
{
{"Mod. Wheel", MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterMWRange},
{"Foot Control", MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterFCRange},
{"Breath Control", MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterBCRange},
{"Aftertouch", MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterATRange},
{"Mod. Wheel", CUIMenu::MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterMWRange},
{"Foot Control", CUIMenu::MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterFCRange},
{"Breath Control", CUIMenu::MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterBCRange},
{"Aftertouch", CUIMenu::MenuHandler, CUIMenu::s_ModulationMenuParameters, CMiniDexed::TTGParameter::TGParameterATRange},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_ModulationMenuParameters[] =
{
{"Range", EditTGParameterModulation, 0, 0},
{"Pitch", EditTGParameterModulation, 0, 1},
{"Amplitude", EditTGParameterModulation, 0, 2},
{"EG Bias", EditTGParameterModulation, 0, 3},
{"Range", CUIMenu::EditTGParameterModulation, 0, 0},
{"Pitch", CUIMenu::EditTGParameterModulation, 0, 1},
{"Amplitude", CUIMenu::EditTGParameterModulation, 0, 2},
{"EG Bias", CUIMenu::EditTGParameterModulation, 0, 3},
{0}
};
@ -147,15 +154,15 @@ const CUIMenu::TMenuItem CUIMenu::s_ModulationMenuParameters[] =
const CUIMenu::TMenuItem CUIMenu::s_FXPlateReverb[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbEnable},
{"Size", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbSize},
{"High damp", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbHighDamp},
{"Low damp", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbLowDamp},
{"Low pass", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbLowPass},
{"Diffusion", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbDiffusion},
{"Level", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbLevel},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbEnable},
{"Size", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbSize},
{"High damp", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbHighDamp},
{"Low damp", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbLowDamp},
{"Low pass", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbLowPass},
{"Diffusion", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbDiffusion},
{"Level", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterReverbLevel},
#if defined(MIXING_CONSOLE_ENABLE)
{"Return", MenuHandler, CUIMenu::s_FXPlateReverbReturn},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXPlateReverbReturn},
#endif
{0}
};
@ -166,175 +173,175 @@ const CUIMenu::TMenuItem CUIMenu::s_FXPlateReverb[] =
const CUIMenu::TMenuItem CUIMenu::s_FXTube[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXTubeEnable},
{"Overdrv", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXTubeOverdrive},
{"Return", MenuHandler, CUIMenu::s_FXTubeReturn},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXTubeEnable},
{"Overdrv", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXTubeOverdrive},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXTubeReturn},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXChorus[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorusEnable},
{"Rate", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorusRate},
{"Depth", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorusDepth},
{"Return", MenuHandler, CUIMenu::s_FXChorusReturn},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorusEnable},
{"Rate", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorusRate},
{"Depth", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorusDepth},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXChorusReturn},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXFlanger[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerEnable},
{"Rate", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerRate},
{"Depth", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerDepth},
{"Feedbck", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerFeedback},
{"Return", MenuHandler, CUIMenu::s_FXFlangerReturn},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerEnable},
{"Rate", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerRate},
{"Depth", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerDepth},
{"Feedbck", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlangerFeedback},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXFlangerReturn},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXOrbitone[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitoneEnable},
{"Rate", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitoneRate},
{"Depth", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitoneDepth},
{"Return", MenuHandler, CUIMenu::s_FXOrbitoneReturn},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitoneEnable},
{"Rate", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitoneRate},
{"Depth", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitoneDepth},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXOrbitoneReturn},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXPhaser[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserEnable},
{"Rate", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserRate},
{"Depth", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserDepth},
{"Feedbck", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserFeedback},
{"Stages", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserNbStages},
{"Return", MenuHandler, CUIMenu::s_FXPhaserReturn},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserEnable},
{"Rate", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserRate},
{"Depth", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserDepth},
{"Feedbck", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserFeedback},
{"Stages", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaserNbStages},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXPhaserReturn},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXDelay[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayEnable},
{"L Delay", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayLeftDelayTime},
{"R Delay", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayRightDelayTime},
{"Feedbck", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayFeedback},
{"Flt Rte", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayFlutterRate},
{"Flt Amt", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayFlutterAmount},
{"Return", MenuHandler, CUIMenu::s_FXDelayReturn},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayEnable},
{"L Delay", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayLeftDelayTime},
{"R Delay", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayRightDelayTime},
{"Feedbck", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayFeedback},
{"Flt Rte", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayFlutterRate},
{"Flt Amt", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelayFlutterAmount},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXDelayReturn},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXReverberator[] =
{
{"Enable", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorEnable},
{"Gain", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorInputGain},
{"Time", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorTime},
{"Diffus", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorDiffusion},
{"LowPass", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorLP},
{"Return", MenuHandler, CUIMenu::s_FXReverberatorReturn},
{"Enable", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorEnable},
{"Gain", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorInputGain},
{"Time", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorTime},
{"Diffus", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorDiffusion},
{"LowPass", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberatorLP},
{"Return", CUIMenu::MenuHandler, CUIMenu::s_FXReverberatorReturn},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXTubeReturn[] =
{
{"ChR Rtn", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_ChorusReturn},
{"Flg Rtn", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_FlangerReturn},
{"Orb Rtn", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_OrbitoneReturn},
{"PhR Rtn", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_PhaserReturn},
{"Dly Rtn", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_DelayReturn},
{"Plt Rtn", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_ReverbReturn},
{"Rev Rtn", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_ReverberatorReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_MainOutput},
{"ChR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_ChorusReturn},
{"Flg Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_FlangerReturn},
{"Orb Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_OrbitoneReturn},
{"PhR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_PhaserReturn},
{"Dly Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_DelayReturn},
{"Plt Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_PlateReverbReturn},
{"Rev Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_ReverberatorReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::ParameterFXTube_MainOutput},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXChorusReturn[] =
{
{"Tub Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_TubeReturn},
{"Flg Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_FlangerReturn},
{"Orb Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_OrbitoneReturn},
{"PhR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_PhaserReturn},
{"Dly Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_DelayReturn},
{"Plt Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_ReverbReturn},
{"Rev Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_ReverberatorReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_MainOutput},
{"Tub Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_TubeReturn},
{"Flg Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_FlangerReturn},
{"Orb Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_OrbitoneReturn},
{"PhR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_PhaserReturn},
{"Dly Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_DelayReturn},
{"Plt Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_PlateReverbReturn},
{"Rev Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_ReverberatorReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXChorus_MainOutput},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXFlangerReturn[] =
{
{"Tub Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_TubeReturn},
{"ChR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_ChorusReturn},
{"Orb Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_OrbitoneReturn},
{"PhR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_PhaserReturn},
{"Dly Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_DelayReturn},
{"Plt Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_ReverbReturn},
{"Rev Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_ReverberatorReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_MainOutput},
{"Tub Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_TubeReturn},
{"ChR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_ChorusReturn},
{"Orb Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_OrbitoneReturn},
{"PhR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_PhaserReturn},
{"Dly Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_DelayReturn},
{"Plt Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_PlateReverbReturn},
{"Rev Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_ReverberatorReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXFlanger_MainOutput},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXOrbitoneReturn[] =
{
{"Tub Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_TubeReturn},
{"ChR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_ChorusReturn},
{"Flg Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_FlangerReturn},
{"PhR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_PhaserReturn},
{"Dly Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_DelayReturn},
{"Plt Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_ReverbReturn},
{"Rev Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_ReverberatorReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_MainOutput},
{"Tub Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_TubeReturn},
{"ChR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_ChorusReturn},
{"Flg Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_FlangerReturn},
{"PhR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_PhaserReturn},
{"Dly Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_DelayReturn},
{"Plt Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_PlateReverbReturn},
{"Rev Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_ReverberatorReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXOrbitone_MainOutput},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXPhaserReturn[] =
{
{"Tub Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_TubeReturn},
{"ChR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_ChorusReturn},
{"Flg Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_FlangerReturn},
{"Orb Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_OrbitoneReturn},
{"Dly Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_DelayReturn},
{"Plt Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_ReverbReturn},
{"Rev Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_ReverberatorReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_MainOutput},
{"Tub Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_TubeReturn},
{"ChR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_ChorusReturn},
{"Flg Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_FlangerReturn},
{"Orb Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_OrbitoneReturn},
{"Dly Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_DelayReturn},
{"Plt Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_PlateReverbReturn},
{"Rev Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_ReverberatorReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPhaser_MainOutput},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXDelayReturn[] =
{
{"Tub Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_TubeReturn},
{"ChR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_ChorusReturn},
{"Flg Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_FlangerReturn},
{"Orb Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_OrbitoneReturn},
{"PhR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_PhaserReturn},
{"Plt Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_ReverbReturn},
{"Rev Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_ReverberatorReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_MainOutput},
{"Tub Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_TubeReturn},
{"ChR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_ChorusReturn},
{"Flg Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_FlangerReturn},
{"Orb Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_OrbitoneReturn},
{"PhR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_PhaserReturn},
{"Plt Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_PlateReverbReturn},
{"Rev Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_ReverberatorReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXDelay_MainOutput},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXPlateReverbReturn[] =
{
{"Tub Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_TubeReturn},
{"ChR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_ChorusReturn},
{"Flg Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_FlangerReturn},
{"Orb Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_OrbitoneReturn},
{"PhR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_PhaserReturn},
{"Dly Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_DelayReturn},
{"Rev Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_ReverberatorReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverb_MainOutput},
{"Tub Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_TubeReturn},
{"ChR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_ChorusReturn},
{"Flg Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_FlangerReturn},
{"Orb Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_OrbitoneReturn},
{"PhR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_PhaserReturn},
{"Dly Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_DelayReturn},
{"Rev Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_ReverberatorReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXPlateReverb_MainOutput},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_FXReverberatorReturn[] =
{
{"Tub Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_TubeReturn},
{"ChR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_ChorusReturn},
{"Flg Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_FlangerReturn},
{"Orb Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_OrbitoneReturn},
{"PhR Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_PhaserReturn},
{"Dly Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_DelayReturn},
{"Plt Rtn", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_ReverbReturn},
{"MainOut", EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_MainOutput},
{"Tub Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_TubeReturn},
{"ChR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_ChorusReturn},
{"Flg Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_FlangerReturn},
{"Orb Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_OrbitoneReturn},
{"PhR Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_PhaserReturn},
{"Dly Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_DelayReturn},
{"Plt Rtn", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_PlateReverbReturn},
{"MainOut", CUIMenu::EditGlobalParameter, 0, CMiniDexed::TParameter::ParameterFXReverberator_MainOutput},
{0}
};
@ -343,79 +350,77 @@ const CUIMenu::TMenuItem CUIMenu::s_FXReverberatorReturn[] =
// inserting menu items before "OP1" affect OPShortcutHandler()
const CUIMenu::TMenuItem CUIMenu::s_EditVoiceMenu[] =
{
{"OP1", MenuHandler, CUIMenu::s_OperatorMenu, 0},
{"OP2", MenuHandler, CUIMenu::s_OperatorMenu, 1},
{"OP3", MenuHandler, CUIMenu::s_OperatorMenu, 2},
{"OP4", MenuHandler, CUIMenu::s_OperatorMenu, 3},
{"OP5", MenuHandler, CUIMenu::s_OperatorMenu, 4},
{"OP6", MenuHandler, CUIMenu::s_OperatorMenu, 5},
{"Algorithm", EditVoiceParameter, 0, DEXED_ALGORITHM},
{"Feedback", EditVoiceParameter, 0, DEXED_FEEDBACK},
{"P EG Rate 1", EditVoiceParameter, 0, DEXED_PITCH_EG_R1},
{"P EG Rate 2", EditVoiceParameter, 0, DEXED_PITCH_EG_R2},
{"P EG Rate 3", EditVoiceParameter, 0, DEXED_PITCH_EG_R3},
{"P EG Rate 4", EditVoiceParameter, 0, DEXED_PITCH_EG_R4},
{"P EG Level 1",EditVoiceParameter, 0, DEXED_PITCH_EG_L1},
{"P EG Level 2",EditVoiceParameter, 0, DEXED_PITCH_EG_L2},
{"P EG Level 3",EditVoiceParameter, 0, DEXED_PITCH_EG_L3},
{"P EG Level 4",EditVoiceParameter, 0, DEXED_PITCH_EG_L4},
{"Osc Key Sync",EditVoiceParameter, 0, DEXED_OSC_KEY_SYNC},
{"LFO Speed", EditVoiceParameter, 0, DEXED_LFO_SPEED},
{"LFO Delay", EditVoiceParameter, 0, DEXED_LFO_DELAY},
{"LFO PMD", EditVoiceParameter, 0, DEXED_LFO_PITCH_MOD_DEP},
{"LFO AMD", EditVoiceParameter, 0, DEXED_LFO_AMP_MOD_DEP},
{"LFO Sync", EditVoiceParameter, 0, DEXED_LFO_SYNC},
{"LFO Wave", EditVoiceParameter, 0, DEXED_LFO_WAVE},
{"P Mod Sens.", EditVoiceParameter, 0, DEXED_LFO_PITCH_MOD_SENS},
{"Transpose", EditVoiceParameter, 0, DEXED_TRANSPOSE},
{"Name", InputTxt, 0, 3},
{"OP1", CUIMenu::MenuHandler, CUIMenu::s_OperatorMenu, 0},
{"OP2", CUIMenu::MenuHandler, CUIMenu::s_OperatorMenu, 1},
{"OP3", CUIMenu::MenuHandler, CUIMenu::s_OperatorMenu, 2},
{"OP4", CUIMenu::MenuHandler, CUIMenu::s_OperatorMenu, 3},
{"OP5", CUIMenu::MenuHandler, CUIMenu::s_OperatorMenu, 4},
{"OP6", CUIMenu::MenuHandler, CUIMenu::s_OperatorMenu, 5},
{"Algorithm", CUIMenu::EditVoiceParameter, 0, DEXED_ALGORITHM},
{"Feedback", CUIMenu::EditVoiceParameter, 0, DEXED_FEEDBACK},
{"P EG Rate 1", CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_R1},
{"P EG Rate 2", CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_R2},
{"P EG Rate 3", CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_R3},
{"P EG Rate 4", CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_R4},
{"P EG Level 1",CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_L1},
{"P EG Level 2",CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_L2},
{"P EG Level 3",CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_L3},
{"P EG Level 4",CUIMenu::EditVoiceParameter, 0, DEXED_PITCH_EG_L4},
{"Osc Key Sync",CUIMenu::EditVoiceParameter, 0, DEXED_OSC_KEY_SYNC},
{"LFO Speed", CUIMenu::EditVoiceParameter, 0, DEXED_LFO_SPEED},
{"LFO Delay", CUIMenu::EditVoiceParameter, 0, DEXED_LFO_DELAY},
{"LFO PMD", CUIMenu::EditVoiceParameter, 0, DEXED_LFO_PITCH_MOD_DEP},
{"LFO AMD", CUIMenu::EditVoiceParameter, 0, DEXED_LFO_AMP_MOD_DEP},
{"LFO Sync", CUIMenu::EditVoiceParameter, 0, DEXED_LFO_SYNC},
{"LFO Wave", CUIMenu::EditVoiceParameter, 0, DEXED_LFO_WAVE},
{"P Mod Sens.", CUIMenu::EditVoiceParameter, 0, DEXED_LFO_PITCH_MOD_SENS},
{"Transpose", CUIMenu::EditVoiceParameter, 0, DEXED_TRANSPOSE},
{"Name", CUIMenu::InputTxt, 0, 3},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_OperatorMenu[] =
{
{"Output Level",EditOPParameter, 0, DEXED_OP_OUTPUT_LEV},
{"Freq Coarse", EditOPParameter, 0, DEXED_OP_FREQ_COARSE},
{"Freq Fine", EditOPParameter, 0, DEXED_OP_FREQ_FINE},
{"Osc Detune", EditOPParameter, 0, DEXED_OP_OSC_DETUNE},
{"Osc Mode", EditOPParameter, 0, DEXED_OP_OSC_MODE},
{"EG Rate 1", EditOPParameter, 0, DEXED_OP_EG_R1},
{"EG Rate 2", EditOPParameter, 0, DEXED_OP_EG_R2},
{"EG Rate 3", EditOPParameter, 0, DEXED_OP_EG_R3},
{"EG Rate 4", EditOPParameter, 0, DEXED_OP_EG_R4},
{"EG Level 1", EditOPParameter, 0, DEXED_OP_EG_L1},
{"EG Level 2", EditOPParameter, 0, DEXED_OP_EG_L2},
{"EG Level 3", EditOPParameter, 0, DEXED_OP_EG_L3},
{"EG Level 4", EditOPParameter, 0, DEXED_OP_EG_L4},
{"Break Point", EditOPParameter, 0, DEXED_OP_LEV_SCL_BRK_PT},
{"L Key Depth", EditOPParameter, 0, DEXED_OP_SCL_LEFT_DEPTH},
{"R Key Depth", EditOPParameter, 0, DEXED_OP_SCL_RGHT_DEPTH},
{"L Key Scale", EditOPParameter, 0, DEXED_OP_SCL_LEFT_CURVE},
{"R Key Scale", EditOPParameter, 0, DEXED_OP_SCL_RGHT_CURVE},
{"Rate Scaling",EditOPParameter, 0, DEXED_OP_OSC_RATE_SCALE},
{"A Mod Sens.", EditOPParameter, 0, DEXED_OP_AMP_MOD_SENS},
{"K Vel. Sens.",EditOPParameter, 0, DEXED_OP_KEY_VEL_SENS},
{"Enable", EditOPParameter, 0, DEXED_OP_ENABLE},
{"Output Level",CUIMenu::EditOPParameter, 0, DEXED_OP_OUTPUT_LEV},
{"Freq Coarse", CUIMenu::EditOPParameter, 0, DEXED_OP_FREQ_COARSE},
{"Freq Fine", CUIMenu::EditOPParameter, 0, DEXED_OP_FREQ_FINE},
{"Osc Detune", CUIMenu::EditOPParameter, 0, DEXED_OP_OSC_DETUNE},
{"Osc Mode", CUIMenu::EditOPParameter, 0, DEXED_OP_OSC_MODE},
{"EG Rate 1", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_R1},
{"EG Rate 2", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_R2},
{"EG Rate 3", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_R3},
{"EG Rate 4", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_R4},
{"EG Level 1", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_L1},
{"EG Level 2", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_L2},
{"EG Level 3", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_L3},
{"EG Level 4", CUIMenu::EditOPParameter, 0, DEXED_OP_EG_L4},
{"Break Point", CUIMenu::EditOPParameter, 0, DEXED_OP_LEV_SCL_BRK_PT},
{"L Key Depth", CUIMenu::EditOPParameter, 0, DEXED_OP_SCL_LEFT_DEPTH},
{"R Key Depth", CUIMenu::EditOPParameter, 0, DEXED_OP_SCL_RGHT_DEPTH},
{"L Key Scale", CUIMenu::EditOPParameter, 0, DEXED_OP_SCL_LEFT_CURVE},
{"R Key Scale", CUIMenu::EditOPParameter, 0, DEXED_OP_SCL_RGHT_CURVE},
{"Rate Scaling",CUIMenu::EditOPParameter, 0, DEXED_OP_OSC_RATE_SCALE},
{"A Mod Sens.", CUIMenu::EditOPParameter, 0, DEXED_OP_AMP_MOD_SENS},
{"K Vel. Sens.",CUIMenu::EditOPParameter, 0, DEXED_OP_KEY_VEL_SENS},
{"Enable", CUIMenu::EditOPParameter, 0, DEXED_OP_ENABLE},
{0}
};
const CUIMenu::TMenuItem CUIMenu::s_SaveMenu[] =
{
{"Overwrite", SavePerformance, 0, 0},
{"New", InputTxt,0 , 1},
{"Save as default", SavePerformance, 0, 1},
{"Overwrite", CUIMenu::SavePerformance, 0, 0},
{"New", CUIMenu::InputTxt, 0, 1},
{"Save as default", CUIMenu::SavePerformance, 0, 1},
{0}
};
// must match CMiniDexed::TParameter
const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknown] =
const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::TParameter::ParameterUnknown] =
{
{0, 1, 1, ToOnOff} // ParameterCompressorEnable
#if defined(MIXING_CONSOLE_ENABLE) || defined(PLATE_REVERB_ENABLE)
#if defined(PLATE_REVERB_ENABLE) || defined(MIXING_CONSOLE_ENABLE)
,
{0, 1, 1, ToOnOff}, // ParameterReverbEnable
{0, 99, 1}, // ParameterReverbSize
{0, 99, 1}, // ParameterReverbHighDamp
@ -428,7 +433,6 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
// BEGIN FX global parameters mapping definition
#if defined(MIXING_CONSOLE_ENABLE)
,
// FX > Tube parameters
{0, 1, 1, ToOnOff}, // ParameterFXTubeEnable
{0, 99, 1}, // ParameterFXTubeOverdrive
@ -477,7 +481,7 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
{0, 99, 1}, // ParameterFXTube_OrbitoneReturn,
{0, 99, 1}, // ParameterFXTube_PhaserReturn,
{0, 99, 1}, // ParameterFXTube_DelayReturn,
{0, 99, 1}, // ParameterFXTube_ReverbReturn,
{0, 99, 1}, // ParameterFXTube_PlateReverbReturn,
{0, 99, 1}, // ParameterFXTube_ReverberatorReturn,
{0, 99, 1}, // ParameterFXTube_MainOutput,
@ -487,7 +491,7 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
{0, 99, 1}, // ParameterFXChorus_OrbitoneReturn,
{0, 99, 1}, // ParameterFXChorus_PhaserReturn,
{0, 99, 1}, // ParameterFXChorus_DelayReturn,
{0, 99, 1}, // ParameterFXChorus_ReverbReturn,
{0, 99, 1}, // ParameterFXChorus_PlateReverbReturn,
{0, 99, 1}, // ParameterFXChorus_ReverberatorReturn,
{0, 99, 1}, // ParameterFXChorus_MainOutput,
@ -497,7 +501,7 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
{0, 99, 1}, // ParameterFXFlanger_OrbitoneReturn,
{0, 99, 1}, // ParameterFXFlanger_PhaserReturn,
{0, 99, 1}, // ParameterFXFlanger_DelayReturn,
{0, 99, 1}, // ParameterFXFlanger_ReverbReturn,
{0, 99, 1}, // ParameterFXFlanger_PlateReverbReturn,
{0, 99, 1}, // ParameterFXFlanger_ReverberatorReturn,
{0, 99, 1}, // ParameterFXFlanger_MainOutput,
@ -507,7 +511,7 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
{0, 99, 1}, // ParameterFXOrbitone_FlangerReturn,
{0, 99, 1}, // ParameterFXOrbitone_PhaserReturn,
{0, 99, 1}, // ParameterFXOrbitone_DelayReturn,
{0, 99, 1}, // ParameterFXOrbitone_ReverbReturn,
{0, 99, 1}, // ParameterFXOrbitone_PlateReverbReturn,
{0, 99, 1}, // ParameterFXOrbitone_ReverberatorReturn,
{0, 99, 1}, // ParameterFXOrbitone_MainOutput,
@ -517,7 +521,7 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
{0, 99, 1}, // ParameterFXPhaser_FlangerReturn,
{0, 99, 1}, // ParameterFXPhaser_OrbitoneReturn,
{0, 99, 1}, // ParameterFXPhaser_DelayReturn,
{0, 99, 1}, // ParameterFXPhaser_ReverbReturn,
{0, 99, 1}, // ParameterFXPhaser_PlateReverbReturn,
{0, 99, 1}, // ParameterFXPhaser_ReverberatorReturn,
{0, 99, 1}, // ParameterFXPhaser_MainOutput,
@ -527,7 +531,7 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
{0, 99, 1}, // ParameterFXDelay_FlangerReturn,
{0, 99, 1}, // ParameterFXDelay_OrbitoneReturn,
{0, 99, 1}, // ParameterFXDelay_PhaserReturn,
{0, 99, 1}, // ParameterFXDelay_ReverbReturn,
{0, 99, 1}, // ParameterFXDelay_PlateReverbReturn,
{0, 99, 1}, // ParameterFXDelay_ReverberatorReturn,
{0, 99, 1}, // ParameterFXDelay_MainOutput,
@ -548,101 +552,113 @@ const CUIMenu::TParameter CUIMenu::s_GlobalParameter[CMiniDexed::ParameterUnknow
{0, 99, 1}, // ParameterFXReverberator_OrbitoneReturn,
{0, 99, 1}, // ParameterFXReverberator_PhaserReturn,
{0, 99, 1}, // ParameterFXReverberator_DelayReturn,
{0, 99, 1}, // ParameterFXReverberator_ReverbReturn,
{0, 99, 1}, // ParameterFXReverberator_MainOutput,
{0, 99, 1}, // ParameterFXReverberator_PlateReverbReturn,
{0, 99, 1} // ParameterFXReverberator_MainOutput,
#endif
// END FX global parameters mapping definition
};
// must match CMiniDexed::TTGParameter
const CUIMenu::TParameter CUIMenu::s_TGParameter[CMiniDexed::TTGParameter::TGParameterUnknown] =
{
{0, CSysExFileLoader::MaxVoiceBankID, 1}, // TGParameterVoiceBank
{0, CSysExFileLoader::VoicesPerBank-1, 1}, // TGParameterProgram
{0, 127, 8, ToVolume}, // TGParameterVolume
{0, 127, 8, ToPan}, // TGParameterPan
{-99, 99, 1}, // TGParameterMasterTune
{0, 99, 1}, // TGParameterCutoff
{0, 99, 1}, // TGParameterResonance
{0, CMIDIDevice::ChannelUnknown-1, 1, ToMIDIChannel}, // TGParameterMIDIChannel
{0, 99, 1}, // TGParameterReverbSend
{0, 12, 1}, // TGParameterPitchBendRange
{0, 12, 1}, // TGParameterPitchBendStep
{0, 1, 1, ToPortaMode}, // TGParameterPortamentoMode
{0, 1, 1, ToPortaGlissando}, // TGParameterPortamentoGlissando
{0, 99, 1}, // TGParameterPortamentoTime
{0, 1, 1, ToPolyMono}, // TGParameterMonoMode
{0, 99, 1}, //MW Range
{0, 1, 1, ToOnOff}, //MW Pitch
{0, 1, 1, ToOnOff}, //MW Amp
{0, 1, 1, ToOnOff}, //MW EGBias
{0, 99, 1}, //FC Range
{0, 1, 1, ToOnOff}, //FC Pitch
{0, 1, 1, ToOnOff}, //FC Amp
{0, 1, 1, ToOnOff}, //FC EGBias
{0, 99, 1}, //BC Range
{0, 1, 1, ToOnOff}, //BC Pitch
{0, 1, 1, ToOnOff}, //BC Amp
{0, 1, 1, ToOnOff}, //BC EGBias
{0, 99, 1}, //AT Range
{0, 1, 1, ToOnOff}, //AT Pitch
{0, 1, 1, ToOnOff}, //AT Amp
{0, 1, 1, ToOnOff} //AT EGBias
{0, CSysExFileLoader::MaxVoiceBankID, 1}, // TGParameterVoiceBank
{0, CSysExFileLoader::VoicesPerBank-1, 1}, // TGParameterProgram
{0, 127, 8, ToVolume}, // TGParameterVolume
{0, 127, 8, ToPan}, // TGParameterPan
{-99, 99, 1}, // TGParameterMasterTune
{0, 99, 1}, // TGParameterCutoff
{0, 99, 1}, // TGParameterResonance
{0, CMIDIDevice::ChannelUnknown-1, 1, ToMIDIChannel}, // TGParameterMIDIChannel
#if defined(PLATE_REVERB_ENABLE)
{0, 99, 1}, // TGParameterReverbSend
#endif
{0, 12, 1}, // TGParameterPitchBendRange
{0, 12, 1}, // TGParameterPitchBendStep
{0, 1, 1, ToPortaMode}, // TGParameterPortamentoMode
{0, 1, 1, ToPortaGlissando}, // TGParameterPortamentoGlissando
{0, 99, 1}, // TGParameterPortamentoTime
{0, 1, 1, ToPolyMono}, // TGParameterMonoMode
{0, 99, 1}, //MW Range
{0, 1, 1, ToOnOff}, //MW Pitch
{0, 1, 1, ToOnOff}, //MW Amp
{0, 1, 1, ToOnOff}, //MW EGBias
{0, 99, 1}, //FC Range
{0, 1, 1, ToOnOff}, //FC Pitch
{0, 1, 1, ToOnOff}, //FC Amp
{0, 1, 1, ToOnOff}, //FC EGBias
{0, 99, 1}, //BC Range
{0, 1, 1, ToOnOff}, //BC Pitch
{0, 1, 1, ToOnOff}, //BC Amp
{0, 1, 1, ToOnOff}, //BC EGBias
{0, 99, 1}, //AT Range
{0, 1, 1, ToOnOff}, //AT Pitch
{0, 1, 1, ToOnOff}, //AT Amp
{0, 1, 1, ToOnOff} //AT EGBias
#if defined(MIXING_CONSOLE_ENABLE)
,
{0, 99, 1}, // TGParameterMixingSendFXTube,
{0, 99, 1}, // TGParameterMixingSendFXChorus,
{0, 99, 1}, // TGParameterMixingSendFXFlanger,
{0, 99, 1}, // TGParameterMixingSendFXOrbittone,
{0, 99, 1}, // TGParameterMixingSendFXPhaser,
{0, 99, 1}, // TGParameterMixingSendFXDelay,
{0, 99, 1}, // TGParameterMixingSendFXPlateReverb,
{0, 99, 1}, // TGParameterMixingSendFXReverberator,
{0, 99, 1} // TGParameterMixingSendFXMainOutput,
#endif // MIXING_CONSOLE_ENABLE
};
// must match DexedVoiceParameters in Synth_Dexed
const CUIMenu::TParameter CUIMenu::s_VoiceParameter[] =
{
{0, 99, 1}, // DEXED_PITCH_EG_R1
{0, 99, 1}, // DEXED_PITCH_EG_R2
{0, 99, 1}, // DEXED_PITCH_EG_R3
{0, 99, 1}, // DEXED_PITCH_EG_R4
{0, 99, 1}, // DEXED_PITCH_EG_L1
{0, 99, 1}, // DEXED_PITCH_EG_L2
{0, 99, 1}, // DEXED_PITCH_EG_L3
{0, 99, 1}, // DEXED_PITCH_EG_L4
{0, 31, 1, ToAlgorithm}, // DEXED_ALGORITHM
{0, 7, 1}, // DEXED_FEEDBACK
{0, 1, 1, ToOnOff}, // DEXED_OSC_KEY_SYNC
{0, 99, 1}, // DEXED_LFO_SPEED
{0, 99, 1}, // DEXED_LFO_DELAY
{0, 99, 1}, // DEXED_LFO_PITCH_MOD_DEP
{0, 99, 1}, // DEXED_LFO_AMP_MOD_DEP
{0, 1, 1, ToOnOff}, // DEXED_LFO_SYNC
{0, 5, 1, ToLFOWaveform}, // DEXED_LFO_WAVE
{0, 7, 1}, // DEXED_LFO_PITCH_MOD_SENS
{0, 48, 1, ToTransposeNote}, // DEXED_TRANSPOSE
{0, 1, 1} // Voice Name - Dummy parameters for in case new item would be added in future
{0, 99, 1}, // DEXED_PITCH_EG_R1
{0, 99, 1}, // DEXED_PITCH_EG_R2
{0, 99, 1}, // DEXED_PITCH_EG_R3
{0, 99, 1}, // DEXED_PITCH_EG_R4
{0, 99, 1}, // DEXED_PITCH_EG_L1
{0, 99, 1}, // DEXED_PITCH_EG_L2
{0, 99, 1}, // DEXED_PITCH_EG_L3
{0, 99, 1}, // DEXED_PITCH_EG_L4
{0, 31, 1, ToAlgorithm}, // DEXED_ALGORITHM
{0, 7, 1}, // DEXED_FEEDBACK
{0, 1, 1, ToOnOff}, // DEXED_OSC_KEY_SYNC
{0, 99, 1}, // DEXED_LFO_SPEED
{0, 99, 1}, // DEXED_LFO_DELAY
{0, 99, 1}, // DEXED_LFO_PITCH_MOD_DEP
{0, 99, 1}, // DEXED_LFO_AMP_MOD_DEP
{0, 1, 1, ToOnOff}, // DEXED_LFO_SYNC
{0, 5, 1, ToLFOWaveform}, // DEXED_LFO_WAVE
{0, 7, 1}, // DEXED_LFO_PITCH_MOD_SENS
{0, 48, 1, ToTransposeNote}, // DEXED_TRANSPOSE
{0, 1, 1} // Voice Name - Dummy parameters for in case new item would be added in future
};
// must match DexedVoiceOPParameters in Synth_Dexed
const CUIMenu::TParameter CUIMenu::s_OPParameter[] =
{
{0, 99, 1}, // DEXED_OP_EG_R1
{0, 99, 1}, // DEXED_OP_EG_R2
{0, 99, 1}, // DEXED_OP_EG_R3
{0, 99, 1}, // DEXED_OP_EG_R4
{0, 99, 1}, // DEXED_OP_EG_L1
{0, 99, 1}, // DEXED_OP_EG_L2
{0, 99, 1}, // DEXED_OP_EG_L3
{0, 99, 1}, // DEXED_OP_EG_L4
{0, 99, 1, ToBreakpointNote}, // DEXED_OP_LEV_SCL_BRK_PT
{0, 99, 1}, // DEXED_OP_SCL_LEFT_DEPTH
{0, 99, 1}, // DEXED_OP_SCL_RGHT_DEPTH
{0, 3, 1, ToKeyboardCurve}, // DEXED_OP_SCL_LEFT_CURVE
{0, 3, 1, ToKeyboardCurve}, // DEXED_OP_SCL_RGHT_CURVE
{0, 7, 1}, // DEXED_OP_OSC_RATE_SCALE
{0, 3, 1}, // DEXED_OP_AMP_MOD_SENS
{0, 7, 1}, // DEXED_OP_KEY_VEL_SENS
{0, 99, 1}, // DEXED_OP_OUTPUT_LEV
{0, 1, 1, ToOscillatorMode}, // DEXED_OP_OSC_MODE
{0, 31, 1}, // DEXED_OP_FREQ_COARSE
{0, 99, 1}, // DEXED_OP_FREQ_FINE
{0, 14, 1, ToOscillatorDetune}, // DEXED_OP_OSC_DETUNE
{0, 1, 1, ToOnOff} // DEXED_OP_ENABLE
{0, 99, 1}, // DEXED_OP_EG_R1
{0, 99, 1}, // DEXED_OP_EG_R2
{0, 99, 1}, // DEXED_OP_EG_R3
{0, 99, 1}, // DEXED_OP_EG_R4
{0, 99, 1}, // DEXED_OP_EG_L1
{0, 99, 1}, // DEXED_OP_EG_L2
{0, 99, 1}, // DEXED_OP_EG_L3
{0, 99, 1}, // DEXED_OP_EG_L4
{0, 99, 1, ToBreakpointNote}, // DEXED_OP_LEV_SCL_BRK_PT
{0, 99, 1}, // DEXED_OP_SCL_LEFT_DEPTH
{0, 99, 1}, // DEXED_OP_SCL_RGHT_DEPTH
{0, 3, 1, ToKeyboardCurve}, // DEXED_OP_SCL_LEFT_CURVE
{0, 3, 1, ToKeyboardCurve}, // DEXED_OP_SCL_RGHT_CURVE
{0, 7, 1}, // DEXED_OP_OSC_RATE_SCALE
{0, 3, 1}, // DEXED_OP_AMP_MOD_SENS
{0, 7, 1}, // DEXED_OP_KEY_VEL_SENS
{0, 99, 1}, // DEXED_OP_OUTPUT_LEV
{0, 1, 1, ToOscillatorMode}, // DEXED_OP_OSC_MODE
{0, 31, 1}, // DEXED_OP_FREQ_COARSE
{0, 99, 1}, // DEXED_OP_FREQ_FINE
{0, 14, 1, ToOscillatorDetune}, // DEXED_OP_OSC_DETUNE
{0, 1, 1, ToOnOff} // DEXED_OP_ENABLE
};
const char CUIMenu::s_NoteName[100][4] =
@ -661,15 +677,14 @@ static const unsigned NoteC3 = 27;
const CUIMenu::TMenuItem CUIMenu::s_PerformanceMenu[] =
{
{"Load", PerformanceMenu, 0, 0},
{"Save", MenuHandler, s_SaveMenu},
{"Delete", PerformanceMenu, 0, 1},
{"Load", CUIMenu::PerformanceMenu, 0, 0},
{"Save", CUIMenu::MenuHandler, s_SaveMenu},
{"Delete", CUIMenu::PerformanceMenu, 0, 1},
{0}
};
CUIMenu::CUIMenu (CUserInterface *pUI, CMiniDexed *pMiniDexed)
: m_pUI (pUI),
CUIMenu::CUIMenu (CUserInterface *pUI, CMiniDexed *pMiniDexed) :
m_pUI (pUI),
m_pMiniDexed (pMiniDexed),
m_pParentMenu (s_MenuRoot),
m_pCurrentMenu (s_MainMenu),
@ -678,6 +693,7 @@ CUIMenu::CUIMenu (CUserInterface *pUI, CMiniDexed *pMiniDexed)
m_nCurrentParameter (0),
m_nCurrentMenuDepth (0)
{
assert(pMiniDexed);
}
void CUIMenu::EventHandler (TMenuEvent Event)

@ -139,7 +139,8 @@ private:
static const TMenuItem s_MainMenu[];
static const TMenuItem s_TGMenu[];
static const TMenuItem s_EffectsMenu[];
#ifdef MIXING_CONSOLE_ENABLE
#if defined(MIXING_CONSOLE_ENABLE)
static const TMenuItem s_TGFXMenu[];
static const TMenuItem s_FXTube[];
static const TMenuItem s_FXTubeReturn[];
static const TMenuItem s_FXChorus[];
@ -156,7 +157,7 @@ private:
#if defined(PLATE_REVERB_ENABLE) || defined(MIXING_CONSOLE_ENABLE)
static const TMenuItem s_FXPlateReverb[];
#endif
#ifdef MIXING_CONSOLE_ENABLE
#if defined(MIXING_CONSOLE_ENABLE)
static const TMenuItem s_FXPlateReverbReturn[];
static const TMenuItem s_FXReverberator[];
static const TMenuItem s_FXReverberatorReturn[];

@ -27,8 +27,13 @@
LOGMODULE ("ui");
CUserInterface::CUserInterface (CMiniDexed *pMiniDexed, CGPIOManager *pGPIOManager, CI2CMaster *pI2CMaster, CConfig *pConfig)
: m_pMiniDexed (pMiniDexed),
CUserInterface::CUserInterface (
CMiniDexed *pMiniDexed,
CGPIOManager *pGPIOManager,
CI2CMaster *pI2CMaster,
CConfig *pConfig
) :
m_pMiniDexed (pMiniDexed),
m_pGPIOManager (pGPIOManager),
m_pI2CMaster (pI2CMaster),
m_pConfig (pConfig),
@ -231,67 +236,90 @@ void CUserInterface::DisplayWrite (const char *pMenu, const char *pParam, const
LCDWrite (Msg);
}
#ifdef DEBUG
#include "cstring"
// #if defined(DEBUG)
#include <sstream>
#include <iomanip>
#include <sstream>
#include <cstring>
void CUserInterface::clear()
{
static size_t nbChars = this->m_pConfig->GetLCDColumns() * this->m_pConfig->GetLCDRows();
std::string txt("\x1B[H\E[?25l");
txt.append(nbChars, ' ');
txt.append("\x1B[K");
if (this->m_pLCDBuffered)
{
std::string txt("\x1B[H\E[?25l");
txt.append(nbChars, ' ');
txt.append("\x1B[K");
this->m_pLCDBuffered->Write(txt.c_str(), txt.length());
this->m_pLCDBuffered->Update ();
}
}
void CUserInterface::log(const char* txt)
void CUserInterface::log(const char* txt, bool clear)
{
if (this->m_pLCDBuffered)
{
if(clear)
{
this->clear();
}
this->m_pLCDBuffered->Write(txt, strlen(txt));
this->m_pLCDBuffered->Update ();
}
}
void CUserInterface::log(float32_t v)
void CUserInterface::log(float32_t v, bool clear)
{
std::ostringstream ss;
ss << std::fixed << std::setprecision(2) << v;
std::string txt = ss.str();
if (this->m_pLCDBuffered)
{
if(clear)
{
this->clear();
}
std::ostringstream ss;
ss << std::fixed << std::setprecision(2) << v;
std::string txt = ss.str();
this->m_pLCDBuffered->Write(txt.c_str(), txt.length());
this->m_pLCDBuffered->Update ();
}
}
void CUserInterface::log(unsigned v)
void CUserInterface::log(unsigned v, bool clear)
{
std::string txt = std::to_string(v);
if (this->m_pLCDBuffered)
{
if(clear)
{
this->clear();
}
std::string txt = std::to_string(v);
this->m_pLCDBuffered->Write(txt.c_str(), txt.length());
this->m_pLCDBuffered->Update ();
}
}
void CUserInterface::log(int v)
void CUserInterface::log(int v, bool clear)
{
std::string txt = std::to_string(v);
if (this->m_pLCDBuffered)
{
if(clear)
{
this->clear();
}
std::string txt = std::to_string(v);
this->m_pLCDBuffered->Write(txt.c_str(), txt.length());
this->m_pLCDBuffered->Update ();
}
}
#endif
// #endif
void CUserInterface::LCDWrite (const char *pString)
{

@ -23,6 +23,7 @@
#include "config.h"
#include "uimenu.h"
#include "uibuttons.h"
#include <arm_math_types.h>
#include <sensor/ky040.h>
#include <display/hd44780device.h>
#include <display/ssd1306device.h>
@ -35,7 +36,11 @@ class CMiniDexed;
class CUserInterface
{
public:
CUserInterface (CMiniDexed *pMiniDexed, CGPIOManager *pGPIOManager, CI2CMaster *pI2CMaster, CConfig *pConfig);
CUserInterface (
CMiniDexed *pMiniDexed,
CGPIOManager *pGPIOManager,
CI2CMaster *pI2CMaster,
CConfig *pConfig);
~CUserInterface (void);
bool Initialize (void);
@ -55,16 +60,16 @@ public:
// To be called from the MIDI device on reception of a MIDI CC message
void UIMIDICmdHandler (unsigned nMidiCh, unsigned nMidiCmd, unsigned nMidiData1, unsigned nMidiData2);
#ifdef DEBUG
// #ifdef DEBUG
public:
void clear();
void log(const char* txt);
void log(float32_t v);
void log(unsigned v);
void log(int v);
#else
void log(const char* txt, bool clear = true);
void log(float32_t v, bool clear = true);
void log(unsigned v, bool clear = true);
void log(int v, bool clear = true);
// #else
private:
#endif
// #endif
void LCDWrite (const char *pString); // Print to optional HD44780 display
private:

Loading…
Cancel
Save