pull/247/head
Holger Wirtz 3 years ago
parent 01f99031c5
commit c30a9c0dc6
  1. 17
      src/minidexed.cpp
  2. 3
      src/minidexed.h

@ -49,7 +49,8 @@ CMiniDexed::CMiniDexed (CConfig *pConfig, CInterruptSystem *pInterrupt,
#endif
m_GetChunkTimer ("GetChunk",
1000000U * pConfig->GetChunkSize ()/2 / pConfig->GetSampleRate ()),
m_bProfileEnabled (m_pConfig->GetProfileEnabled ())
m_bProfileEnabled (m_pConfig->GetProfileEnabled ()),
m_bSavePerformance (false)
{
assert (m_pConfig);
@ -272,6 +273,13 @@ void CMiniDexed::Process (bool bPlugAndPlayUpdated)
m_UI.Process ();
if (m_bSavePerformance)
{
DoSavePerformance ();
m_bSavePerformance = false;
}
if (m_bProfileEnabled)
{
m_GetChunkTimer.Dump ();
@ -950,6 +958,13 @@ void CMiniDexed::ProcessSound (void)
#endif
bool CMiniDexed::SavePerformance (void)
{
m_bSavePerformance = true;
return true;
}
bool CMiniDexed::DoSavePerformance (void)
{
for (unsigned nTG = 0; nTG < CConfig::ToneGenerators; nTG++)
{

@ -151,6 +151,7 @@ public:
bool SavePerformance (void);
void setMasterVolume (float32_t vol);
bool DoSavePerformance (void);
private:
int16_t ApplyNoteLimits (int16_t pitch, unsigned nTG); // returns < 0 to ignore note
@ -226,6 +227,8 @@ private:
AudioStereoMixer<CConfig::ToneGenerators>* reverb_send_mixer;
CSpinLock m_ReverbSpinLock;
bool m_bSavePerformance;
};
#endif

Loading…
Cancel
Save