1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-09 14:43:57 +01:00

Remove some naked new amd delete in: Built-in Effects

This commit is contained in:
Paul Licameli
2016-08-04 07:33:22 -04:00
parent 52d12c6913
commit 6fec00149b
22 changed files with 103 additions and 163 deletions

View File

@@ -154,14 +154,14 @@ bool EffectChangePitch::LoadFactoryDefaults()
bool EffectChangePitch::Init()
{
mSoundTouch = NULL;
mSoundTouch.reset();
return true;
}
bool EffectChangePitch::Process()
{
mSoundTouch = new SoundTouch();
SetTimeWarper(new IdentityTimeWarper());
mSoundTouch = std::make_unique<SoundTouch>();
SetTimeWarper(std::make_unique<IdentityTimeWarper>());
mSoundTouch->setPitchSemiTones((float)(m_dSemitonesChange));
#ifdef USE_MIDI
// Note: m_dSemitonesChange is private to ChangePitch because it only