123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114 |
- #include <QLayout>
- #include <QLabel>
- #include "BitcrushControlDialog.h"
- #include "BitcrushControls.h"
- #include "embed.h"
- #include "ToolTip.h"
- #include "LedCheckbox.h"
- #include "Knob.h"
- BitcrushControlDialog::BitcrushControlDialog( BitcrushControls * controls ) :
- EffectControlDialog( controls )
- {
- setAutoFillBackground( true );
- QPalette pal;
- pal.setBrush( backgroundRole(), PLUGIN_NAME::getIconPixmap( "artwork" ) );
- setPalette( pal );
- setFixedSize( 181, 128 );
-
-
- QLabel * inLabel = new QLabel( tr( "IN" ), this );
- inLabel->move( 24, 15 );
-
- QLabel * outLabel = new QLabel( tr( "OUT" ), this );
- outLabel->move( 139, 15 );
-
-
- Knob * inGain = new Knob( knobBright_26, this );
- inGain->move( 16, 32 );
- inGain->setModel( & controls->m_inGain );
- inGain->setLabel( tr( "GAIN" ) );
- inGain->setHintText( tr( "Input Gain:" ) + " ", " dBFS" );
-
- Knob * inNoise = new Knob( knobBright_26, this );
- inNoise->move( 14, 76 );
- inNoise->setModel( & controls->m_inNoise );
- inNoise->setLabel( tr( "NOISE" ) );
- inNoise->setHintText( tr( "Input Noise:" ) + " ", "%" );
-
-
-
- Knob * outGain = new Knob( knobBright_26, this );
- outGain->move( 138, 32 );
- outGain->setModel( & controls->m_outGain );
- outGain->setLabel( tr( "GAIN" ) );
- outGain->setHintText( tr( "Output Gain:" ) + " ", " dBFS" );
-
- Knob * outClip = new Knob( knobBright_26, this );
- outClip->move( 138, 76 );
- outClip->setModel( & controls->m_outClip );
- outClip->setLabel( tr( "CLIP" ) );
- outClip->setHintText( tr( "Output Clip:" ) + " ", "%" );
-
-
-
- LedCheckBox * rateEnabled = new LedCheckBox( "", this, tr( "Rate Enabled" ), LedCheckBox::Green );
- rateEnabled->move( 64, 14 );
- rateEnabled->setModel( & controls->m_rateEnabled );
- ToolTip::add( rateEnabled, tr( "Enable samplerate-crushing" ) );
-
- LedCheckBox * depthEnabled = new LedCheckBox( "", this, tr( "Depth Enabled" ), LedCheckBox::Green );
- depthEnabled->move( 101, 14 );
- depthEnabled->setModel( & controls->m_depthEnabled );
- ToolTip::add( depthEnabled, tr( "Enable bitdepth-crushing" ) );
-
-
-
- Knob * rate = new Knob( knobBright_26, this );
- rate->move( 59, 32 );
- rate->setModel( & controls->m_rate );
- rate->setLabel( tr( "FREQ" ) );
- rate->setHintText( tr( "Sample rate:" ) + " ", " Hz" );
-
- Knob * stereoDiff = new Knob( knobBright_26, this );
- stereoDiff->move( 72, 76 );
- stereoDiff->setModel( & controls->m_stereoDiff );
- stereoDiff->setLabel( tr( "STEREO" ) );
- stereoDiff->setHintText( tr( "Stereo difference:" ) + " ", "%" );
-
-
-
- Knob * levels = new Knob( knobBright_26, this );
- levels->move( 92, 32 );
- levels->setModel( & controls->m_levels );
- levels->setLabel( tr( "QUANT" ) );
- levels->setHintText( tr( "Levels:" ) + " ", "" );
- }
|