From 2721e1a0e391dd947df0cb9055f2e05012a62bb8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Nusser?= Date: Sat, 13 Feb 2021 12:35:45 +0100 Subject: Add position parameter of sample selection to settings. --- src/sample_selection.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/sample_selection.cc') diff --git a/src/sample_selection.cc b/src/sample_selection.cc index cec90b1..0ff2c51 100644 --- a/src/sample_selection.cc +++ b/src/sample_selection.cc @@ -69,16 +69,16 @@ const Sample* SampleSelection::get(level_t level, float position, std::size_t po float pos_opt{0.f}; float value_opt{std::numeric_limits::max()}; // the following three values are mostly for debugging - float random_opt = 0.; float close_opt = 0.; - float diverse_opt = 0.; float closepos_opt = 0.; + float random_opt = 0.; + float diverse_opt = 0.; // Note the magic values in front of the settings factors. const float f_close = 4.*settings.sample_selection_f_close.load(); + const float f_position = 1000.*settings.sample_selection_f_position.load(); // FIXME: huge factor for now const float f_diverse = (1./2.)*settings.sample_selection_f_diverse.load(); const float f_random = (1./3.)*settings.sample_selection_f_random.load(); - const float f_position = 1000.; // FIXME: get from settings float power_range = powerlist.getMaxPower() - powerlist.getMinPower(); // If all power values are the same then power_range is invalid but we want -- cgit v1.2.3