|
- # data file for the Fltk User Interface Designer (fluid)
- version 1.0302
- header_name {.h}
- code_name {.cc}
- decl {//Copyright (c) 2002-2005 Nasca Octavian Paul} {private local
- }
-
- decl {//License: GNU GPL version 2 or later} {private local
- }
-
- decl {\#include "../Params/ADnoteParameters.h"} {public local
- }
- decl {\#include "ResonanceUI.h"} {public local
- }
-
- decl {\#include "Fl_Osc_Slider.H"} {public local
- }
-
- decl {\#include <FL/Fl_Box.H>} {public local
- }
-
- decl {\#include <FL/Fl_Group.H>} {public local
- }
-
- decl {\#include <cmath>} {private local
- }
-
- decl {\#include <cstdio>} {private local
- }
-
- decl {\#include <cstdlib>} {private local
- }
-
- decl {\#include <cstring>} {private local
- }
-
- decl {\#include "Fl_Osc_Pane.H"} {public local
- }
-
- decl {\#include "Fl_Osc_Dial.H"} {public local
- }
-
- decl {\#include "Fl_Osc_Check.H"} {public local
- }
-
- decl {\#include "Fl_Osc_Choice.H"} {public local
- }
-
- decl {\#include "Fl_Osc_Slider.H"} {public local
- }
-
- decl {\#include "Fl_Osc_VSlider.H"} {public local
- }
-
- decl {\#include "Fl_Oscilloscope.h"} {public local
- }
-
- decl {\#include "EnvelopeUI.h"} {public local
- }
-
- decl {\#include "LFOUI.h"} {public local
- }
-
- decl {\#include "FilterUI.h"} {public local
- }
-
- decl {\#include "OscilGenUI.h"} {public local
- }
-
- decl {\#include "PresetsUI.h"} {public local
- }
-
- class ADvoicelistitem {open : {public Fl_Osc_Group}
- } {
- Function {make_window()} {open private
- } {
- Fl_Window ADnoteVoiceListItem {open
- private xywh {346 881 615 100} type Double box UP_FRAME
- class Fl_Osc_Group visible
- } {
- Fl_Box {} {
- xywh {0 0 0 0}
- code0 {ADnoteVoiceListItem->base = loc;}
- }
- Fl_Group voicelistitemgroup {open
- private xywh {50 0 570 25}
- class Fl_Osc_Group
- } {
- Fl_Value_Slider voicevolume {
- tooltip Volume xywh {90 5 115 20} type {Horz Knob} box NO_BOX labelsize 8 align 5 maximum 127 step 1
- code1 {o->init("PVolume");}
- class Fl_Osc_VSlider
- }
- Fl_Check_Button voiceresonanceenabled {
- tooltip {Resonance On/Off} xywh {245 7 15 17} down_box DOWN_BOX labeltype EMBOSSED_LABEL labelfont 1 labelsize 11 align 4
- code0 {o->init("Presonance");}
- class Fl_Osc_Check
- }
- Fl_Value_Slider voicelfofreq {
- tooltip {Frequency LFO amount} xywh {500 5 115 20} type {Horz Knob} box NO_BOX labelsize 8 align 5 maximum 127 step 1
- code0 {o->init("FreqLfo/Pintensity", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Dial voicepanning {
- tooltip {Panning (leftmost is Random)} xywh {215 5 20 20} box ROUND_UP_BOX labelsize 10 align 4 maximum 127 step 1
- code0 {o->init("PPanning");}
- class Fl_Osc_Dial
- }
- Fl_Group voiceoscil {open
- xywh {60 5 30 20} box THIN_DOWN_BOX color 32 selection_color 71 labelcolor 179
- code0 {voiceoscil->ext = "OscilSmp/";}
- code1 {oscil=new Fl_Oscilloscope(o->x(),o->y(),o->w(),o->h(),"");}
- code2 {oscil->init(false);}
- class Fl_Osc_Group
- } {}
- Fl_Value_Output detunevalueoutput {
- xywh {265 5 45 20} labelsize 10 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 10
- code0 {o->init("detunevalue");}
- class Fl_Osc_Output
- }
- Fl_Slider voicedetune {
- callback {//detunevalueoutput->do_callback();}
- tooltip {Fine Detune (cents)} xywh {315 5 185 20} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
- code0 {o->init("PDetune",'i');}
- class Fl_Osc_Slider
- }
- Fl_Box noiselabel {
- label N
- xywh {65 5 20 20} labelfont 1 labelsize 13 labelcolor 7
- }
- Fl_Check_Button noisehack {
- callback {if (o->value()==0) {
- noiselabel->hide();
- voiceresonanceenabled->activate();
- detunevalueoutput->activate();
- voicedetune->activate();
- voicelfofreq->activate();
- voiceoscil->activate();
- } else {
- noiselabel->show();
- voiceresonanceenabled->deactivate();
- detunevalueoutput->deactivate();
- voicedetune->deactivate();
- voicelfofreq->deactivate();
- voiceoscil->deactivate();
- };}
- xywh {0 0 0 0} down_box DOWN_BOX
- code0 {o->init("Type");o->hide();}
- class Fl_Osc_Check
- }
- }
- Fl_Check_Button voiceenabled {
- label 01
- callback {if (o->value()==0) voicelistitemgroup->deactivate();
- else voicelistitemgroup->activate();
- o->redraw();}
- private xywh {30 5 20 20} down_box DOWN_BOX labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 4
- code0 {char tmp[10];snprintf(tmp,10,"%d",nvoice+1);o->label(strdup(tmp));}
- code1 {o->init("Enabled");}
- class Fl_Osc_Check
- }
- }
- }
- Function {ADvoicelistitem(int x,int y, int w, int h, const char *label=0):Fl_Osc_Group(x,y,w,h,label)} {open
- } {
- code {assert(osc);
- nvoice=0;} {}
- }
- Function {init(int nvoice_, std::string loc_, Fl_Osc_Interface *osc_)} {open
- } {
- code {assert(osc_);
- assert(!loc_.empty());
-
- nvoice=nvoice_;
- loc = loc_;
- make_window();
- ADnoteVoiceListItem->show();
- end();} {}
- }
- Function {refreshlist()} {open
- } {
- code {if (voiceenabled->value()==0) voicelistitemgroup->deactivate();
- else voicelistitemgroup->activate();
- detunevalueoutput->do_callback();
- ADnoteVoiceListItem->redraw();} {}
- }
- Function {~ADvoicelistitem()} {} {
- code {ADnoteVoiceListItem->hide();} {}
- }
- decl {int nvoice;} {private local
- }
- decl {Fl_Oscilloscope *oscil;} {private local
- }
- decl {std::string loc;} {private local
- }
- }
-
- class ADvoiceUI {open : {public Fl_Group}
- } {
- Function {make_window()} {open
- } {
- Fl_Window ADnoteVoiceParameters {
- label Voice open
- xywh {512 391 765 595} type Double box NO_BOX
- class Fl_Osc_Group visible
- } {
- Fl_Box {} {
- label label
- xywh {25 25 35 16}
- code0 {ADnoteVoiceParameters->base = base+"VoicePar"+to_s(nvoice)+"/";}
- code1 {ADnoteVoiceParameters->osc = osc_i;}
- }
- Fl_Group voiceparametersgroup {open
- xywh {0 0 770 590} color 48
- } {
- Fl_Group voicemodegroup {open
- xywh {0 5 770 585} color 64
- } {
- Fl_Group voiceFMparametersgroup {
- label MODULATOR open
- xywh {530 5 230 580} box UP_FRAME color 48 labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Group modfrequency {
- label {Mod.FREQUENCY}
- xywh {535 220 220 155} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Group voiceFMfreqenvgroup {
- label {ADSynth Modulator - Frequency Envelope}
- xywh {540 300 210 70} box FLAT_BOX color 51 align 144
- code0 {o->init(ENV_ASR, osc_i, loc, "FMFreqEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voiceFMfreqenvgroup->deactivate();
- else voiceFMfreqenvgroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {545 305 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PFMFreqEnvelopeEnabled");}
- class Fl_Osc_Check
- }
- Fl_Counter {} {
- label {Coarse Det.}
- tooltip {Coarse Detune} xywh {685 280 60 15} labelsize 10 align 1 minimum -64 maximum 63 step 1 textfont 1 textsize 11
- code0 {o->init("FMcoarsedetune");}
- code3 {o->lstep(10);}
- class Fl_Osc_Counter
- }
- Fl_Counter {} {
- label Octave
- tooltip Octave xywh {625 280 45 15} type Simple labelsize 10 align 1 minimum -8 maximum 7 step 1 textfont 1 textsize 11
- code0 {o->init("FMoctave");}
- class Fl_Osc_Counter
- }
- Fl_Slider {} {
- callback {o->oscWrite("detunevalue");}
- tooltip {Fine Detune (cents)} xywh {590 245 155 15} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
- code0 {o->init("PFMDetune", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Value_Output fmdetunevalueoutput {
- label Detune
- xywh {540 245 45 18} labelsize 8 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 8
- code0 {o->init("FMdetunevalue");}
- class Fl_Osc_Output
- }
- Fl_Choice {} {
- label {Detune Type}
- callback {fmdetunevalueoutput->do_callback();} open
- xywh {540 280 75 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
- code0 {o->add("Default");o->add("L35cents");o->add("L10cents");o->add("E100cents");o->add("E1200cents");}
- code1 {o->init("PFMDetuneType");}
- class Fl_Osc_Choice
- } {}
- }
- Fl_Group {} {
- label {Mod.AMPLITUDE}
- xywh {535 60 220 160} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Value_Slider {} {
- label Vol
- tooltip Volume xywh {540 80 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
- code0 {o->init("PFMVolume", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Value_Slider {} {
- label {V.Sns}
- tooltip {Velocity Sensing Function (rightmost to disable)} xywh {540 100 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
- code0 {o->init("PFMVelocityScaleFunction");}
- class Fl_Osc_VSlider
- }
- Fl_Group voiceFMampenvgroup {
- label {ADSynth Modulator - Amplitude Envelope} open
- xywh {540 145 205 70} box FLAT_BOX color 51 align 144
- code0 {o->init(//pars->VoicePar[nvoice].FMAmpEnvelope,
- ENV_ADSR, osc_i, loc, "FMAmpEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voiceFMampenvgroup->deactivate();
- else voiceFMampenvgroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {545 150 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PFMAmpEnvelopeEnabled");}
- class Fl_Osc_Check
- }
- Fl_Value_Slider {} {
- label {F.Damp}
- tooltip {Modulator Damp at Higher frequency} xywh {540 120 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 minimum -64 maximum 63 step 1
- code0 {o->init("PFMVolumeDamp",'i');}
- class Fl_Osc_Slider
- }
- }
- Fl_Group modoscil {open
- xywh {535 365 220 220}
- } {
- Fl_Group fmoscil {open
- xywh {535 440 220 140} box THIN_DOWN_BOX color 32 selection_color 71 labelcolor 179
- code0 {fmoscil->base = loc; fmoscil->ext="FMSmp/";fmoscil->osc = osc_i;fmoscil->begin();}
- code1 {oscFM=new Fl_Oscilloscope(o->x(),o->y(),o->w(),o->h(),"");}
- code2 {//int nv=nvoice; if (pars->VoicePar[nvoice].PextFMoscil>=0) nv=pars->VoicePar[nvoice].PextFMoscil;}
- code3 {oscFM->parent(fmoscil);oscFM->init(false);oscFM->update();fmoscil->end();}
- class Fl_Osc_Group
- } {}
- Fl_Box {} {
- label {Mod.Oscillator}
- xywh {535 375 155 20} labelfont 1 align 20
- }
- Fl_Button changeFMoscilbutton {
- label Change
- callback {if (oscedit!=NULL)
- delete(oscedit);
-
- //int nv=nvoice;
- //if (extFMoscil->value()>=0)
- // nv=extFMoscil->value();
-
- oscedit=new OscilEditor(true, loc+"FMSmp/", osc_i);}
- xywh {700 380 55 15} box THIN_UP_BOX labelfont 1 labelsize 11
- code0 {(void)o;/*if (extFMoscil->value()>=0) o->labelcolor(FL_BLUE);*/}
- }
- Fl_Slider {} {
- label Phase
- callback {oscFM->phase=64-(int) o->value();
- fmoscil->redraw();}
- xywh {645 415 105 15} type {Horz Knob} box NO_BOX labelsize 10 align 5 minimum -64 maximum 63 step 1
- code0 {o->init("PFMoscilphase", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Choice extFMoscil {
- label Use
- callback {if ((int) o->value() != 0) {
- oscFM->init(false);
- changeFMoscilbutton->labelcolor(FL_BLUE);
- } else {
- oscFM->init(false);
- changeFMoscilbutton->labelcolor(FL_BLACK);
- };
- voiceFMparametersgroup->redraw();} open
- xywh {560 410 75 20} down_box BORDER_BOX labelsize 10 textfont 1 textsize 10
- code0 {o->add("Internal");}
- code1 {char tmp[50]; for (int i=0;i<nvoice;i++) {sprintf(tmp,"ExtM.%2d",i+1);o->add(tmp);};}
- code3 {o->init("PextFMoscil",1);}
- class Fl_Osc_Choice
- } {}
- }
- Fl_Choice {} {
- label {External Mod.}
- callback {if ((int) o->value() != 0) {
- modoscil->deactivate();
- modfrequency->deactivate();
- } else {
- modoscil->activate();
- modfrequency->activate();
- };
- voiceFMparametersgroup->redraw();} open
- xywh {635 40 85 20} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
- code0 {o->add("OFF");}
- code1 {char tmp[50]; for (int i=0;i<nvoice;i++) {sprintf(tmp,"ExtMod.%2d",i+1);o->add(tmp);};}
- code2 {o->init("PFMVoice", -1);}
- code3 {if ((int) o->value() != 0) {modoscil->deactivate();modfrequency->deactivate();}}
- class Fl_Osc_Choice
- } {}
- }
- Fl_Choice {} {
- label {Type:}
- callback {if (o->value()==0) voiceFMparametersgroup->deactivate();
- else voiceFMparametersgroup->activate();
- o->redraw();}
- xywh {535 40 80 20} down_box BORDER_BOX align 5
- code0 {o->init("PFMEnabled");}
- class Fl_Osc_Choice
- } {
- MenuItem {} {
- label OFF
- xywh {40 40 100 20} labelfont 1
- }
- MenuItem {} {
- label MORPH
- xywh {50 50 100 20} labelfont 1
- }
- MenuItem {} {
- label RING
- xywh {60 60 100 20} labelfont 1
- }
- MenuItem {} {
- label PM
- xywh {70 70 100 20} labelfont 1
- }
- MenuItem {} {
- label FM
- xywh {80 80 100 20} labelfont 1
- }
- MenuItem {} {
- label PITCH
- xywh {90 90 100 20} labelfont 1 deactivate
- }
- }
- Fl_Group {} {
- label FREQUENCY open
- xywh {5 265 525 120} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Group voicefreqenvgroup {
- label {ADSynth Voice - Frequency Envelope} open
- xywh {10 305 205 70} box FLAT_BOX color 51 align 144
- code0 {o->init(//pars->VoicePar[nvoice].FreqEnvelope,
- ENV_ASR, osc_i, loc, "FreqEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voicefreqenvgroup->deactivate();
- else voicefreqenvgroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {15 310 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PFreqEnvelopeEnabled");}
- class Fl_Osc_Check
- }
- Fl_Group voicefreqlfogroup {
- label {Frequency LFO } open
- xywh {220 305 230 70} box FLAT_BOX color 47 align 144
- code0 {o->init(osc_i, loc,"FreqLfo/");}
- class LFOUI
- } {}
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voicefreqlfogroup->deactivate();
- else voicefreqlfogroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {225 311 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PFreqLfoEnabled");}
- class Fl_Osc_Check
- }
- Fl_Counter {} {
- label Octave
- tooltip Octave xywh {470 285 45 15} type Simple labelsize 10 align 1 minimum -8 maximum 7 step 1 textfont 1 textsize 11
- code0 {o->init("octave");}
- class Fl_Osc_Counter
- }
- Fl_Counter {} {
- label {Coarse Det.}
- tooltip {Coarse Detune} xywh {455 355 60 20} labelsize 10 align 1 minimum -64 maximum 63 step 1 textfont 1 textsize 11
- code0 {o->init("coarsedetune");}
- code3 {o->lstep(10);}
- class Fl_Osc_Counter
- }
- Fl_Slider {} {
- callback {detunevalueoutput->do_callback();}
- tooltip {Fine Detune (cents)} xywh {58 287 392 13} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
- code0 {o->init("PDetune", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Value_Output detunevalueoutput {
- label Detune
- code0 {o->init("detunevalue");}
- xywh {10 287 45 15} labelsize 10 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 10
- class Fl_Osc_Output
- }
- Fl_Check_Button {} {
- label 440Hz
- callback {if (o->value()==0) fixedfreqetdial->deactivate();
- else fixedfreqetdial->activate();}
- tooltip {Set the voice base frequency to 440Hz} xywh {345 268 55 15} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("Pfixedfreq");}
- class Fl_Osc_Check
- }
- Fl_Dial fixedfreqetdial {
- label {Eq.T.}
- tooltip {How the frequency varies acording to the keyboard (leftmost for fixed frequency)} xywh {405 270 15 15} box ROUND_UP_BOX labelsize 10 align 8 maximum 127 step 1
- code0 {o->init("PfixedfreqET");}
- class Fl_Osc_Dial
- }
- Fl_Choice {} {
- label {Detune Type}
- callback {detunevalueoutput->do_callback();} open
- xywh {455 320 70 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
- code0 {o->add("Default");o->add("L35cents");o->add("L10cents");o->add("E100cents");o->add("E1200cents");}
- code1 {o->init("PDetuneType");}
- class Fl_Osc_Choice
- } {}
- }
- Fl_Group voiceoscil {
- xywh {80 390 445 145} box THIN_DOWN_BOX color 32 selection_color 71 labelcolor 179
- code0 {voiceoscil->base = loc;voiceoscil->ext="OscilSmp/";voiceoscil->begin();//int nv=nvoice; if (extoscil->value()>=0) nv=extoscil->value();}
- code1 {osc=new Fl_Oscilloscope(o->x(),o->y(),o->w(),o->h(),"");}
- code2 {voiceoscil->osc = osc_i;}
- code3 {osc->parent(voiceoscil); osc->init(false);voiceoscil->end();}
- class Fl_Osc_Group
- } {}
- Fl_Button changevoiceoscilbutton {
- label Change
- callback {delete oscedit;
- //if(extoscil->value()>=0)
- // nv=extoscil->value();
-
- oscedit=new OscilEditor(true,loc+"OscilSmp/", osc_i);}
- xywh {5 490 65 20} box THIN_UP_BOX labelfont 1 labelsize 11
- code0 {(void)o;/*if (extoscil->value()>=0) o->labelcolor(FL_BLUE);*/}
- }
- Fl_Box {} {
- label {Voice Oscillator}
- xywh {5 390 75 35} labelfont 1 labelsize 12 align 128
- }
- Fl_Slider {} {
- label Phase
- callback {osc->phase=64-(int) o->value();
- voiceoscil->redraw();}
- xywh {10 435 65 10} type {Horz Knob} box NO_BOX labelsize 10 align 5 minimum -64 maximum 63 step 1
- code0 {o->init("Poscilphase", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Check_Button {} {
- label {R.}
- tooltip {Resonance On/Off} xywh {210 5 35 35} box THIN_UP_BOX down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("Presonance");}
- class Fl_Osc_Check
- }
- Fl_Choice extoscil {
- label {Use Oscil.}
- callback {if ((int) o->value() != 0) {
- osc->init(false);
- changevoiceoscilbutton->labelcolor(FL_BLUE);
- } else {
- osc->init(false);
- changevoiceoscilbutton->labelcolor(FL_BLACK);
- };
-
- voiceparametersgroup->redraw();
- voiceonbutton->redraw();} open
- xywh {5 470 65 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
- code0 {o->add("Internal");}
- code1 {char tmp[50]; for (int i=0;i<nvoice;i++) {sprintf(tmp,"Ext.%2d",i+1);o->add(tmp);};}
- code3 {o->init("Pextoscil",1);}
- class Fl_Osc_Choice
- } {}
- Fl_Group {} {open
- xywh {5 540 520 50} box UP_FRAME
- } {
- Fl_Dial {} {
- label Stereo
- tooltip {Stereo Spread} xywh {322 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("Unison_stereo_spread");}
- class Fl_Osc_Dial
- }
- Fl_Choice {} {
- label Unison
- tooltip {Unison size} xywh {10 560 75 20} down_box BORDER_BOX labelfont 1 align 5 textfont 1 textsize 10
- code0 {o->add("OFF");char tmp[100];for (int i=1;ADnote_unison_sizes[i];i++){snprintf(tmp,100,"size %d",ADnote_unison_sizes[i]);o->add(tmp);};}
- code1 {o->init("Unison_size");}
- class Fl_Osc_Choice
- } {}
- Fl_Dial {} {
- label Vibrato
- tooltip Vibrato xywh {364 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("Unison_vibratto");}
- class Fl_Osc_Dial
- }
- Fl_Choice {} {
- label Invert
- tooltip {Phase Invert} xywh {445 560 65 15} down_box BORDER_BOX labelsize 11 align 5 textfont 1 textsize 10
- code0 {o->add("None");o->add("Random");char tmp[100];for (int i=2;i<=5;i++){snprintf(tmp,100,"%d %%",100/i);o->add(tmp);};}
- code1 {o->init("Unison_invert_phase");}
- class Fl_Osc_Choice
- } {}
- Fl_Slider {} {
- label {Frequency Spread}
- callback {unisonspreadoutput->update();}
- tooltip {Frequency Spread of the Unison} xywh {95 562 125 13} type {Horz Knob} box NO_BOX labelsize 12 align 1 maximum 127 step 1 value 64
- code0 {o->init("Unison_frequency_spread", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Value_Output unisonspreadoutput {
- label {(cents)}
- xywh {225 560 40 15} labelsize 10 align 5 maximum 1000 step 0.1 textfont 1 textsize 10
- code0 {o->init("unisonFrequencySpreadCents");//o->value(pars->getUnisonFrequencySpreadCents(nvoice));}
- class Fl_Osc_Output
- }
- Fl_Dial {} {
- label {V.speed}
- tooltip {Vibrato Average Speed} xywh {406 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("Unison_vibratto_speed");}
- class Fl_Osc_Dial
- }
- Fl_Dial {} {
- label {Ph.rand}
- tooltip {Phase randomness} xywh {280 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("Unison_phase_randomness");}
- class Fl_Osc_Dial
- }
- }
- }
- Fl_Group {} {
- label AMPLITUDE open
- xywh {5 40 240 220} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Value_Slider {} {
- label Vol
- tooltip Volume xywh {10 60 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
- code0 {o->init("PVolume");}
- class Fl_Osc_VSlider
- }
- Fl_Value_Slider {} {
- label {V.Sns}
- tooltip {Velocity Sensing Function (rightmost to disable)} xywh {10 80 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
- code0 {o->init("PAmpVelocityScaleFunction");}
- class Fl_Osc_VSlider
- }
- Fl_Group voiceampenvgroup {
- label {ADSynth Voice - Amplitude Envelope} open
- xywh {10 105 205 70} box FLAT_BOX color 51 align 144
- code0 {o->init(//pars->VoicePar[nvoice].AmpEnvelope,
- ENV_ADSR, osc_i, loc, "AmpEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Dial {} {
- label Pan
- tooltip {Panning (leftmost is Random)} xywh {210 60 30 30} box ROUND_UP_BOX labelsize 10 maximum 127 step 1
- code0 {o->init("PPanning");}
- class Fl_Osc_Dial
- }
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voiceampenvgroup->deactivate();
- else voiceampenvgroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {15 110 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PAmpEnvelopeEnabled");}
- class Fl_Osc_Check
- }
- Fl_Group voiceamplfogroup {
- label {Amplitude LFO } open
- xywh {10 180 230 75} box FLAT_BOX color 47 align 144
- code0 {o->init(osc_i, loc, "AmpLfo/");}
- class LFOUI
- } {}
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voiceamplfogroup->deactivate();
- else voiceamplfogroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {15 185 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PAmpLfoEnabled");}
- class Fl_Osc_Check
- }
- Fl_Check_Button {} {
- label Minus
- xywh {10 45 50 10} down_box DOWN_BOX labelfont 1 labelsize 10
- code0 {o->init("PVolumeminus");}
- class Fl_Osc_Check
- }
- }
- Fl_Group voicefiltergroup {
- label FILTER open
- xywh {245 5 285 260} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Group {} {
- label {ADsynth Voice - Filter} open
- xywh {250 30 275 75} box FLAT_BOX color 50 align 144
- code0 {o->init("", osc_i, loc, "VoiceFilter/");}
- class FilterUI
- } {}
- Fl_Group voicefilterenvgroup {
- label {ADSynth Voice - Filter Envelope} open
- xywh {250 115 275 70} box FLAT_BOX color 51 align 144
- code0 {o->init(
- ENV_ADSR_FILTER, osc_i, loc, "FilterEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voicefilterenvgroup->deactivate();
- else voicefilterenvgroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {255 119 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PFilterEnvelopeEnabled");}
- class Fl_Osc_Check
- }
- Fl_Group voicefilterlfogroup {
- label {Filter LFO } open
- xywh {250 190 230 70} box FLAT_BOX color 47 align 144
- code0 {o->init(osc_i, loc, "FilterLfo/");}
- class LFOUI
- } {}
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voicefilterlfogroup->deactivate();
- else voicefilterlfogroup->activate();
- o->redraw();}
- tooltip {Forced Release} xywh {255 196 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PFilterLfoEnabled");}
- class Fl_Osc_Check
- }
- }
- Fl_Group activeVoiceID {
- label 01
- xywh {5 5 55 35} box THIN_UP_BOX labeltype EMBOSSED_LABEL labelfont 1 labelsize 22 align 16
- code0 {char tmp[10];snprintf(tmp,10,"%d",nvoice+1);o->label(strdup(tmp));}
- } {}
- Fl_Choice {} {
- callback {if (o->value()==0){ voicemodegroup->activate(); noiselabel->hide();}
- else{ voicemodegroup->deactivate(); noiselabel->show();}}
- tooltip {Oscillator Type (sound/noise)} xywh {5 515 65 20} down_box BORDER_BOX labelsize 10 textfont 1 textsize 10
- code0 {o->init("Type");}
- class Fl_Osc_Choice
- } {
- MenuItem {} {
- label Sound
- xywh {5 5 100 20} labelfont 1 labelsize 11
- }
- MenuItem {} {
- label NOISE
- xywh {15 15 100 20} labelfont 1 labelsize 11 labelcolor 1
- }
- }
- Fl_Check_Button bypassfiltercheckbutton {
- label {Bypass Global F.}
- xywh {425 10 100 20} down_box DOWN_BOX labelfont 1 labelsize 10 align 148
- code0 {o->init("Pfilterbypass");}
- class Fl_Osc_Check
- }
- Fl_Group {} {open
- xywh {115 5 95 35} box THIN_UP_BOX
- } {
- Fl_Value_Slider {} {
- label Delay
- tooltip Volume xywh {120 21 84 12} type {Horz Knob} box NO_BOX labelsize 11 align 5 maximum 127 step 1
- code0 {o->init("PDelay");}
- class Fl_Osc_VSlider
- }
- }
- Fl_Check_Button {} {
- label On
- callback {if (o->value()==0) voicefiltergroup->deactivate();
- else voicefiltergroup->activate();
- o->redraw();
- bypassfiltercheckbutton->redraw();}
- tooltip {Enable Filter} xywh {250 15 60 15} down_box DOWN_BOX labelfont 1 labelsize 11
- code0 {o->init("PFilterEnabled");}
- class Fl_Osc_Check
- }
- Fl_Box noiselabel {
- label {White Noise}
- xywh {150 430 300 65} labelfont 1 labelsize 50 labelcolor 53 hide
- }
- }
- Fl_Check_Button voiceonbutton {
- label On
- callback {if (o->value()==0) voiceparametersgroup->deactivate();
- else voiceparametersgroup->activate();
- o->redraw();}
- xywh {60 5 55 35} box THIN_UP_BOX down_box DOWN_BOX labelfont 1 labelsize 13
- code0 {o->init("Enabled");}
- class Fl_Osc_Check
- }
- }
- }
- Function {ADvoiceUI(int x,int y, int w, int h, const char *label=0):Fl_Group(x,y,w,h,label)} {} {
- code {nvoice=0;
- oscedit=NULL;} {}
- }
- Function {init(int nvoice_, std::string loc_, Fl_Osc_Interface *osc_)} {open
- } {
- code {assert(osc_);
- assert(!loc_.empty());
- nvoice=nvoice_;
- loc=loc_+"VoicePar"+to_s(nvoice)+"/";
- base = loc_;
- osc_i=osc_;
- make_window();
- end();
- ADnoteVoiceParameters->show();} {}
- }
- Function {~ADvoiceUI()} {open
- } {
- code {ADnoteVoiceParameters->hide();
- hide();
- delete(oscedit);
- //delete (ADnoteVoiceParameters);} {}
- }
- Function {change_voice(int nvoice_)} {open
- } {
- code {nvoice = nvoice_;
- loc = base+"VoicePar"+to_s(nvoice)+"/";
- char tmp[10];snprintf(tmp,10,"%d",nvoice+1);
- activeVoiceID->label(strdup(tmp));
- ADnoteVoiceParameters->rebase(base+"VoicePar"+to_s(nvoice)+"/");} {selected
- }
- }
- decl {int nvoice;} {private local
- }
- decl {OscilEditor *oscedit;} {private local
- }
- decl {Fl_Oscilloscope *osc;} {private local
- }
- decl {Fl_Oscilloscope *oscFM;} {private local
- }
- decl {std::string loc;} {private local
- }
- decl {std::string base;} {private local
- }
- decl {Fl_Osc_Interface *osc_i;} {private local
- }
- }
-
- class ADnoteUI {open : {public PresetsUI_}
- } {
- Function {make_window()} {open private
- } {
- Fl_Window ADnoteGlobalParameters {
- label {ADsynth Global Parameters of the Instrument} open
- xywh {688 551 540 430} type Double
- class Fl_Osc_Window visible
- } {
- Fl_Box {} {
- xywh {0 0 0 0}
- code0 {ADnoteGlobalParameters->base = loc + "GlobalPar/"; ADnoteGlobalParameters->osc = osc;}
- }
- Fl_Group {} {
- label FREQUENCY open
- xywh {5 280 530 115} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Group freqenv {
- label {ADSynth Global - Frequency Envelope} open
- xywh {10 320 205 70} box FLAT_BOX color 51 align 144
- code0 {o->init(ENV_ASR, osc, loc, "GlobalPar/FreqEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Counter octave {
- label Octave
- tooltip Octave xywh {455 300 45 15} type Simple labelsize 10 align 1 minimum -8 maximum 7 step 1 textfont 1 textsize 11
- code0 {o->init("octave");}
- class Fl_Osc_Counter
- }
- Fl_Counter coarsedet {
- label {Coarse det.}
- tooltip {Coarse Detune} xywh {460 370 60 20} type Simple labelsize 10 align 5 minimum -64 maximum 63 step 1 textfont 1 textsize 11
- code0 {o->init("coarsedetune");}
- code3 {o->lstep(10);}
- class Fl_Osc_Counter
- }
- Fl_Group freqlfo {
- label {Frequency LFO } open
- xywh {220 320 230 70} box FLAT_BOX color 47 align 144
- code0 {o->init(osc, loc, "GlobalPar/FreqLfo/");}
- class LFOUI
- } {}
- Fl_Slider detune {
- callback {o->oscWrite("detunevalue");}
- tooltip {Fine Detune (cents)} xywh {60 300 385 15} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
- code0 {o->init("PDetune", 'i');}
- class Fl_Osc_Slider
- }
- Fl_Value_Output detunevalueoutput {
- label Detune
- xywh {12 300 45 15} labelsize 10 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 10
- code0 {o->init("detunevalue");}
- class Fl_Osc_Output
- }
- Fl_Choice detunetype {
- label {Detune Type}
- callback {o->oscWrite("detunevalue");} open
- xywh {455 340 75 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
- code0 {o->add("L35cents");o->add("L10cents");o->add("E100cents");o->add("E1200cents");}
- code1 {o->init("PDetuneType",1);}
- class Fl_Osc_Choice
- } {}
- Fl_Dial {} {
- label relBW
- callback {for (int i=0;i<NUM_VOICES;i++){
- voicelistitem[i]->refreshlist();
- };}
- tooltip {Bandwidth - how the relative fine detune of the voice are changed} xywh {505 295 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("PBandwidth");}
- class Fl_Osc_Dial
- }
- }
- Fl_Group {} {
- label AMPLITUDE open
- xywh {5 5 240 260} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Value_Slider volume {
- label Vol
- tooltip Volume xywh {10 30 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
- code0 {o->init("PVolume");}
- class Fl_Osc_VSlider
- }
- Fl_Value_Slider vsns {
- label {V.Sns}
- tooltip {Velocity Sensing Function (rightmost to disable)} xywh {10 50 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
- code0 {o->init("PAmpVelocityScaleFunction");}
- class Fl_Osc_VSlider
- }
- Fl_Dial pan {
- label Pan
- tooltip {Panning (leftmost is Random)} xywh {210 25 30 30} box ROUND_UP_BOX labelsize 10 maximum 127 step 1
- code0 {o->init("PPanning");}
- class Fl_Osc_Dial
- }
- Fl_Dial pstr {
- label {P.Str.}
- tooltip {Punch Strength} xywh {125 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("PPunchStrength");}
- class Fl_Osc_Dial
- }
- Fl_Dial pt {
- label {P.t.}
- tooltip {Punch Time (duration)} xywh {155 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("PPunchTime");}
- class Fl_Osc_Dial
- }
- Fl_Dial pstc {
- label {P.Stc.}
- tooltip {Punch Stretch} xywh {185 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("PPunchStretch");}
- class Fl_Osc_Dial
- }
- Fl_Dial pvel {
- label {P.Vel.}
- tooltip {Punch Velocity Sensing} xywh {215 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
- code0 {o->init("PPunchVelocitySensing");}
- class Fl_Osc_Dial
- }
- Fl_Group ampenv {
- label {ADSynth Global - Amplitude Envelope} open
- xywh {10 75 205 70} box FLAT_BOX color 51 align 144
- code0 {o->init(ENV_ADSR, osc, loc, "GlobalPar/AmpEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Group amplfo {
- label {Amplitude LFO } open
- xywh {10 150 230 70} box FLAT_BOX color 47 align 144
- code0 {o->init(osc, loc, "GlobalPar/AmpLfo/");}
- class LFOUI
- } {}
- Fl_Check_Button rndgrp {
- label {Rnd Grp}
- tooltip {How the Harmonic Amplitude is applied to voices that use the same oscillator} xywh {70 235 40 25} down_box DOWN_BOX labelsize 10 align 148
- code0 {o->init("Hrandgrouping");}
- class Fl_Osc_Check
- }
- }
- Fl_Group {} {
- label FILTER open
- xywh {250 5 285 265} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
- } {
- Fl_Group filterenv {
- label {ADSynth Global - Filter Envelope} open
- xywh {255 118 275 70} box FLAT_BOX color 51 align 144
- code0 {o->init(ENV_ADSR_FILTER, osc, loc, "GlobalPar/FilterEnvelope/");}
- class EnvelopeUI
- } {}
- Fl_Group filterlfo {
- label {Filter LFO} open
- xywh {255 195 230 70} box FLAT_BOX color 47 align 144
- code0 {o->init(osc, loc, "GlobalPar/FilterLfo/");}
- class LFOUI
- } {}
- Fl_Group filterui {
- label {ADsynth Global - Filter} open
- xywh {255 35 275 75} box FLAT_BOX color 50 align 144
- code0 {o->init(loc + "GlobalPar/PFilter",
- osc, loc, "GlobalPar/GlobalFilter/");}
- class FilterUI
- } {}
- }
- Fl_Check_Button stereo {
- label Stereo
- xywh {5 230 65 35} down_box DOWN_BOX labelsize 11
- code0 {o->init("PStereo");}
- class Fl_Osc_Check
- }
- Fl_Button {} {
- label {Show Voice List}
- callback {for (int i=0;i<NUM_VOICES;i++){
- voicelistitem[i]->refreshlist();
- }
- ADnoteVoiceList->show();}
- xywh {180 400 125 25} labelsize 12
- }
- Fl_Button {} {
- label {Show Voice Parameters}
- callback {ADnoteVoice->show();}
- xywh {5 400 170 25} labelsize 12
- }
- Fl_Button {} {
- label Close
- callback {ADnoteGlobalParameters->hide();}
- xywh {475 400 60 25} box THIN_UP_BOX
- }
- Fl_Button {} {
- label Resonance
- callback {resui->resonancewindow->redraw();
- resui->resonancewindow->show();}
- tooltip Resonance xywh {309 400 86 25} box THIN_UP_BOX labelsize 12
- }
- Fl_Button {} {
- label C
- callback {presetsui->copy(loc);}
- xywh {405 405 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
- }
- Fl_Button {} {
- label P
- callback {presetsui->paste(loc,this);}
- xywh {435 405 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
- }
- }
- Fl_Window ADnoteVoice {
- label {ADsynth Voice Parameters} open
- xywh {48 361 765 630} type Double
- class Fl_Osc_Window visible
- } {
- Fl_Box {} {
- xywh {0 0 0 0}
- code0 {ADnoteVoice->base = loc;}
- code1 {ADnoteVoice->osc = osc;}
- }
- Fl_Group advoice {open
- xywh {0 0 765 595}
- code0 {o->init(nvoice,loc, osc);}
- code1 {o->show();}
- class ADvoiceUI
- } {}
- Fl_Button {} {
- label {Close Window}
- callback {ADnoteVoice->hide();}
- xywh {305 601 195 25} box THIN_UP_BOX labelfont 1
- }
- Fl_Counter currentvoicecounter {
- label {Current Voice}
- callback {nvoice=(int)o->value()-1;
- advoice->change_voice(nvoice);}
- xywh {10 601 130 25} type Simple labelfont 1 align 8 minimum 0 maximum 2 step 1 value 1 textfont 1 textsize 13
- code0 {o->bounds(1,NUM_VOICES);}
- }
- Fl_Button {} {
- label C
- callback {presetsui->copy(ADnoteVoice->loc(),nvoice);}
- xywh {705 609 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
- }
- Fl_Button {} {
- label P
- callback {presetsui->paste(ADnoteVoice->loc(),this,nvoice);}
- xywh {735 609 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
- }
- }
- Fl_Window ADnoteVoiceList {
- label {ADsynth Voices list} open
- xywh {32 266 650 260} type Double hide
- class Fl_Osc_Window
- } {
- Fl_Box {} {
- xywh {0 0 0 0}
- code0 {ADnoteVoiceList->base = loc;}
- code1 {ADnoteVoiceList->osc = osc;}
- }
- Fl_Text_Display {} {
- label {No.}
- xywh {10 15 30 10} box NO_BOX labelfont 1 labelsize 11
- }
- Fl_Text_Display {} {
- label Vol
- xywh {145 15 30 10} box NO_BOX labelfont 1 labelsize 11
- }
- Fl_Text_Display {} {
- label Detune
- xywh {384 15 25 10} box NO_BOX labelfont 1 labelsize 11
- }
- Fl_Text_Display {} {
- label Pan
- xywh {210 15 30 10} box NO_BOX labelfont 1 labelsize 11
- }
- Fl_Text_Display {} {
- label {Vib. Depth}
- xywh {560 15 30 10} box NO_BOX labelfont 1 labelsize 11
- }
- Fl_Text_Display {} {
- label {R.}
- xywh {245 15 25 10} box NO_BOX labelfont 1 labelsize 11
- }
- Fl_Button {} {
- label {Hide Voice List}
- callback {ADnoteVoiceList->hide();}
- xywh {255 237 125 20}
- }
- Fl_Scroll {} {open
- xywh {0 15 640 220} type VERTICAL box THIN_UP_BOX
- } {
- Fl_Pack {} {open
- xywh {0 20 620 210}
- code0 {o->begin();for (int i=0;i<NUM_VOICES;i++){voicelistitem[i]=new ADvoicelistitem(0,0,620,25,"");voicelistitem[i]->init(i,loc+"VoicePar"+to_s(i)+"/",osc);}o->end();}
- } {}
- }
- }
- }
- Function {ADnoteUI(std::string loc_, Fl_Osc_Interface *osc_)} {open
- } {
- code {assert(osc_);
- assert(!loc_.empty());
-
- nvoice=0;
- resui=new ResonanceUI(osc_, loc_+"GlobalPar/Reson/");
- loc=loc_;
- osc=osc_;
- make_window();} {}
- }
- Function {~ADnoteUI()} {open
- } {
- code {ADnoteVoiceList->hide();
- ADnoteGlobalParameters->hide();
- ADnoteVoice->hide();
- delete ADnoteVoiceList;
- delete ADnoteGlobalParameters;
- delete ADnoteVoice;
- delete resui;} {}
- }
- Function {refresh()} {open
- } {
- code {amplfo->refresh();
- freqlfo->refresh();
- filterlfo->refresh();
-
- ampenv->refresh();
- freqenv->refresh();
- filterenv->refresh();
- filterui->refresh();
-
- for (int i=0;i<NUM_VOICES;i++) voicelistitem[i]->refreshlist();
-
- resui->refresh();
- currentvoicecounter->do_callback();} {}
- }
- decl {ResonanceUI *resui;} {private local
- }
- decl {int nvoice;} {private local
- }
- decl {ADvoicelistitem *voicelistitem[NUM_VOICES];} {private local
- }
- decl {std::string loc;} {private local
- }
- decl {Fl_Osc_Interface *osc;} {private local
- }
- }
|