13
0

add dedicated line-up level for IEC1/DIN meter (15dbFS)

This commit is contained in:
Robin Gareus 2013-07-28 03:29:16 +02:00 committed by Paul Davis
parent d4c864d803
commit ff9296e17c
3 changed files with 24 additions and 4 deletions

View File

@ -85,8 +85,8 @@ LevelMeterBase::set_meter (PeakMeter* meter)
}
}
static float meter_lineup(float offset) {
switch (Config->get_meter_line_up_level()) {
static float meter_lineup_cfg(MeterLineUp lul, float offset) {
switch (lul) {
case MeteringLineUp24:
return offset + 6.0;
case MeteringLineUp20:
@ -101,6 +101,10 @@ static float meter_lineup(float offset) {
return offset;
}
static float meter_lineup(float offset) {
return meter_lineup_cfg(Config->get_meter_line_up_level(), offset);
}
static float vu_standard() {
// note - default meter config is +2dB (france)
switch (Config->get_meter_vu_standard()) {
@ -148,7 +152,7 @@ LevelMeterBase::update_meters ()
} else if (meter_type == MeterIEC1NOR) {
(*i).meter->set (meter_deflect_nordic (peak + meter_lineup(0)));
} else if (meter_type == MeterIEC1DIN) {
(*i).meter->set (meter_deflect_din (peak + meter_lineup(3.0)));
(*i).meter->set (meter_deflect_din (peak + meter_lineup_cfg(Config->get_meter_line_up_din(), 3.0)));
} else if (meter_type == MeterIEC2BBC || meter_type == MeterIEC2EBU) {
(*i).meter->set (meter_deflect_ppm (peak + meter_lineup(0)));
} else if (meter_type == MeterVU) {

View File

@ -1930,10 +1930,25 @@ RCOptionEditor::RCOptionEditor ()
mlu->add (MeteringLineUp18, _("-18dBFS (EBU, BBC)"));
mlu->add (MeteringLineUp15, _("-15dBFS (DIN)"));
Gtkmm2ext::UI::instance()->set_tip (mlu->tip_widget(), _("Configure meter-ticks and color-knee point for dBFS scale DPM, set reference/offset level for IEC PPM."));
Gtkmm2ext::UI::instance()->set_tip (mlu->tip_widget(), _("Configure meter-marks and color-knee point for dBFS scale DPM, set reference level for IEC1/Nordic, IEC2 PPM and VU meter."));
add_option (S_("Preferences|GUI"), mlu);
ComboOption<MeterLineUp>* mld = new ComboOption<MeterLineUp> (
"meter-line-up-din",
_("IEC1/DIN Meter line-up level; 0dBu"),
sigc::mem_fun (*_rc_config, &RCConfiguration::get_meter_line_up_din),
sigc::mem_fun (*_rc_config, &RCConfiguration::set_meter_line_up_din)
);
mld->add (MeteringLineUp24, _("-24dBFS (SMPTE US: 4dBu = -20dBFS)"));
mld->add (MeteringLineUp20, _("-20dBFS (SMPTE RP.0155)"));
mld->add (MeteringLineUp18, _("-18dBFS (EBU, BBC)"));
mld->add (MeteringLineUp15, _("-15dBFS (DIN)"));
Gtkmm2ext::UI::instance()->set_tip (mld->tip_widget(), _("Reference level for IEC1/DIN meter."));
add_option (S_("Preferences|GUI"), mld);
ComboOption<VUMeterStandard>* mvu = new ComboOption<VUMeterStandard> (
"meter-vu-standard",

View File

@ -151,6 +151,7 @@ CONFIG_VARIABLE (float, meter_hold, "meter-hold", 100.0f)
CONFIG_VARIABLE (float, meter_falloff, "meter-falloff", 32.0f)
CONFIG_VARIABLE (VUMeterStandard, meter_vu_standard, "meter-vu-standard", MeteringVUstandard)
CONFIG_VARIABLE (MeterLineUp, meter_line_up_level, "meter-line-up-level", MeteringLineUp18)
CONFIG_VARIABLE (MeterLineUp, meter_line_up_din, "meter-line-up-din", MeteringLineUp15)
CONFIG_VARIABLE (float, meter_peak, "meter-peak", 0.0f)
CONFIG_VARIABLE (bool, meter_style_led, "meter-style-led", true)