Code simplifed

This commit is contained in:
Oskar Wallgren
2014-05-24 20:02:18 +02:00
parent 768f0e54b0
commit 2e78e65d59
4 changed files with 2 additions and 20 deletions

View File

@@ -174,8 +174,6 @@ private:
sample_t lfoShapeSample( fpp_t _frame_offset );
void updateLfoShapeData();
void updateRandomWave();
friend class EnvelopeAndLfoView;

View File

@@ -92,7 +92,6 @@ private:
ledCheckBox * m_controlEnvAmountCb;
float m_randomGraph;
void updateRandomGraph();
} ;
#endif

View File

@@ -221,7 +221,7 @@ inline sample_t EnvelopeAndLfoParameters::lfoShapeSample( fpp_t _frame_offset )
case RandomWave:
if( frame == 0 )
{
updateRandomWave();
m_random = Oscillator::noiseSample( 0.0f );
}
shape_sample = m_random;
break;
@@ -249,14 +249,6 @@ void EnvelopeAndLfoParameters::updateLfoShapeData()
void EnvelopeAndLfoParameters::updateRandomWave()
{
m_random = Oscillator::noiseSample( 0.0f );
}
inline void EnvelopeAndLfoParameters::fillLfoLevel( float * _buf,
f_cnt_t _frame,
const fpp_t _frames )

View File

@@ -537,7 +537,7 @@ void EnvelopeAndLfoView::paintEvent( QPaintEvent * )
case EnvelopeAndLfoParameters::RandomWave:
if( x % (int)( 900 * m_lfoSpeedKnob->value<float>() + 1 ) == 0 )
{
updateRandomGraph();
m_randomGraph = Oscillator::noiseSample( 0.0f );
}
val = m_randomGraph;
break;
@@ -572,13 +572,6 @@ void EnvelopeAndLfoView::paintEvent( QPaintEvent * )
void EnvelopeAndLfoView::updateRandomGraph()
{
m_randomGraph = Oscillator::noiseSample( 0.0f );
}
void EnvelopeAndLfoView::lfoUserWaveChanged()
{