39 |
bool VelocityCurve::on_expose_event(GdkEventExpose* e) { |
bool VelocityCurve::on_expose_event(GdkEventExpose* e) { |
40 |
const Cairo::RefPtr<Cairo::Context>& cr = |
const Cairo::RefPtr<Cairo::Context>& cr = |
41 |
get_window()->create_cairo_context(); |
get_window()->create_cairo_context(); |
|
#if 0 |
|
|
} |
|
|
#endif |
|
42 |
#else |
#else |
43 |
bool VelocityCurve::on_draw(const Cairo::RefPtr<Cairo::Context>& cr) { |
bool VelocityCurve::on_draw(const Cairo::RefPtr<Cairo::Context>& cr) { |
44 |
#endif |
#endif |
74 |
|
|
75 |
|
|
76 |
CrossfadeCurve::CrossfadeCurve() : dimreg(0) { |
CrossfadeCurve::CrossfadeCurve() : dimreg(0) { |
77 |
set_size_request(280, 80); |
set_size_request(500, 100); |
78 |
} |
} |
79 |
|
|
80 |
#if (GTKMM_MAJOR_VERSION == 2 && GTKMM_MINOR_VERSION < 90) || GTKMM_MAJOR_VERSION < 2 |
#if (GTKMM_MAJOR_VERSION == 2 && GTKMM_MINOR_VERSION < 90) || GTKMM_MAJOR_VERSION < 2 |
81 |
bool CrossfadeCurve::on_expose_event(GdkEventExpose* e) { |
bool CrossfadeCurve::on_expose_event(GdkEventExpose* e) { |
82 |
const Cairo::RefPtr<Cairo::Context>& cr = |
const Cairo::RefPtr<Cairo::Context>& cr = |
83 |
get_window()->create_cairo_context(); |
get_window()->create_cairo_context(); |
|
#if 0 |
|
|
} |
|
|
#endif |
|
84 |
#else |
#else |
85 |
bool CrossfadeCurve::on_draw(const Cairo::RefPtr<Cairo::Context>& cr) { |
bool CrossfadeCurve::on_draw(const Cairo::RefPtr<Cairo::Context>& cr) { |
86 |
#endif |
#endif |
149 |
} |
} |
150 |
|
|
151 |
|
|
152 |
|
LFOGraph::LFOGraph() : dimreg(0) { |
153 |
|
set_size_request(500, 100); |
154 |
|
} |
155 |
|
|
156 |
|
#if (GTKMM_MAJOR_VERSION == 2 && GTKMM_MINOR_VERSION < 90) || GTKMM_MAJOR_VERSION < 2 |
157 |
|
bool LFOGraph::on_expose_event(GdkEventExpose* e) { |
158 |
|
const Cairo::RefPtr<Cairo::Context>& cr = |
159 |
|
get_window()->create_cairo_context(); |
160 |
|
#else |
161 |
|
bool LFOGraph::on_draw(const Cairo::RefPtr<Cairo::Context>& cr) { |
162 |
|
#endif |
163 |
|
if (dimreg) { |
164 |
|
const int w = get_width(); |
165 |
|
const int h = get_height(); |
166 |
|
const bool sensitive = is_sensitive(); |
167 |
|
const bool signedRange = this->signedRange(); |
168 |
|
const float visiblePeriods = 5.f; // such that minimum LFO frequency 0.1 Hz draws exactly a half period |
169 |
|
|
170 |
|
// short-hand functions for setting colors |
171 |
|
auto setGrayColor = [&] { |
172 |
|
cr->set_source_rgba(0.88, 0.88, 0.88, sensitive ? 1.0 : 0.3); |
173 |
|
}; |
174 |
|
auto setBlackColor = [&] { |
175 |
|
cr->set_source_rgba(0, 0, 0, sensitive ? 1.0 : 0.3); |
176 |
|
}; |
177 |
|
auto setGreenColor = [&] { |
178 |
|
cr->set_source_rgba(94/255.f, 219/255.f, 80/255.f, sensitive ? 1.0 : 0.3); |
179 |
|
}; |
180 |
|
auto setRedColor = [&] { |
181 |
|
cr->set_source_rgba(255.f, 44/255.f, 44/255.f, sensitive ? 1.0 : 0.3); |
182 |
|
}; |
183 |
|
/*auto setBlueColor = [&] { |
184 |
|
cr->set_source_rgba(53/255.f, 167/255.f, 255.f, sensitive ? 1.0 : 0.3); |
185 |
|
};*/ |
186 |
|
auto setOrangeColor = [&] { |
187 |
|
cr->set_source_rgba(255.f, 177/255.f, 82/255.f, sensitive ? 1.0 : 0.3); |
188 |
|
}; |
189 |
|
auto setWhiteColor = [&] { |
190 |
|
cr->set_source_rgba(255.f, 255.f, 255.f, sensitive ? 1.0 : 0.3); |
191 |
|
}; |
192 |
|
|
193 |
|
// fill background white |
194 |
|
cr->rectangle(0, 0, w, h); |
195 |
|
setWhiteColor(); |
196 |
|
cr->fill(); |
197 |
|
|
198 |
|
// draw horizontal center line (dashed gray) if LFO range is signed |
199 |
|
if (signedRange) { |
200 |
|
cr->move_to(0, h/2); |
201 |
|
cr->line_to(w, h/2); |
202 |
|
cr->set_line_width(2); |
203 |
|
setGrayColor(); |
204 |
|
cr->set_dash(std::vector<double>{ 7, 5 }, 0 /*offset*/); |
205 |
|
cr->stroke(); |
206 |
|
} |
207 |
|
|
208 |
|
// draw a vertical line for each second |
209 |
|
for (int period = 1; period < visiblePeriods; ++period) { |
210 |
|
int x = float(w) / float(visiblePeriods) * period; |
211 |
|
cr->move_to(x, 0); |
212 |
|
cr->line_to(x, h); |
213 |
|
cr->set_line_width(2); |
214 |
|
setGrayColor(); |
215 |
|
cr->set_dash(std::vector<double>{ 5, 3 }, 0 /*offset*/); |
216 |
|
cr->stroke(); |
217 |
|
} |
218 |
|
|
219 |
|
// how many curves shall we draw, two or one? |
220 |
|
const int runs = (hasControllerAssigned()) ? 2 : 1; |
221 |
|
// only draw the two curves in dashed style if they're very close to each other |
222 |
|
const bool dashedCurves = (runs == 2 && controllerDepth() < 63); |
223 |
|
// draw the required amount of curves |
224 |
|
for (int run = 0; run < runs; ++run) { |
225 |
|
// setup the LFO generator with the relevant parameters |
226 |
|
lfo.setup({ |
227 |
|
.waveType = waveType(), |
228 |
|
.rangeType = (signedRange) ? LinuxSampler::LFO::range_signed : LinuxSampler::LFO::range_unsigned, |
229 |
|
.frequency = frequency(), |
230 |
|
.phase = phase(), |
231 |
|
.startLevel = startLevel(), |
232 |
|
.internalDepth = internalDepth(), |
233 |
|
.midiControllerDepth = controllerDepth(), |
234 |
|
.flipPolarity = flipPolarity(), |
235 |
|
.samplerate = w / visiblePeriods, |
236 |
|
.maxValue = (signedRange) ? h/2 : h, |
237 |
|
}); |
238 |
|
// 1st curve reflects min. CC value, 2nd curve max. CC value |
239 |
|
lfo.setMIDICtrlValue( (run == 0) ? 0 : 127 ); |
240 |
|
|
241 |
|
// the actual render/draw loop |
242 |
|
for (int x = 0; x < w ; ++x) { |
243 |
|
const float y = |
244 |
|
(signedRange) ? |
245 |
|
h/2 - lfo.render() : |
246 |
|
h - lfo.render(); |
247 |
|
if (x == 0) |
248 |
|
cr->move_to(x, y); |
249 |
|
else |
250 |
|
cr->line_to(x, y); |
251 |
|
} |
252 |
|
cr->set_line_width( (frequency() <= 4.f) ? 2 : 1 ); |
253 |
|
if (runs == 1) |
254 |
|
setOrangeColor(); |
255 |
|
else if (run == 0) |
256 |
|
setGreenColor(); |
257 |
|
else |
258 |
|
setRedColor(); |
259 |
|
if (dashedCurves) |
260 |
|
cr->set_dash(std::vector<double>{ 3, 3 }, (run == 0) ? 0 : 3 /*offset*/); |
261 |
|
else |
262 |
|
cr->set_dash(std::vector<double>(), 0 /*offset*/); |
263 |
|
cr->stroke(); |
264 |
|
} |
265 |
|
|
266 |
|
// draw text legend |
267 |
|
if (runs == 2) { |
268 |
|
setRedColor(); |
269 |
|
cr->move_to(2, 10); |
270 |
|
cr->show_text("CC Max."); |
271 |
|
|
272 |
|
setGreenColor(); |
273 |
|
cr->move_to(2, 23); |
274 |
|
cr->show_text("CC Min."); |
275 |
|
} else { // no controller assigned, internal depth only ... |
276 |
|
setOrangeColor(); |
277 |
|
cr->move_to(2, 10); |
278 |
|
cr->show_text("Const. Depth"); |
279 |
|
} |
280 |
|
// draw text legend for each second ("1s", "2s", ...) |
281 |
|
for (int period = 1; period < visiblePeriods; ++period) { |
282 |
|
int x = float(w) / float(visiblePeriods) * period; |
283 |
|
setBlackColor(); |
284 |
|
cr->move_to(x - 13, h - 3); |
285 |
|
cr->show_text(ToString(period) + "s"); |
286 |
|
} |
287 |
|
} |
288 |
|
return true; |
289 |
|
} |
290 |
|
|
291 |
|
|
292 |
EGStateOptions::EGStateOptions() : HBox(), |
EGStateOptions::EGStateOptions() : HBox(), |
293 |
label(_("May be cancelled: ")), |
label(_("May be cancelled: ")), |
294 |
checkBoxAttack(_("Attack")), |
checkBoxAttack(_("Attack")), |
351 |
eEG1ControllerAttackInfluence(_("Controller attack influence"), 0, 3), |
eEG1ControllerAttackInfluence(_("Controller attack influence"), 0, 3), |
352 |
eEG1ControllerDecayInfluence(_("Controller decay influence"), 0, 3), |
eEG1ControllerDecayInfluence(_("Controller decay influence"), 0, 3), |
353 |
eEG1ControllerReleaseInfluence(_("Controller release influence"), 0, 3), |
eEG1ControllerReleaseInfluence(_("Controller release influence"), 0, 3), |
354 |
|
eLFO1Wave(_("Wave Form")), |
355 |
eLFO1Frequency(_("Frequency"), 0.1, 10, 2), |
eLFO1Frequency(_("Frequency"), 0.1, 10, 2), |
356 |
|
eLFO1Phase(_("Phase"), 0.0, 360.0, 2), |
357 |
eLFO1InternalDepth(_("Internal depth"), 0, 1200), |
eLFO1InternalDepth(_("Internal depth"), 0, 1200), |
358 |
eLFO1ControlDepth(_("Control depth"), 0, 1200), |
eLFO1ControlDepth(_("Control depth"), 0, 1200), |
359 |
eLFO1Controller(_("Controller")), |
eLFO1Controller(_("Controller")), |
371 |
eEG2ControllerAttackInfluence(_("Controller attack influence"), 0, 3), |
eEG2ControllerAttackInfluence(_("Controller attack influence"), 0, 3), |
372 |
eEG2ControllerDecayInfluence(_("Controller decay influence"), 0, 3), |
eEG2ControllerDecayInfluence(_("Controller decay influence"), 0, 3), |
373 |
eEG2ControllerReleaseInfluence(_("Controller release influence"), 0, 3), |
eEG2ControllerReleaseInfluence(_("Controller release influence"), 0, 3), |
374 |
|
eLFO2Wave(_("Wave Form")), |
375 |
eLFO2Frequency(_("Frequency"), 0.1, 10, 2), |
eLFO2Frequency(_("Frequency"), 0.1, 10, 2), |
376 |
|
eLFO2Phase(_("Phase"), 0.0, 360.0, 2), |
377 |
eLFO2InternalDepth(_("Internal depth"), 0, 1200), |
eLFO2InternalDepth(_("Internal depth"), 0, 1200), |
378 |
eLFO2ControlDepth(_("Control depth"), 0, 1200), |
eLFO2ControlDepth(_("Control depth"), 0, 1200), |
379 |
eLFO2Controller(_("Controller")), |
eLFO2Controller(_("Controller")), |
381 |
eLFO2Sync(_("Sync")), |
eLFO2Sync(_("Sync")), |
382 |
eEG3Attack(_("Attack"), 0, 10, 3), |
eEG3Attack(_("Attack"), 0, 10, 3), |
383 |
eEG3Depth(_("Depth"), -1200, 1200), |
eEG3Depth(_("Depth"), -1200, 1200), |
384 |
|
eLFO3Wave(_("Wave Form")), |
385 |
eLFO3Frequency(_("Frequency"), 0.1, 10, 2), |
eLFO3Frequency(_("Frequency"), 0.1, 10, 2), |
386 |
|
eLFO3Phase(_("Phase"), 0.0, 360.0, 2), |
387 |
eLFO3InternalDepth(_("Internal depth"), 0, 1200), |
eLFO3InternalDepth(_("Internal depth"), 0, 1200), |
388 |
eLFO3ControlDepth(_("Control depth"), 0, 1200), |
eLFO3ControlDepth(_("Control depth"), 0, 1200), |
389 |
eLFO3Controller(_("Controller")), |
eLFO3Controller(_("Controller")), |
390 |
|
eLFO3FlipPhase(_("Flip phase")), |
391 |
eLFO3Sync(_("Sync")), |
eLFO3Sync(_("Sync")), |
392 |
eVCFEnabled(_("Enabled")), |
eVCFEnabled(_("Enabled")), |
393 |
eVCFType(_("Type")), |
eVCFType(_("Type")), |
472 |
&gig::eg_opt_t::Decay2Cancel); |
&gig::eg_opt_t::Decay2Cancel); |
473 |
connect(eEG1StateOptions.checkBoxRelease, &gig::DimensionRegion::EG1Options, |
connect(eEG1StateOptions.checkBoxRelease, &gig::DimensionRegion::EG1Options, |
474 |
&gig::eg_opt_t::ReleaseCancel); |
&gig::eg_opt_t::ReleaseCancel); |
475 |
|
connect(eLFO1Wave, &gig::DimensionRegion::LFO1WaveForm); |
476 |
connect(eLFO1Frequency, &gig::DimensionRegion::LFO1Frequency); |
connect(eLFO1Frequency, &gig::DimensionRegion::LFO1Frequency); |
477 |
|
connect(eLFO1Phase, &gig::DimensionRegion::LFO1Phase); |
478 |
connect(eLFO1InternalDepth, &gig::DimensionRegion::LFO1InternalDepth); |
connect(eLFO1InternalDepth, &gig::DimensionRegion::LFO1InternalDepth); |
479 |
connect(eLFO1ControlDepth, &gig::DimensionRegion::LFO1ControlDepth); |
connect(eLFO1ControlDepth, &gig::DimensionRegion::LFO1ControlDepth); |
480 |
connect(eLFO1Controller, &gig::DimensionRegion::LFO1Controller); |
connect(eLFO1Controller, &gig::DimensionRegion::LFO1Controller); |
505 |
&gig::eg_opt_t::Decay2Cancel); |
&gig::eg_opt_t::Decay2Cancel); |
506 |
connect(eEG2StateOptions.checkBoxRelease, &gig::DimensionRegion::EG2Options, |
connect(eEG2StateOptions.checkBoxRelease, &gig::DimensionRegion::EG2Options, |
507 |
&gig::eg_opt_t::ReleaseCancel); |
&gig::eg_opt_t::ReleaseCancel); |
508 |
|
connect(eLFO2Wave, &gig::DimensionRegion::LFO2WaveForm); |
509 |
connect(eLFO2Frequency, &gig::DimensionRegion::LFO2Frequency); |
connect(eLFO2Frequency, &gig::DimensionRegion::LFO2Frequency); |
510 |
|
connect(eLFO2Phase, &gig::DimensionRegion::LFO2Phase); |
511 |
connect(eLFO2InternalDepth, &gig::DimensionRegion::LFO2InternalDepth); |
connect(eLFO2InternalDepth, &gig::DimensionRegion::LFO2InternalDepth); |
512 |
connect(eLFO2ControlDepth, &gig::DimensionRegion::LFO2ControlDepth); |
connect(eLFO2ControlDepth, &gig::DimensionRegion::LFO2ControlDepth); |
513 |
connect(eLFO2Controller, &gig::DimensionRegion::LFO2Controller); |
connect(eLFO2Controller, &gig::DimensionRegion::LFO2Controller); |
515 |
connect(eLFO2Sync, &gig::DimensionRegion::LFO2Sync); |
connect(eLFO2Sync, &gig::DimensionRegion::LFO2Sync); |
516 |
connect(eEG3Attack, &gig::DimensionRegion::EG3Attack); |
connect(eEG3Attack, &gig::DimensionRegion::EG3Attack); |
517 |
connect(eEG3Depth, &gig::DimensionRegion::EG3Depth); |
connect(eEG3Depth, &gig::DimensionRegion::EG3Depth); |
518 |
|
connect(eLFO3Wave, &gig::DimensionRegion::LFO3WaveForm); |
519 |
connect(eLFO3Frequency, &gig::DimensionRegion::LFO3Frequency); |
connect(eLFO3Frequency, &gig::DimensionRegion::LFO3Frequency); |
520 |
|
connect(eLFO3Phase, &gig::DimensionRegion::LFO3Phase); |
521 |
connect(eLFO3InternalDepth, &gig::DimensionRegion::LFO3InternalDepth); |
connect(eLFO3InternalDepth, &gig::DimensionRegion::LFO3InternalDepth); |
522 |
connect(eLFO3ControlDepth, &gig::DimensionRegion::LFO3ControlDepth); |
connect(eLFO3ControlDepth, &gig::DimensionRegion::LFO3ControlDepth); |
523 |
connect(eLFO3Controller, &gig::DimensionRegion::LFO3Controller); |
connect(eLFO3Controller, &gig::DimensionRegion::LFO3Controller); |
524 |
|
connect(eLFO3FlipPhase, &gig::DimensionRegion::LFO3FlipPhase); |
525 |
connect(eLFO3Sync, &gig::DimensionRegion::LFO3Sync); |
connect(eLFO3Sync, &gig::DimensionRegion::LFO3Sync); |
526 |
connect(eVCFEnabled, &gig::DimensionRegion::VCFEnabled); |
connect(eVCFEnabled, &gig::DimensionRegion::VCFEnabled); |
527 |
connect(eVCFType, &gig::DimensionRegion::VCFType); |
connect(eVCFType, &gig::DimensionRegion::VCFType); |
586 |
sigc::mem_fun(*this, &DimRegionEdit::onButtonSelectSamplePressed) |
sigc::mem_fun(*this, &DimRegionEdit::onButtonSelectSamplePressed) |
587 |
); |
); |
588 |
|
|
589 |
for (int i = 0 ; i < 7 ; i++) { |
for (int i = 0 ; i < 9 ; i++) { |
590 |
#if USE_GTKMM_GRID |
#if USE_GTKMM_GRID |
591 |
table[i] = new Gtk::Grid; |
table[i] = new Gtk::Grid; |
592 |
table[i]->set_column_spacing(7); |
table[i]->set_column_spacing(7); |
691 |
eLFO2FlipPhase.set_tip( |
eLFO2FlipPhase.set_tip( |
692 |
"Inverts the LFO's generated wave vertically." |
"Inverts the LFO's generated wave vertically." |
693 |
); |
); |
694 |
|
eLFO3FlipPhase.set_tip( |
695 |
|
"Inverts the LFO's generated wave vertically." |
696 |
|
); |
697 |
|
|
698 |
pageno = 0; |
pageno = 0; |
699 |
rowno = 0; |
rowno = 0; |
763 |
nextPage(); |
nextPage(); |
764 |
|
|
765 |
addHeader(_("Amplitude Oscillator (LFO1)")); |
addHeader(_("Amplitude Oscillator (LFO1)")); |
766 |
|
addProp(eLFO1Wave); |
767 |
addProp(eLFO1Frequency); |
addProp(eLFO1Frequency); |
768 |
|
addProp(eLFO1Phase); |
769 |
addProp(eLFO1InternalDepth); |
addProp(eLFO1InternalDepth); |
770 |
addProp(eLFO1ControlDepth); |
addProp(eLFO1ControlDepth); |
771 |
{ |
{ |
783 |
addProp(eLFO1Controller); |
addProp(eLFO1Controller); |
784 |
addProp(eLFO1FlipPhase); |
addProp(eLFO1FlipPhase); |
785 |
addProp(eLFO1Sync); |
addProp(eLFO1Sync); |
786 |
|
{ |
787 |
|
Gtk::Frame* frame = new Gtk::Frame; |
788 |
|
frame->add(lfo1Graph); |
789 |
|
// on Gtk 3 there is no margin at all by default |
790 |
|
#if GTKMM_MAJOR_VERSION >= 3 |
791 |
|
frame->set_margin_top(12); |
792 |
|
frame->set_margin_bottom(12); |
793 |
|
#endif |
794 |
|
#if USE_GTKMM_GRID |
795 |
|
table[pageno]->attach(*frame, 1, rowno, 2); |
796 |
|
#else |
797 |
|
table[pageno]->attach(*frame, 1, 3, rowno, rowno + 1, |
798 |
|
Gtk::SHRINK, Gtk::SHRINK); |
799 |
|
#endif |
800 |
|
rowno++; |
801 |
|
} |
802 |
|
eLFO1Wave.signal_value_changed().connect( |
803 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
804 |
|
); |
805 |
|
eLFO1Frequency.signal_value_changed().connect( |
806 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
807 |
|
); |
808 |
|
eLFO1Phase.signal_value_changed().connect( |
809 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
810 |
|
); |
811 |
|
eLFO1InternalDepth.signal_value_changed().connect( |
812 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
813 |
|
); |
814 |
|
eLFO1ControlDepth.signal_value_changed().connect( |
815 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
816 |
|
); |
817 |
|
eLFO1Controller.signal_value_changed().connect( |
818 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
819 |
|
); |
820 |
|
eLFO1FlipPhase.signal_value_changed().connect( |
821 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
822 |
|
); |
823 |
|
eLFO1Sync.signal_value_changed().connect( |
824 |
|
sigc::mem_fun(lfo1Graph, &LFOGraph::queue_draw) |
825 |
|
); |
826 |
|
|
827 |
|
nextPage(); |
828 |
|
|
829 |
addHeader(_("Crossfade")); |
addHeader(_("Crossfade")); |
830 |
addProp(eAttenuationController); |
addProp(eAttenuationController); |
831 |
addProp(eInvertAttenuationController); |
addProp(eInvertAttenuationController); |
968 |
addProp(eEG2ControllerDecayInfluence); |
addProp(eEG2ControllerDecayInfluence); |
969 |
addProp(eEG2ControllerReleaseInfluence); |
addProp(eEG2ControllerReleaseInfluence); |
970 |
addLine(eEG2StateOptions); |
addLine(eEG2StateOptions); |
971 |
|
|
972 |
|
nextPage(); |
973 |
|
|
974 |
lLFO2 = addHeader(_("Filter Cutoff Oscillator (LFO2)")); |
lLFO2 = addHeader(_("Filter Cutoff Oscillator (LFO2)")); |
975 |
|
addProp(eLFO2Wave); |
976 |
addProp(eLFO2Frequency); |
addProp(eLFO2Frequency); |
977 |
|
addProp(eLFO2Phase); |
978 |
addProp(eLFO2InternalDepth); |
addProp(eLFO2InternalDepth); |
979 |
addProp(eLFO2ControlDepth); |
addProp(eLFO2ControlDepth); |
980 |
{ |
{ |
992 |
addProp(eLFO2Controller); |
addProp(eLFO2Controller); |
993 |
addProp(eLFO2FlipPhase); |
addProp(eLFO2FlipPhase); |
994 |
addProp(eLFO2Sync); |
addProp(eLFO2Sync); |
995 |
|
{ |
996 |
|
Gtk::Frame* frame = new Gtk::Frame; |
997 |
|
frame->add(lfo2Graph); |
998 |
|
// on Gtk 3 there is no margin at all by default |
999 |
|
#if GTKMM_MAJOR_VERSION >= 3 |
1000 |
|
frame->set_margin_top(12); |
1001 |
|
frame->set_margin_bottom(12); |
1002 |
|
#endif |
1003 |
|
#if USE_GTKMM_GRID |
1004 |
|
table[pageno]->attach(*frame, 1, rowno, 2); |
1005 |
|
#else |
1006 |
|
table[pageno]->attach(*frame, 1, 3, rowno, rowno + 1, |
1007 |
|
Gtk::SHRINK, Gtk::SHRINK); |
1008 |
|
#endif |
1009 |
|
rowno++; |
1010 |
|
} |
1011 |
|
eLFO2Wave.signal_value_changed().connect( |
1012 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1013 |
|
); |
1014 |
|
eLFO2Frequency.signal_value_changed().connect( |
1015 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1016 |
|
); |
1017 |
|
eLFO2Phase.signal_value_changed().connect( |
1018 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1019 |
|
); |
1020 |
|
eLFO2InternalDepth.signal_value_changed().connect( |
1021 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1022 |
|
); |
1023 |
|
eLFO2ControlDepth.signal_value_changed().connect( |
1024 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1025 |
|
); |
1026 |
|
eLFO2Controller.signal_value_changed().connect( |
1027 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1028 |
|
); |
1029 |
|
eLFO2FlipPhase.signal_value_changed().connect( |
1030 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1031 |
|
); |
1032 |
|
eLFO2Sync.signal_value_changed().connect( |
1033 |
|
sigc::mem_fun(lfo2Graph, &LFOGraph::queue_draw) |
1034 |
|
); |
1035 |
|
|
1036 |
nextPage(); |
nextPage(); |
1037 |
|
|
1042 |
addProp(eEG3Attack); |
addProp(eEG3Attack); |
1043 |
addProp(eEG3Depth); |
addProp(eEG3Depth); |
1044 |
addHeader(_("Pitch Oscillator (LFO3)")); |
addHeader(_("Pitch Oscillator (LFO3)")); |
1045 |
|
addProp(eLFO3Wave); |
1046 |
addProp(eLFO3Frequency); |
addProp(eLFO3Frequency); |
1047 |
|
addProp(eLFO3Phase); |
1048 |
addProp(eLFO3InternalDepth); |
addProp(eLFO3InternalDepth); |
1049 |
addProp(eLFO3ControlDepth); |
addProp(eLFO3ControlDepth); |
1050 |
{ |
{ |
1060 |
eLFO3Controller.set_choices(choices, values); |
eLFO3Controller.set_choices(choices, values); |
1061 |
} |
} |
1062 |
addProp(eLFO3Controller); |
addProp(eLFO3Controller); |
1063 |
|
addProp(eLFO3FlipPhase); |
1064 |
addProp(eLFO3Sync); |
addProp(eLFO3Sync); |
1065 |
|
{ |
1066 |
|
Gtk::Frame* frame = new Gtk::Frame; |
1067 |
|
frame->add(lfo3Graph); |
1068 |
|
// on Gtk 3 there is no margin at all by default |
1069 |
|
#if GTKMM_MAJOR_VERSION >= 3 |
1070 |
|
frame->set_margin_top(12); |
1071 |
|
frame->set_margin_bottom(12); |
1072 |
|
#endif |
1073 |
|
#if USE_GTKMM_GRID |
1074 |
|
table[pageno]->attach(*frame, 1, rowno, 2); |
1075 |
|
#else |
1076 |
|
table[pageno]->attach(*frame, 1, 3, rowno, rowno + 1, |
1077 |
|
Gtk::SHRINK, Gtk::SHRINK); |
1078 |
|
#endif |
1079 |
|
rowno++; |
1080 |
|
} |
1081 |
|
eLFO3Wave.signal_value_changed().connect( |
1082 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1083 |
|
); |
1084 |
|
eLFO3Frequency.signal_value_changed().connect( |
1085 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1086 |
|
); |
1087 |
|
eLFO3Phase.signal_value_changed().connect( |
1088 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1089 |
|
); |
1090 |
|
eLFO3InternalDepth.signal_value_changed().connect( |
1091 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1092 |
|
); |
1093 |
|
eLFO3ControlDepth.signal_value_changed().connect( |
1094 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1095 |
|
); |
1096 |
|
eLFO3Controller.signal_value_changed().connect( |
1097 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1098 |
|
); |
1099 |
|
eLFO3FlipPhase.signal_value_changed().connect( |
1100 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1101 |
|
); |
1102 |
|
eLFO3Sync.signal_value_changed().connect( |
1103 |
|
sigc::mem_fun(lfo3Graph, &LFOGraph::queue_draw) |
1104 |
|
); |
1105 |
|
|
1106 |
nextPage(); |
nextPage(); |
1107 |
|
|
1255 |
sigc::mem_fun(*this, &DimRegionEdit::loop_infinite_toggled)); |
sigc::mem_fun(*this, &DimRegionEdit::loop_infinite_toggled)); |
1256 |
|
|
1257 |
append_page(*table[0], _("Sample")); |
append_page(*table[0], _("Sample")); |
1258 |
append_page(*table[1], _("Amplitude (1)")); |
append_page(*table[1], _("Amp (1)")); |
1259 |
append_page(*table[2], _("Amplitude (2)")); |
append_page(*table[2], _("Amp (2)")); |
1260 |
append_page(*table[3], _("Filter (1)")); |
append_page(*table[3], _("Amp (3)")); |
1261 |
append_page(*table[4], _("Filter (2)")); |
append_page(*table[4], _("Filter (1)")); |
1262 |
append_page(*table[5], _("Pitch")); |
append_page(*table[5], _("Filter (2)")); |
1263 |
append_page(*table[6], _("Misc")); |
append_page(*table[6], _("Filter (3)")); |
1264 |
|
append_page(*table[7], _("Pitch")); |
1265 |
|
append_page(*table[8], _("Misc")); |
1266 |
|
|
1267 |
Settings::singleton()->showTooltips.get_proxy().signal_changed().connect( |
Settings::singleton()->showTooltips.get_proxy().signal_changed().connect( |
1268 |
sigc::mem_fun(*this, &DimRegionEdit::on_show_tooltips_changed) |
sigc::mem_fun(*this, &DimRegionEdit::on_show_tooltips_changed) |
1471 |
release_curve.set_dim_region(d); |
release_curve.set_dim_region(d); |
1472 |
cutoff_curve.set_dim_region(d); |
cutoff_curve.set_dim_region(d); |
1473 |
crossfade_curve.set_dim_region(d); |
crossfade_curve.set_dim_region(d); |
1474 |
|
lfo1Graph.set_dim_region(d); |
1475 |
|
lfo2Graph.set_dim_region(d); |
1476 |
|
lfo3Graph.set_dim_region(d); |
1477 |
|
|
1478 |
set_sensitive(d); |
set_sensitive(d); |
1479 |
if (!d) return; |
if (!d) return; |
1497 |
eEG1StateOptions.checkBoxDecay1.set_value(d->EG1Options.Decay1Cancel); |
eEG1StateOptions.checkBoxDecay1.set_value(d->EG1Options.Decay1Cancel); |
1498 |
eEG1StateOptions.checkBoxDecay2.set_value(d->EG1Options.Decay2Cancel); |
eEG1StateOptions.checkBoxDecay2.set_value(d->EG1Options.Decay2Cancel); |
1499 |
eEG1StateOptions.checkBoxRelease.set_value(d->EG1Options.ReleaseCancel); |
eEG1StateOptions.checkBoxRelease.set_value(d->EG1Options.ReleaseCancel); |
1500 |
|
eLFO1Wave.set_value(d->LFO1WaveForm); |
1501 |
eLFO1Frequency.set_value(d->LFO1Frequency); |
eLFO1Frequency.set_value(d->LFO1Frequency); |
1502 |
|
eLFO1Phase.set_value(d->LFO1Phase); |
1503 |
eLFO1InternalDepth.set_value(d->LFO1InternalDepth); |
eLFO1InternalDepth.set_value(d->LFO1InternalDepth); |
1504 |
eLFO1ControlDepth.set_value(d->LFO1ControlDepth); |
eLFO1ControlDepth.set_value(d->LFO1ControlDepth); |
1505 |
eLFO1Controller.set_value(d->LFO1Controller); |
eLFO1Controller.set_value(d->LFO1Controller); |
1522 |
eEG2StateOptions.checkBoxDecay1.set_value(d->EG2Options.Decay1Cancel); |
eEG2StateOptions.checkBoxDecay1.set_value(d->EG2Options.Decay1Cancel); |
1523 |
eEG2StateOptions.checkBoxDecay2.set_value(d->EG2Options.Decay2Cancel); |
eEG2StateOptions.checkBoxDecay2.set_value(d->EG2Options.Decay2Cancel); |
1524 |
eEG2StateOptions.checkBoxRelease.set_value(d->EG2Options.ReleaseCancel); |
eEG2StateOptions.checkBoxRelease.set_value(d->EG2Options.ReleaseCancel); |
1525 |
|
eLFO2Wave.set_value(d->LFO2WaveForm); |
1526 |
eLFO2Frequency.set_value(d->LFO2Frequency); |
eLFO2Frequency.set_value(d->LFO2Frequency); |
1527 |
|
eLFO2Phase.set_value(d->LFO2Phase); |
1528 |
eLFO2InternalDepth.set_value(d->LFO2InternalDepth); |
eLFO2InternalDepth.set_value(d->LFO2InternalDepth); |
1529 |
eLFO2ControlDepth.set_value(d->LFO2ControlDepth); |
eLFO2ControlDepth.set_value(d->LFO2ControlDepth); |
1530 |
eLFO2Controller.set_value(d->LFO2Controller); |
eLFO2Controller.set_value(d->LFO2Controller); |
1532 |
eLFO2Sync.set_value(d->LFO2Sync); |
eLFO2Sync.set_value(d->LFO2Sync); |
1533 |
eEG3Attack.set_value(d->EG3Attack); |
eEG3Attack.set_value(d->EG3Attack); |
1534 |
eEG3Depth.set_value(d->EG3Depth); |
eEG3Depth.set_value(d->EG3Depth); |
1535 |
|
eLFO3Wave.set_value(d->LFO3WaveForm); |
1536 |
eLFO3Frequency.set_value(d->LFO3Frequency); |
eLFO3Frequency.set_value(d->LFO3Frequency); |
1537 |
|
eLFO3Phase.set_value(d->LFO3Phase); |
1538 |
eLFO3InternalDepth.set_value(d->LFO3InternalDepth); |
eLFO3InternalDepth.set_value(d->LFO3InternalDepth); |
1539 |
eLFO3ControlDepth.set_value(d->LFO3ControlDepth); |
eLFO3ControlDepth.set_value(d->LFO3ControlDepth); |
1540 |
eLFO3Controller.set_value(d->LFO3Controller); |
eLFO3Controller.set_value(d->LFO3Controller); |
1541 |
|
eLFO3FlipPhase.set_value(d->LFO3FlipPhase); |
1542 |
eLFO3Sync.set_value(d->LFO3Sync); |
eLFO3Sync.set_value(d->LFO3Sync); |
1543 |
eVCFEnabled.set_value(d->VCFEnabled); |
eVCFEnabled.set_value(d->VCFEnabled); |
1544 |
eVCFType.set_value(d->VCFType); |
eVCFType.set_value(d->VCFType); |
1676 |
eEG2ControllerReleaseInfluence.set_sensitive(sensitive); |
eEG2ControllerReleaseInfluence.set_sensitive(sensitive); |
1677 |
eEG2StateOptions.set_sensitive(sensitive); |
eEG2StateOptions.set_sensitive(sensitive); |
1678 |
lLFO2->set_sensitive(sensitive); |
lLFO2->set_sensitive(sensitive); |
1679 |
|
eLFO2Wave.set_sensitive(sensitive); |
1680 |
eLFO2Frequency.set_sensitive(sensitive); |
eLFO2Frequency.set_sensitive(sensitive); |
1681 |
|
eLFO2Phase.set_sensitive(sensitive); |
1682 |
eLFO2InternalDepth.set_sensitive(sensitive); |
eLFO2InternalDepth.set_sensitive(sensitive); |
1683 |
eLFO2ControlDepth.set_sensitive(sensitive); |
eLFO2ControlDepth.set_sensitive(sensitive); |
1684 |
eLFO2Controller.set_sensitive(sensitive); |
eLFO2Controller.set_sensitive(sensitive); |
1685 |
eLFO2FlipPhase.set_sensitive(sensitive); |
eLFO2FlipPhase.set_sensitive(sensitive); |
1686 |
eLFO2Sync.set_sensitive(sensitive); |
eLFO2Sync.set_sensitive(sensitive); |
1687 |
|
lfo2Graph.set_sensitive(sensitive); |
1688 |
if (sensitive) { |
if (sensitive) { |
1689 |
VCFCutoffController_changed(); |
VCFCutoffController_changed(); |
1690 |
VCFResonanceController_changed(); |
VCFResonanceController_changed(); |