randomize PeakControllerEffect::m_effectId
This commit is contained in:
@@ -54,7 +54,6 @@ public:
|
||||
virtual QString nodeName() const;
|
||||
|
||||
static PeakControllerEffectVector s_effects;
|
||||
static int s_lastEffectId;
|
||||
|
||||
|
||||
public slots:
|
||||
|
||||
@@ -31,7 +31,6 @@
|
||||
|
||||
#include "embed.cpp"
|
||||
|
||||
|
||||
extern "C"
|
||||
{
|
||||
|
||||
@@ -61,6 +60,7 @@ PeakControllerEffect::PeakControllerEffect(
|
||||
Model * _parent,
|
||||
const Descriptor::SubPluginFeatures::Key * _key ) :
|
||||
Effect( &peakcontrollereffect_plugin_descriptor, _parent, _key ),
|
||||
m_effectId( rand() ),
|
||||
m_peakControls( this ),
|
||||
m_lastSample( 0 ),
|
||||
m_lastRMS( -1 ),
|
||||
|
||||
@@ -62,10 +62,6 @@ void PeakControllerEffectControls::loadSettings( const QDomElement & _this )
|
||||
m_amountMultModel.loadSettings( _this, "amountmult" );
|
||||
|
||||
int effectId = _this.attribute( "effectId" ).toInt();
|
||||
if( effectId > PeakController::s_lastEffectId )
|
||||
{
|
||||
PeakController::s_lastEffectId = effectId;
|
||||
}
|
||||
m_effect->m_effectId = effectId;
|
||||
|
||||
if( m_effect->m_autoController && ( engine::getSong()->isLoadingProject() == true || presetPreviewPlayHandle::isPreviewing() == false ) )
|
||||
|
||||
@@ -37,7 +37,6 @@
|
||||
#include "ControllerDialog.h"
|
||||
#include "plugins/peak_controller_effect/peak_controller_effect.h"
|
||||
|
||||
int PeakController::s_lastEffectId = 0;
|
||||
PeakControllerEffectVector PeakController::s_effects;
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user