Audio plugin host https://kx.studio/carla
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1164 lines
43KB

  1. # data file for the Fltk User Interface Designer (fluid)
  2. version 1.0302
  3. header_name {.h}
  4. code_name {.cc}
  5. decl {//Copyright (c) 2002-2005 Nasca Octavian Paul} {private local
  6. }
  7. decl {//License: GNU GPL version 2 or later} {private local
  8. }
  9. decl {\#include "../Params/ADnoteParameters.h"} {public local
  10. }
  11. decl {\#include "ResonanceUI.h"} {public local
  12. }
  13. decl {\#include "Fl_Osc_Slider.H"} {public local
  14. }
  15. decl {\#include <FL/Fl_Box.H>} {public local
  16. }
  17. decl {\#include <FL/Fl_Group.H>} {public local
  18. }
  19. decl {\#include <cmath>} {private local
  20. }
  21. decl {\#include <cstdio>} {private local
  22. }
  23. decl {\#include <cstdlib>} {private local
  24. }
  25. decl {\#include <cstring>} {private local
  26. }
  27. decl {\#include "Fl_Osc_Pane.H"} {public local
  28. }
  29. decl {\#include "Fl_Osc_Dial.H"} {public local
  30. }
  31. decl {\#include "Fl_Osc_Check.H"} {public local
  32. }
  33. decl {\#include "Fl_Osc_Choice.H"} {public local
  34. }
  35. decl {\#include "Fl_Osc_Slider.H"} {public local
  36. }
  37. decl {\#include "Fl_Osc_VSlider.H"} {public local
  38. }
  39. decl {\#include "Fl_Oscilloscope.h"} {public local
  40. }
  41. decl {\#include "EnvelopeUI.h"} {public local
  42. }
  43. decl {\#include "LFOUI.h"} {public local
  44. }
  45. decl {\#include "FilterUI.h"} {public local
  46. }
  47. decl {\#include "OscilGenUI.h"} {public local
  48. }
  49. decl {\#include "PresetsUI.h"} {public local
  50. }
  51. class ADvoicelistitem {open : {public Fl_Osc_Group}
  52. } {
  53. Function {make_window()} {open private
  54. } {
  55. Fl_Window ADnoteVoiceListItem {open
  56. private xywh {346 881 615 100} type Double box UP_FRAME
  57. class Fl_Osc_Group visible
  58. } {
  59. Fl_Box {} {
  60. xywh {0 0 0 0}
  61. code0 {ADnoteVoiceListItem->base = loc;}
  62. }
  63. Fl_Group voicelistitemgroup {open
  64. private xywh {50 0 570 25}
  65. class Fl_Osc_Group
  66. } {
  67. Fl_Value_Slider voicevolume {
  68. tooltip Volume xywh {90 5 115 20} type {Horz Knob} box NO_BOX labelsize 8 align 5 maximum 127 step 1
  69. code1 {o->init("PVolume");}
  70. class Fl_Osc_VSlider
  71. }
  72. Fl_Check_Button voiceresonanceenabled {
  73. tooltip {Resonance On/Off} xywh {245 7 15 17} down_box DOWN_BOX labeltype EMBOSSED_LABEL labelfont 1 labelsize 11 align 4
  74. code0 {o->init("Presonance");}
  75. class Fl_Osc_Check
  76. }
  77. Fl_Value_Slider voicelfofreq {
  78. tooltip {Frequency LFO amount} xywh {500 5 115 20} type {Horz Knob} box NO_BOX labelsize 8 align 5 maximum 127 step 1
  79. code0 {o->init("FreqLfo/Pintensity", 'i');}
  80. class Fl_Osc_Slider
  81. }
  82. Fl_Dial voicepanning {
  83. tooltip {Panning (leftmost is Random)} xywh {215 5 20 20} box ROUND_UP_BOX labelsize 10 align 4 maximum 127 step 1
  84. code0 {o->init("PPanning");}
  85. class Fl_Osc_Dial
  86. }
  87. Fl_Group voiceoscil {open
  88. xywh {60 5 30 20} box THIN_DOWN_BOX color 32 selection_color 71 labelcolor 179
  89. code0 {voiceoscil->ext = "OscilSmp/";}
  90. code1 {oscil=new Fl_Oscilloscope(o->x(),o->y(),o->w(),o->h(),"");}
  91. code2 {oscil->init(false);}
  92. class Fl_Osc_Group
  93. } {}
  94. Fl_Value_Output detunevalueoutput {
  95. xywh {265 5 45 20} labelsize 10 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 10
  96. code0 {o->init("detunevalue");}
  97. class Fl_Osc_Output
  98. }
  99. Fl_Slider voicedetune {
  100. callback {//detunevalueoutput->do_callback();}
  101. tooltip {Fine Detune (cents)} xywh {315 5 185 20} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
  102. code0 {o->init("PDetune",'i');}
  103. class Fl_Osc_Slider
  104. }
  105. Fl_Box noiselabel {
  106. label N
  107. xywh {65 5 20 20} labelfont 1 labelsize 13 labelcolor 7
  108. }
  109. Fl_Check_Button noisehack {
  110. callback {if (o->value()==0) {
  111. noiselabel->hide();
  112. voiceresonanceenabled->activate();
  113. detunevalueoutput->activate();
  114. voicedetune->activate();
  115. voicelfofreq->activate();
  116. voiceoscil->activate();
  117. } else {
  118. noiselabel->show();
  119. voiceresonanceenabled->deactivate();
  120. detunevalueoutput->deactivate();
  121. voicedetune->deactivate();
  122. voicelfofreq->deactivate();
  123. voiceoscil->deactivate();
  124. };}
  125. xywh {0 0 0 0} down_box DOWN_BOX
  126. code0 {o->init("Type");o->hide();}
  127. class Fl_Osc_Check
  128. }
  129. }
  130. Fl_Check_Button voiceenabled {
  131. label 01
  132. callback {if (o->value()==0) voicelistitemgroup->deactivate();
  133. else voicelistitemgroup->activate();
  134. o->redraw();}
  135. private xywh {30 5 20 20} down_box DOWN_BOX labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 4
  136. code0 {char tmp[10];snprintf(tmp,10,"%d",nvoice+1);o->label(strdup(tmp));}
  137. code1 {o->init("Enabled");}
  138. class Fl_Osc_Check
  139. }
  140. }
  141. }
  142. Function {ADvoicelistitem(int x,int y, int w, int h, const char *label=0):Fl_Osc_Group(x,y,w,h,label)} {open
  143. } {
  144. code {assert(osc);
  145. nvoice=0;} {}
  146. }
  147. Function {init(int nvoice_, std::string loc_, Fl_Osc_Interface *osc_)} {open
  148. } {
  149. code {assert(osc_);
  150. assert(!loc_.empty());
  151. nvoice=nvoice_;
  152. loc = loc_;
  153. make_window();
  154. ADnoteVoiceListItem->show();
  155. end();} {}
  156. }
  157. Function {refreshlist()} {open
  158. } {
  159. code {if (voiceenabled->value()==0) voicelistitemgroup->deactivate();
  160. else voicelistitemgroup->activate();
  161. detunevalueoutput->do_callback();
  162. ADnoteVoiceListItem->redraw();} {}
  163. }
  164. Function {~ADvoicelistitem()} {} {
  165. code {ADnoteVoiceListItem->hide();} {}
  166. }
  167. decl {int nvoice;} {private local
  168. }
  169. decl {Fl_Oscilloscope *oscil;} {private local
  170. }
  171. decl {std::string loc;} {private local
  172. }
  173. }
  174. class ADvoiceUI {open : {public Fl_Group}
  175. } {
  176. Function {make_window()} {open
  177. } {
  178. Fl_Window ADnoteVoiceParameters {
  179. label Voice open
  180. xywh {512 391 765 595} type Double box NO_BOX
  181. class Fl_Osc_Group visible
  182. } {
  183. Fl_Box {} {
  184. label label
  185. xywh {25 25 35 16}
  186. code0 {ADnoteVoiceParameters->base = base+"VoicePar"+to_s(nvoice)+"/";}
  187. code1 {ADnoteVoiceParameters->osc = osc_i;}
  188. }
  189. Fl_Group voiceparametersgroup {open
  190. xywh {0 0 770 590} color 48
  191. } {
  192. Fl_Group voicemodegroup {open
  193. xywh {0 5 770 585} color 64
  194. } {
  195. Fl_Group voiceFMparametersgroup {
  196. label MODULATOR open
  197. xywh {530 5 230 580} box UP_FRAME color 48 labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  198. } {
  199. Fl_Group modfrequency {
  200. label {Mod.FREQUENCY}
  201. xywh {535 220 220 155} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  202. } {
  203. Fl_Group voiceFMfreqenvgroup {
  204. label {ADSynth Modulator - Frequency Envelope}
  205. xywh {540 300 210 70} box FLAT_BOX color 51 align 144
  206. code0 {o->init(ENV_ASR, osc_i, loc, "FMFreqEnvelope/");}
  207. class EnvelopeUI
  208. } {}
  209. Fl_Check_Button {} {
  210. label On
  211. callback {if (o->value()==0) voiceFMfreqenvgroup->deactivate();
  212. else voiceFMfreqenvgroup->activate();
  213. o->redraw();}
  214. tooltip {Forced Release} xywh {545 305 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
  215. code0 {o->init("PFMFreqEnvelopeEnabled");}
  216. class Fl_Osc_Check
  217. }
  218. Fl_Counter {} {
  219. label {Coarse Det.}
  220. tooltip {Coarse Detune} xywh {685 280 60 15} labelsize 10 align 1 minimum -64 maximum 63 step 1 textfont 1 textsize 11
  221. code0 {o->init("FMcoarsedetune");}
  222. code3 {o->lstep(10);}
  223. class Fl_Osc_Counter
  224. }
  225. Fl_Counter {} {
  226. label Octave
  227. tooltip Octave xywh {625 280 45 15} type Simple labelsize 10 align 1 minimum -8 maximum 7 step 1 textfont 1 textsize 11
  228. code0 {o->init("FMoctave");}
  229. class Fl_Osc_Counter
  230. }
  231. Fl_Slider {} {
  232. callback {o->oscWrite("detunevalue");}
  233. tooltip {Fine Detune (cents)} xywh {590 245 155 15} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
  234. code0 {o->init("PFMDetune", 'i');}
  235. class Fl_Osc_Slider
  236. }
  237. Fl_Value_Output fmdetunevalueoutput {
  238. label Detune
  239. xywh {540 245 45 18} labelsize 8 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 8
  240. code0 {o->init("FMdetunevalue");}
  241. class Fl_Osc_Output
  242. }
  243. Fl_Choice {} {
  244. label {Detune Type}
  245. callback {fmdetunevalueoutput->do_callback();} open
  246. xywh {540 280 75 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
  247. code0 {o->add("Default");o->add("L35cents");o->add("L10cents");o->add("E100cents");o->add("E1200cents");}
  248. code1 {o->init("PFMDetuneType");}
  249. class Fl_Osc_Choice
  250. } {}
  251. }
  252. Fl_Group {} {
  253. label {Mod.AMPLITUDE}
  254. xywh {535 60 220 160} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  255. } {
  256. Fl_Value_Slider {} {
  257. label Vol
  258. tooltip Volume xywh {540 80 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
  259. code0 {o->init("PFMVolume", 'i');}
  260. class Fl_Osc_Slider
  261. }
  262. Fl_Value_Slider {} {
  263. label {V.Sns}
  264. 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
  265. code0 {o->init("PFMVelocityScaleFunction");}
  266. class Fl_Osc_VSlider
  267. }
  268. Fl_Group voiceFMampenvgroup {
  269. label {ADSynth Modulator - Amplitude Envelope} open
  270. xywh {540 145 205 70} box FLAT_BOX color 51 align 144
  271. code0 {o->init(//pars->VoicePar[nvoice].FMAmpEnvelope,
  272. ENV_ADSR, osc_i, loc, "FMAmpEnvelope/");}
  273. class EnvelopeUI
  274. } {}
  275. Fl_Check_Button {} {
  276. label On
  277. callback {if (o->value()==0) voiceFMampenvgroup->deactivate();
  278. else voiceFMampenvgroup->activate();
  279. o->redraw();}
  280. tooltip {Forced Release} xywh {545 150 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
  281. code0 {o->init("PFMAmpEnvelopeEnabled");}
  282. class Fl_Osc_Check
  283. }
  284. Fl_Value_Slider {} {
  285. label {F.Damp}
  286. 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
  287. code0 {o->init("PFMVolumeDamp",'i');}
  288. class Fl_Osc_Slider
  289. }
  290. }
  291. Fl_Group modoscil {open
  292. xywh {535 365 220 220}
  293. } {
  294. Fl_Group fmoscil {open
  295. xywh {535 440 220 140} box THIN_DOWN_BOX color 32 selection_color 71 labelcolor 179
  296. code0 {fmoscil->base = loc; fmoscil->ext="FMSmp/";fmoscil->osc = osc_i;fmoscil->begin();}
  297. code1 {oscFM=new Fl_Oscilloscope(o->x(),o->y(),o->w(),o->h(),"");}
  298. code2 {//int nv=nvoice; if (pars->VoicePar[nvoice].PextFMoscil>=0) nv=pars->VoicePar[nvoice].PextFMoscil;}
  299. code3 {oscFM->parent(fmoscil);oscFM->init(false);oscFM->update();fmoscil->end();}
  300. class Fl_Osc_Group
  301. } {}
  302. Fl_Box {} {
  303. label {Mod.Oscillator}
  304. xywh {535 375 155 20} labelfont 1 align 20
  305. }
  306. Fl_Button changeFMoscilbutton {
  307. label Change
  308. callback {if (oscedit!=NULL)
  309. delete(oscedit);
  310. //int nv=nvoice;
  311. //if (extFMoscil->value()>=0)
  312. // nv=extFMoscil->value();
  313. oscedit=new OscilEditor(true, loc+"FMSmp/", osc_i);}
  314. xywh {700 380 55 15} box THIN_UP_BOX labelfont 1 labelsize 11
  315. code0 {(void)o;/*if (extFMoscil->value()>=0) o->labelcolor(FL_BLUE);*/}
  316. }
  317. Fl_Slider {} {
  318. label Phase
  319. callback {oscFM->phase=64-(int) o->value();
  320. fmoscil->redraw();}
  321. xywh {645 415 105 15} type {Horz Knob} box NO_BOX labelsize 10 align 5 minimum -64 maximum 63 step 1
  322. code0 {o->init("PFMoscilphase", 'i');}
  323. class Fl_Osc_Slider
  324. }
  325. Fl_Choice extFMoscil {
  326. label Use
  327. callback {if ((int) o->value() != 0) {
  328. oscFM->init(false);
  329. changeFMoscilbutton->labelcolor(FL_BLUE);
  330. } else {
  331. oscFM->init(false);
  332. changeFMoscilbutton->labelcolor(FL_BLACK);
  333. };
  334. voiceFMparametersgroup->redraw();} open
  335. xywh {560 410 75 20} down_box BORDER_BOX labelsize 10 textfont 1 textsize 10
  336. code0 {o->add("Internal");}
  337. code1 {char tmp[50]; for (int i=0;i<nvoice;i++) {sprintf(tmp,"ExtM.%2d",i+1);o->add(tmp);};}
  338. code3 {o->init("PextFMoscil",1);}
  339. class Fl_Osc_Choice
  340. } {}
  341. }
  342. Fl_Choice {} {
  343. label {External Mod.}
  344. callback {if ((int) o->value() != 0) {
  345. modoscil->deactivate();
  346. modfrequency->deactivate();
  347. } else {
  348. modoscil->activate();
  349. modfrequency->activate();
  350. };
  351. voiceFMparametersgroup->redraw();} open
  352. xywh {635 40 85 20} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
  353. code0 {o->add("OFF");}
  354. code1 {char tmp[50]; for (int i=0;i<nvoice;i++) {sprintf(tmp,"ExtMod.%2d",i+1);o->add(tmp);};}
  355. code2 {o->init("PFMVoice", -1);}
  356. code3 {if ((int) o->value() != 0) {modoscil->deactivate();modfrequency->deactivate();}}
  357. class Fl_Osc_Choice
  358. } {}
  359. }
  360. Fl_Choice {} {
  361. label {Type:}
  362. callback {if (o->value()==0) voiceFMparametersgroup->deactivate();
  363. else voiceFMparametersgroup->activate();
  364. o->redraw();}
  365. xywh {535 40 80 20} down_box BORDER_BOX align 5
  366. code0 {o->init("PFMEnabled");}
  367. class Fl_Osc_Choice
  368. } {
  369. MenuItem {} {
  370. label OFF
  371. xywh {40 40 100 20} labelfont 1
  372. }
  373. MenuItem {} {
  374. label MORPH
  375. xywh {50 50 100 20} labelfont 1
  376. }
  377. MenuItem {} {
  378. label RING
  379. xywh {60 60 100 20} labelfont 1
  380. }
  381. MenuItem {} {
  382. label PM
  383. xywh {70 70 100 20} labelfont 1
  384. }
  385. MenuItem {} {
  386. label FM
  387. xywh {80 80 100 20} labelfont 1
  388. }
  389. MenuItem {} {
  390. label PITCH
  391. xywh {90 90 100 20} labelfont 1 deactivate
  392. }
  393. }
  394. Fl_Group {} {
  395. label FREQUENCY open
  396. xywh {5 265 525 120} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  397. } {
  398. Fl_Group voicefreqenvgroup {
  399. label {ADSynth Voice - Frequency Envelope} open
  400. xywh {10 305 205 70} box FLAT_BOX color 51 align 144
  401. code0 {o->init(//pars->VoicePar[nvoice].FreqEnvelope,
  402. ENV_ASR, osc_i, loc, "FreqEnvelope/");}
  403. class EnvelopeUI
  404. } {}
  405. Fl_Check_Button {} {
  406. label On
  407. callback {if (o->value()==0) voicefreqenvgroup->deactivate();
  408. else voicefreqenvgroup->activate();
  409. o->redraw();}
  410. tooltip {Forced Release} xywh {15 310 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
  411. code0 {o->init("PFreqEnvelopeEnabled");}
  412. class Fl_Osc_Check
  413. }
  414. Fl_Group voicefreqlfogroup {
  415. label {Frequency LFO } open
  416. xywh {220 305 230 70} box FLAT_BOX color 47 align 144
  417. code0 {o->init(osc_i, loc,"FreqLfo/");}
  418. class LFOUI
  419. } {}
  420. Fl_Check_Button {} {
  421. label On
  422. callback {if (o->value()==0) voicefreqlfogroup->deactivate();
  423. else voicefreqlfogroup->activate();
  424. o->redraw();}
  425. tooltip {Forced Release} xywh {225 311 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
  426. code0 {o->init("PFreqLfoEnabled");}
  427. class Fl_Osc_Check
  428. }
  429. Fl_Counter {} {
  430. label Octave
  431. tooltip Octave xywh {470 285 45 15} type Simple labelsize 10 align 1 minimum -8 maximum 7 step 1 textfont 1 textsize 11
  432. code0 {o->init("octave");}
  433. class Fl_Osc_Counter
  434. }
  435. Fl_Counter {} {
  436. label {Coarse Det.}
  437. tooltip {Coarse Detune} xywh {455 355 60 20} labelsize 10 align 1 minimum -64 maximum 63 step 1 textfont 1 textsize 11
  438. code0 {o->init("coarsedetune");}
  439. code3 {o->lstep(10);}
  440. class Fl_Osc_Counter
  441. }
  442. Fl_Slider {} {
  443. callback {detunevalueoutput->do_callback();}
  444. tooltip {Fine Detune (cents)} xywh {58 287 392 13} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
  445. code0 {o->init("PDetune", 'i');}
  446. class Fl_Osc_Slider
  447. }
  448. Fl_Value_Output detunevalueoutput {
  449. label Detune
  450. code0 {o->init("detunevalue");}
  451. xywh {10 287 45 15} labelsize 10 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 10
  452. class Fl_Osc_Output
  453. }
  454. Fl_Check_Button {} {
  455. label 440Hz
  456. callback {if (o->value()==0) fixedfreqetdial->deactivate();
  457. else fixedfreqetdial->activate();}
  458. tooltip {Set the voice base frequency to 440Hz} xywh {345 268 55 15} down_box DOWN_BOX labelfont 1 labelsize 11
  459. code0 {o->init("Pfixedfreq");}
  460. class Fl_Osc_Check
  461. }
  462. Fl_Dial fixedfreqetdial {
  463. label {Eq.T.}
  464. 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
  465. code0 {o->init("PfixedfreqET");}
  466. class Fl_Osc_Dial
  467. }
  468. Fl_Choice {} {
  469. label {Detune Type}
  470. callback {detunevalueoutput->do_callback();} open
  471. xywh {455 320 70 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
  472. code0 {o->add("Default");o->add("L35cents");o->add("L10cents");o->add("E100cents");o->add("E1200cents");}
  473. code1 {o->init("PDetuneType");}
  474. class Fl_Osc_Choice
  475. } {}
  476. }
  477. Fl_Group voiceoscil {
  478. xywh {80 390 445 145} box THIN_DOWN_BOX color 32 selection_color 71 labelcolor 179
  479. code0 {voiceoscil->base = loc;voiceoscil->ext="OscilSmp/";voiceoscil->begin();//int nv=nvoice; if (extoscil->value()>=0) nv=extoscil->value();}
  480. code1 {osc=new Fl_Oscilloscope(o->x(),o->y(),o->w(),o->h(),"");}
  481. code2 {voiceoscil->osc = osc_i;}
  482. code3 {osc->parent(voiceoscil); osc->init(false);voiceoscil->end();}
  483. class Fl_Osc_Group
  484. } {}
  485. Fl_Button changevoiceoscilbutton {
  486. label Change
  487. callback {delete oscedit;
  488. //if(extoscil->value()>=0)
  489. // nv=extoscil->value();
  490. oscedit=new OscilEditor(true,loc+"OscilSmp/", osc_i);}
  491. xywh {5 490 65 20} box THIN_UP_BOX labelfont 1 labelsize 11
  492. code0 {(void)o;/*if (extoscil->value()>=0) o->labelcolor(FL_BLUE);*/}
  493. }
  494. Fl_Box {} {
  495. label {Voice Oscillator}
  496. xywh {5 390 75 35} labelfont 1 labelsize 12 align 128
  497. }
  498. Fl_Slider {} {
  499. label Phase
  500. callback {osc->phase=64-(int) o->value();
  501. voiceoscil->redraw();}
  502. xywh {10 435 65 10} type {Horz Knob} box NO_BOX labelsize 10 align 5 minimum -64 maximum 63 step 1
  503. code0 {o->init("Poscilphase", 'i');}
  504. class Fl_Osc_Slider
  505. }
  506. Fl_Check_Button {} {
  507. label {R.}
  508. tooltip {Resonance On/Off} xywh {210 5 35 35} box THIN_UP_BOX down_box DOWN_BOX labelfont 1 labelsize 11
  509. code0 {o->init("Presonance");}
  510. class Fl_Osc_Check
  511. }
  512. Fl_Choice extoscil {
  513. label {Use Oscil.}
  514. callback {if ((int) o->value() != 0) {
  515. osc->init(false);
  516. changevoiceoscilbutton->labelcolor(FL_BLUE);
  517. } else {
  518. osc->init(false);
  519. changevoiceoscilbutton->labelcolor(FL_BLACK);
  520. };
  521. voiceparametersgroup->redraw();
  522. voiceonbutton->redraw();} open
  523. xywh {5 470 65 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
  524. code0 {o->add("Internal");}
  525. code1 {char tmp[50]; for (int i=0;i<nvoice;i++) {sprintf(tmp,"Ext.%2d",i+1);o->add(tmp);};}
  526. code3 {o->init("Pextoscil",1);}
  527. class Fl_Osc_Choice
  528. } {}
  529. Fl_Group {} {open
  530. xywh {5 540 520 50} box UP_FRAME
  531. } {
  532. Fl_Dial {} {
  533. label Stereo
  534. tooltip {Stereo Spread} xywh {322 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  535. code0 {o->init("Unison_stereo_spread");}
  536. class Fl_Osc_Dial
  537. }
  538. Fl_Choice {} {
  539. label Unison
  540. tooltip {Unison size} xywh {10 560 75 20} down_box BORDER_BOX labelfont 1 align 5 textfont 1 textsize 10
  541. 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);};}
  542. code1 {o->init("Unison_size");}
  543. class Fl_Osc_Choice
  544. } {}
  545. Fl_Dial {} {
  546. label Vibrato
  547. tooltip Vibrato xywh {364 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  548. code0 {o->init("Unison_vibratto");}
  549. class Fl_Osc_Dial
  550. }
  551. Fl_Choice {} {
  552. label Invert
  553. tooltip {Phase Invert} xywh {445 560 65 15} down_box BORDER_BOX labelsize 11 align 5 textfont 1 textsize 10
  554. 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);};}
  555. code1 {o->init("Unison_invert_phase");}
  556. class Fl_Osc_Choice
  557. } {}
  558. Fl_Slider {} {
  559. label {Frequency Spread}
  560. callback {unisonspreadoutput->update();}
  561. 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
  562. code0 {o->init("Unison_frequency_spread", 'i');}
  563. class Fl_Osc_Slider
  564. }
  565. Fl_Value_Output unisonspreadoutput {
  566. label {(cents)}
  567. xywh {225 560 40 15} labelsize 10 align 5 maximum 1000 step 0.1 textfont 1 textsize 10
  568. code0 {o->init("unisonFrequencySpreadCents");//o->value(pars->getUnisonFrequencySpreadCents(nvoice));}
  569. class Fl_Osc_Output
  570. }
  571. Fl_Dial {} {
  572. label {V.speed}
  573. tooltip {Vibrato Average Speed} xywh {406 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  574. code0 {o->init("Unison_vibratto_speed");}
  575. class Fl_Osc_Dial
  576. }
  577. Fl_Dial {} {
  578. label {Ph.rand}
  579. tooltip {Phase randomness} xywh {280 555 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  580. code0 {o->init("Unison_phase_randomness");}
  581. class Fl_Osc_Dial
  582. }
  583. }
  584. }
  585. Fl_Group {} {
  586. label AMPLITUDE open
  587. xywh {5 40 240 220} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  588. } {
  589. Fl_Value_Slider {} {
  590. label Vol
  591. tooltip Volume xywh {10 60 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
  592. code0 {o->init("PVolume");}
  593. class Fl_Osc_VSlider
  594. }
  595. Fl_Value_Slider {} {
  596. label {V.Sns}
  597. 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
  598. code0 {o->init("PAmpVelocityScaleFunction");}
  599. class Fl_Osc_VSlider
  600. }
  601. Fl_Group voiceampenvgroup {
  602. label {ADSynth Voice - Amplitude Envelope} open
  603. xywh {10 105 205 70} box FLAT_BOX color 51 align 144
  604. code0 {o->init(//pars->VoicePar[nvoice].AmpEnvelope,
  605. ENV_ADSR, osc_i, loc, "AmpEnvelope/");}
  606. class EnvelopeUI
  607. } {}
  608. Fl_Dial {} {
  609. label Pan
  610. tooltip {Panning (leftmost is Random)} xywh {210 60 30 30} box ROUND_UP_BOX labelsize 10 maximum 127 step 1
  611. code0 {o->init("PPanning");}
  612. class Fl_Osc_Dial
  613. }
  614. Fl_Check_Button {} {
  615. label On
  616. callback {if (o->value()==0) voiceampenvgroup->deactivate();
  617. else voiceampenvgroup->activate();
  618. o->redraw();}
  619. tooltip {Forced Release} xywh {15 110 50 10} down_box DOWN_BOX labelfont 1 labelsize 11
  620. code0 {o->init("PAmpEnvelopeEnabled");}
  621. class Fl_Osc_Check
  622. }
  623. Fl_Group voiceamplfogroup {
  624. label {Amplitude LFO } open
  625. xywh {10 180 230 75} box FLAT_BOX color 47 align 144
  626. code0 {o->init(osc_i, loc, "AmpLfo/");}
  627. class LFOUI
  628. } {}
  629. Fl_Check_Button {} {
  630. label On
  631. callback {if (o->value()==0) voiceamplfogroup->deactivate();
  632. else voiceamplfogroup->activate();
  633. o->redraw();}
  634. tooltip {Forced Release} xywh {15 185 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
  635. code0 {o->init("PAmpLfoEnabled");}
  636. class Fl_Osc_Check
  637. }
  638. Fl_Check_Button {} {
  639. label Minus
  640. xywh {10 45 50 10} down_box DOWN_BOX labelfont 1 labelsize 10
  641. code0 {o->init("PVolumeminus");}
  642. class Fl_Osc_Check
  643. }
  644. }
  645. Fl_Group voicefiltergroup {
  646. label FILTER open
  647. xywh {245 5 285 260} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  648. } {
  649. Fl_Group {} {
  650. label {ADsynth Voice - Filter} open
  651. xywh {250 30 275 75} box FLAT_BOX color 50 align 144
  652. code0 {o->init("", osc_i, loc, "VoiceFilter/");}
  653. class FilterUI
  654. } {}
  655. Fl_Group voicefilterenvgroup {
  656. label {ADSynth Voice - Filter Envelope} open
  657. xywh {250 115 275 70} box FLAT_BOX color 51 align 144
  658. code0 {o->init(
  659. ENV_ADSR_FILTER, osc_i, loc, "FilterEnvelope/");}
  660. class EnvelopeUI
  661. } {}
  662. Fl_Check_Button {} {
  663. label On
  664. callback {if (o->value()==0) voicefilterenvgroup->deactivate();
  665. else voicefilterenvgroup->activate();
  666. o->redraw();}
  667. tooltip {Forced Release} xywh {255 119 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
  668. code0 {o->init("PFilterEnvelopeEnabled");}
  669. class Fl_Osc_Check
  670. }
  671. Fl_Group voicefilterlfogroup {
  672. label {Filter LFO } open
  673. xywh {250 190 230 70} box FLAT_BOX color 47 align 144
  674. code0 {o->init(osc_i, loc, "FilterLfo/");}
  675. class LFOUI
  676. } {}
  677. Fl_Check_Button {} {
  678. label On
  679. callback {if (o->value()==0) voicefilterlfogroup->deactivate();
  680. else voicefilterlfogroup->activate();
  681. o->redraw();}
  682. tooltip {Forced Release} xywh {255 196 55 10} down_box DOWN_BOX labelfont 1 labelsize 11
  683. code0 {o->init("PFilterLfoEnabled");}
  684. class Fl_Osc_Check
  685. }
  686. }
  687. Fl_Group activeVoiceID {
  688. label 01
  689. xywh {5 5 55 35} box THIN_UP_BOX labeltype EMBOSSED_LABEL labelfont 1 labelsize 22 align 16
  690. code0 {char tmp[10];snprintf(tmp,10,"%d",nvoice+1);o->label(strdup(tmp));}
  691. } {}
  692. Fl_Choice {} {
  693. callback {if (o->value()==0){ voicemodegroup->activate(); noiselabel->hide();}
  694. else{ voicemodegroup->deactivate(); noiselabel->show();}}
  695. tooltip {Oscillator Type (sound/noise)} xywh {5 515 65 20} down_box BORDER_BOX labelsize 10 textfont 1 textsize 10
  696. code0 {o->init("Type");}
  697. class Fl_Osc_Choice
  698. } {
  699. MenuItem {} {
  700. label Sound
  701. xywh {5 5 100 20} labelfont 1 labelsize 11
  702. }
  703. MenuItem {} {
  704. label NOISE
  705. xywh {15 15 100 20} labelfont 1 labelsize 11 labelcolor 1
  706. }
  707. }
  708. Fl_Check_Button bypassfiltercheckbutton {
  709. label {Bypass Global F.}
  710. xywh {425 10 100 20} down_box DOWN_BOX labelfont 1 labelsize 10 align 148
  711. code0 {o->init("Pfilterbypass");}
  712. class Fl_Osc_Check
  713. }
  714. Fl_Group {} {open
  715. xywh {115 5 95 35} box THIN_UP_BOX
  716. } {
  717. Fl_Value_Slider {} {
  718. label Delay
  719. tooltip Volume xywh {120 21 84 12} type {Horz Knob} box NO_BOX labelsize 11 align 5 maximum 127 step 1
  720. code0 {o->init("PDelay");}
  721. class Fl_Osc_VSlider
  722. }
  723. }
  724. Fl_Check_Button {} {
  725. label On
  726. callback {if (o->value()==0) voicefiltergroup->deactivate();
  727. else voicefiltergroup->activate();
  728. o->redraw();
  729. bypassfiltercheckbutton->redraw();}
  730. tooltip {Enable Filter} xywh {250 15 60 15} down_box DOWN_BOX labelfont 1 labelsize 11
  731. code0 {o->init("PFilterEnabled");}
  732. class Fl_Osc_Check
  733. }
  734. Fl_Box noiselabel {
  735. label {White Noise}
  736. xywh {150 430 300 65} labelfont 1 labelsize 50 labelcolor 53 hide
  737. }
  738. }
  739. Fl_Check_Button voiceonbutton {
  740. label On
  741. callback {if (o->value()==0) voiceparametersgroup->deactivate();
  742. else voiceparametersgroup->activate();
  743. o->redraw();}
  744. xywh {60 5 55 35} box THIN_UP_BOX down_box DOWN_BOX labelfont 1 labelsize 13
  745. code0 {o->init("Enabled");}
  746. class Fl_Osc_Check
  747. }
  748. }
  749. }
  750. Function {ADvoiceUI(int x,int y, int w, int h, const char *label=0):Fl_Group(x,y,w,h,label)} {} {
  751. code {nvoice=0;
  752. oscedit=NULL;} {}
  753. }
  754. Function {init(int nvoice_, std::string loc_, Fl_Osc_Interface *osc_)} {open
  755. } {
  756. code {assert(osc_);
  757. assert(!loc_.empty());
  758. nvoice=nvoice_;
  759. loc=loc_+"VoicePar"+to_s(nvoice)+"/";
  760. base = loc_;
  761. osc_i=osc_;
  762. make_window();
  763. end();
  764. ADnoteVoiceParameters->show();} {}
  765. }
  766. Function {~ADvoiceUI()} {open
  767. } {
  768. code {ADnoteVoiceParameters->hide();
  769. hide();
  770. delete(oscedit);
  771. //delete (ADnoteVoiceParameters);} {}
  772. }
  773. Function {change_voice(int nvoice_)} {open
  774. } {
  775. code {nvoice = nvoice_;
  776. loc = base+"VoicePar"+to_s(nvoice)+"/";
  777. char tmp[10];snprintf(tmp,10,"%d",nvoice+1);
  778. activeVoiceID->label(strdup(tmp));
  779. ADnoteVoiceParameters->rebase(base+"VoicePar"+to_s(nvoice)+"/");} {selected
  780. }
  781. }
  782. decl {int nvoice;} {private local
  783. }
  784. decl {OscilEditor *oscedit;} {private local
  785. }
  786. decl {Fl_Oscilloscope *osc;} {private local
  787. }
  788. decl {Fl_Oscilloscope *oscFM;} {private local
  789. }
  790. decl {std::string loc;} {private local
  791. }
  792. decl {std::string base;} {private local
  793. }
  794. decl {Fl_Osc_Interface *osc_i;} {private local
  795. }
  796. }
  797. class ADnoteUI {open : {public PresetsUI_}
  798. } {
  799. Function {make_window()} {open private
  800. } {
  801. Fl_Window ADnoteGlobalParameters {
  802. label {ADsynth Global Parameters of the Instrument} open
  803. xywh {688 551 540 430} type Double
  804. class Fl_Osc_Window visible
  805. } {
  806. Fl_Box {} {
  807. xywh {0 0 0 0}
  808. code0 {ADnoteGlobalParameters->base = loc + "GlobalPar/"; ADnoteGlobalParameters->osc = osc;}
  809. }
  810. Fl_Group {} {
  811. label FREQUENCY open
  812. xywh {5 280 530 115} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  813. } {
  814. Fl_Group freqenv {
  815. label {ADSynth Global - Frequency Envelope} open
  816. xywh {10 320 205 70} box FLAT_BOX color 51 align 144
  817. code0 {o->init(ENV_ASR, osc, loc, "GlobalPar/FreqEnvelope/");}
  818. class EnvelopeUI
  819. } {}
  820. Fl_Counter octave {
  821. label Octave
  822. tooltip Octave xywh {455 300 45 15} type Simple labelsize 10 align 1 minimum -8 maximum 7 step 1 textfont 1 textsize 11
  823. code0 {o->init("octave");}
  824. class Fl_Osc_Counter
  825. }
  826. Fl_Counter coarsedet {
  827. label {Coarse det.}
  828. tooltip {Coarse Detune} xywh {460 370 60 20} type Simple labelsize 10 align 5 minimum -64 maximum 63 step 1 textfont 1 textsize 11
  829. code0 {o->init("coarsedetune");}
  830. code3 {o->lstep(10);}
  831. class Fl_Osc_Counter
  832. }
  833. Fl_Group freqlfo {
  834. label {Frequency LFO } open
  835. xywh {220 320 230 70} box FLAT_BOX color 47 align 144
  836. code0 {o->init(osc, loc, "GlobalPar/FreqLfo/");}
  837. class LFOUI
  838. } {}
  839. Fl_Slider detune {
  840. callback {o->oscWrite("detunevalue");}
  841. tooltip {Fine Detune (cents)} xywh {60 300 385 15} type {Horz Knob} box NO_BOX minimum -8192 maximum 8191 step 1
  842. code0 {o->init("PDetune", 'i');}
  843. class Fl_Osc_Slider
  844. }
  845. Fl_Value_Output detunevalueoutput {
  846. label Detune
  847. xywh {12 300 45 15} labelsize 10 align 5 minimum -5000 maximum 5000 step 0.01 textfont 1 textsize 10
  848. code0 {o->init("detunevalue");}
  849. class Fl_Osc_Output
  850. }
  851. Fl_Choice detunetype {
  852. label {Detune Type}
  853. callback {o->oscWrite("detunevalue");} open
  854. xywh {455 340 75 15} down_box BORDER_BOX labelsize 10 align 5 textfont 1 textsize 10
  855. code0 {o->add("L35cents");o->add("L10cents");o->add("E100cents");o->add("E1200cents");}
  856. code1 {o->init("PDetuneType",1);}
  857. class Fl_Osc_Choice
  858. } {}
  859. Fl_Dial {} {
  860. label relBW
  861. callback {for (int i=0;i<NUM_VOICES;i++){
  862. voicelistitem[i]->refreshlist();
  863. };}
  864. 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
  865. code0 {o->init("PBandwidth");}
  866. class Fl_Osc_Dial
  867. }
  868. }
  869. Fl_Group {} {
  870. label AMPLITUDE open
  871. xywh {5 5 240 260} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  872. } {
  873. Fl_Value_Slider volume {
  874. label Vol
  875. tooltip Volume xywh {10 30 160 15} type {Horz Knob} box NO_BOX labelsize 11 align 8 maximum 127 step 1
  876. code0 {o->init("PVolume");}
  877. class Fl_Osc_VSlider
  878. }
  879. Fl_Value_Slider vsns {
  880. label {V.Sns}
  881. 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
  882. code0 {o->init("PAmpVelocityScaleFunction");}
  883. class Fl_Osc_VSlider
  884. }
  885. Fl_Dial pan {
  886. label Pan
  887. tooltip {Panning (leftmost is Random)} xywh {210 25 30 30} box ROUND_UP_BOX labelsize 10 maximum 127 step 1
  888. code0 {o->init("PPanning");}
  889. class Fl_Osc_Dial
  890. }
  891. Fl_Dial pstr {
  892. label {P.Str.}
  893. tooltip {Punch Strength} xywh {125 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  894. code0 {o->init("PPunchStrength");}
  895. class Fl_Osc_Dial
  896. }
  897. Fl_Dial pt {
  898. label {P.t.}
  899. tooltip {Punch Time (duration)} xywh {155 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  900. code0 {o->init("PPunchTime");}
  901. class Fl_Osc_Dial
  902. }
  903. Fl_Dial pstc {
  904. label {P.Stc.}
  905. tooltip {Punch Stretch} xywh {185 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  906. code0 {o->init("PPunchStretch");}
  907. class Fl_Osc_Dial
  908. }
  909. Fl_Dial pvel {
  910. label {P.Vel.}
  911. tooltip {Punch Velocity Sensing} xywh {215 237 25 25} box ROUND_UP_BOX labelsize 10 align 1 maximum 127 step 1
  912. code0 {o->init("PPunchVelocitySensing");}
  913. class Fl_Osc_Dial
  914. }
  915. Fl_Group ampenv {
  916. label {ADSynth Global - Amplitude Envelope} open
  917. xywh {10 75 205 70} box FLAT_BOX color 51 align 144
  918. code0 {o->init(ENV_ADSR, osc, loc, "GlobalPar/AmpEnvelope/");}
  919. class EnvelopeUI
  920. } {}
  921. Fl_Group amplfo {
  922. label {Amplitude LFO } open
  923. xywh {10 150 230 70} box FLAT_BOX color 47 align 144
  924. code0 {o->init(osc, loc, "GlobalPar/AmpLfo/");}
  925. class LFOUI
  926. } {}
  927. Fl_Check_Button rndgrp {
  928. label {Rnd Grp}
  929. 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
  930. code0 {o->init("Hrandgrouping");}
  931. class Fl_Osc_Check
  932. }
  933. }
  934. Fl_Group {} {
  935. label FILTER open
  936. xywh {250 5 285 265} box UP_FRAME labeltype EMBOSSED_LABEL labelfont 1 labelsize 13 align 17
  937. } {
  938. Fl_Group filterenv {
  939. label {ADSynth Global - Filter Envelope} open
  940. xywh {255 118 275 70} box FLAT_BOX color 51 align 144
  941. code0 {o->init(ENV_ADSR_FILTER, osc, loc, "GlobalPar/FilterEnvelope/");}
  942. class EnvelopeUI
  943. } {}
  944. Fl_Group filterlfo {
  945. label {Filter LFO} open
  946. xywh {255 195 230 70} box FLAT_BOX color 47 align 144
  947. code0 {o->init(osc, loc, "GlobalPar/FilterLfo/");}
  948. class LFOUI
  949. } {}
  950. Fl_Group filterui {
  951. label {ADsynth Global - Filter} open
  952. xywh {255 35 275 75} box FLAT_BOX color 50 align 144
  953. code0 {o->init(loc + "GlobalPar/PFilter",
  954. osc, loc, "GlobalPar/GlobalFilter/");}
  955. class FilterUI
  956. } {}
  957. }
  958. Fl_Check_Button stereo {
  959. label Stereo
  960. xywh {5 230 65 35} down_box DOWN_BOX labelsize 11
  961. code0 {o->init("PStereo");}
  962. class Fl_Osc_Check
  963. }
  964. Fl_Button {} {
  965. label {Show Voice List}
  966. callback {for (int i=0;i<NUM_VOICES;i++){
  967. voicelistitem[i]->refreshlist();
  968. }
  969. ADnoteVoiceList->show();}
  970. xywh {180 400 125 25} labelsize 12
  971. }
  972. Fl_Button {} {
  973. label {Show Voice Parameters}
  974. callback {ADnoteVoice->show();}
  975. xywh {5 400 170 25} labelsize 12
  976. }
  977. Fl_Button {} {
  978. label Close
  979. callback {ADnoteGlobalParameters->hide();}
  980. xywh {475 400 60 25} box THIN_UP_BOX
  981. }
  982. Fl_Button {} {
  983. label Resonance
  984. callback {resui->resonancewindow->redraw();
  985. resui->resonancewindow->show();}
  986. tooltip Resonance xywh {309 400 86 25} box THIN_UP_BOX labelsize 12
  987. }
  988. Fl_Button {} {
  989. label C
  990. callback {presetsui->copy(loc);}
  991. xywh {405 405 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
  992. }
  993. Fl_Button {} {
  994. label P
  995. callback {presetsui->paste(loc,this);}
  996. xywh {435 405 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
  997. }
  998. }
  999. Fl_Window ADnoteVoice {
  1000. label {ADsynth Voice Parameters} open
  1001. xywh {48 361 765 630} type Double
  1002. class Fl_Osc_Window visible
  1003. } {
  1004. Fl_Box {} {
  1005. xywh {0 0 0 0}
  1006. code0 {ADnoteVoice->base = loc;}
  1007. code1 {ADnoteVoice->osc = osc;}
  1008. }
  1009. Fl_Group advoice {open
  1010. xywh {0 0 765 595}
  1011. code0 {o->init(nvoice,loc, osc);}
  1012. code1 {o->show();}
  1013. class ADvoiceUI
  1014. } {}
  1015. Fl_Button {} {
  1016. label {Close Window}
  1017. callback {ADnoteVoice->hide();}
  1018. xywh {305 601 195 25} box THIN_UP_BOX labelfont 1
  1019. }
  1020. Fl_Counter currentvoicecounter {
  1021. label {Current Voice}
  1022. callback {nvoice=(int)o->value()-1;
  1023. advoice->change_voice(nvoice);}
  1024. xywh {10 601 130 25} type Simple labelfont 1 align 8 minimum 0 maximum 2 step 1 value 1 textfont 1 textsize 13
  1025. code0 {o->bounds(1,NUM_VOICES);}
  1026. }
  1027. Fl_Button {} {
  1028. label C
  1029. callback {presetsui->copy(ADnoteVoice->loc(),nvoice);}
  1030. xywh {705 609 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
  1031. }
  1032. Fl_Button {} {
  1033. label P
  1034. callback {presetsui->paste(ADnoteVoice->loc(),this,nvoice);}
  1035. xywh {735 609 25 15} box THIN_UP_BOX color 179 labelfont 1 labelsize 11 labelcolor 55
  1036. }
  1037. }
  1038. Fl_Window ADnoteVoiceList {
  1039. label {ADsynth Voices list} open
  1040. xywh {32 266 650 260} type Double hide
  1041. class Fl_Osc_Window
  1042. } {
  1043. Fl_Box {} {
  1044. xywh {0 0 0 0}
  1045. code0 {ADnoteVoiceList->base = loc;}
  1046. code1 {ADnoteVoiceList->osc = osc;}
  1047. }
  1048. Fl_Text_Display {} {
  1049. label {No.}
  1050. xywh {10 15 30 10} box NO_BOX labelfont 1 labelsize 11
  1051. }
  1052. Fl_Text_Display {} {
  1053. label Vol
  1054. xywh {145 15 30 10} box NO_BOX labelfont 1 labelsize 11
  1055. }
  1056. Fl_Text_Display {} {
  1057. label Detune
  1058. xywh {384 15 25 10} box NO_BOX labelfont 1 labelsize 11
  1059. }
  1060. Fl_Text_Display {} {
  1061. label Pan
  1062. xywh {210 15 30 10} box NO_BOX labelfont 1 labelsize 11
  1063. }
  1064. Fl_Text_Display {} {
  1065. label {Vib. Depth}
  1066. xywh {560 15 30 10} box NO_BOX labelfont 1 labelsize 11
  1067. }
  1068. Fl_Text_Display {} {
  1069. label {R.}
  1070. xywh {245 15 25 10} box NO_BOX labelfont 1 labelsize 11
  1071. }
  1072. Fl_Button {} {
  1073. label {Hide Voice List}
  1074. callback {ADnoteVoiceList->hide();}
  1075. xywh {255 237 125 20}
  1076. }
  1077. Fl_Scroll {} {open
  1078. xywh {0 15 640 220} type VERTICAL box THIN_UP_BOX
  1079. } {
  1080. Fl_Pack {} {open
  1081. xywh {0 20 620 210}
  1082. 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();}
  1083. } {}
  1084. }
  1085. }
  1086. }
  1087. Function {ADnoteUI(std::string loc_, Fl_Osc_Interface *osc_)} {open
  1088. } {
  1089. code {assert(osc_);
  1090. assert(!loc_.empty());
  1091. nvoice=0;
  1092. resui=new ResonanceUI(osc_, loc_+"GlobalPar/Reson/");
  1093. loc=loc_;
  1094. osc=osc_;
  1095. make_window();} {}
  1096. }
  1097. Function {~ADnoteUI()} {open
  1098. } {
  1099. code {ADnoteVoiceList->hide();
  1100. ADnoteGlobalParameters->hide();
  1101. ADnoteVoice->hide();
  1102. delete ADnoteVoiceList;
  1103. delete ADnoteGlobalParameters;
  1104. delete ADnoteVoice;
  1105. delete resui;} {}
  1106. }
  1107. Function {refresh()} {open
  1108. } {
  1109. code {amplfo->refresh();
  1110. freqlfo->refresh();
  1111. filterlfo->refresh();
  1112. ampenv->refresh();
  1113. freqenv->refresh();
  1114. filterenv->refresh();
  1115. filterui->refresh();
  1116. for (int i=0;i<NUM_VOICES;i++) voicelistitem[i]->refreshlist();
  1117. resui->refresh();
  1118. currentvoicecounter->do_callback();} {}
  1119. }
  1120. decl {ResonanceUI *resui;} {private local
  1121. }
  1122. decl {int nvoice;} {private local
  1123. }
  1124. decl {ADvoicelistitem *voicelistitem[NUM_VOICES];} {private local
  1125. }
  1126. decl {std::string loc;} {private local
  1127. }
  1128. decl {Fl_Osc_Interface *osc;} {private local
  1129. }
  1130. }