diff options
Diffstat (limited to 'libs/audiographer')
-rw-r--r-- | libs/audiographer/src/general/analyser.cc | 4 | ||||
-rw-r--r-- | libs/audiographer/src/general/loudness_reader.cc | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/libs/audiographer/src/general/analyser.cc b/libs/audiographer/src/general/analyser.cc index 930a2a95ab..639ab5d9ef 100644 --- a/libs/audiographer/src/general/analyser.cc +++ b/libs/audiographer/src/general/analyser.cc @@ -149,7 +149,7 @@ Analyser::process (ProcessContext<float> const & ctx) } float const * const data = ctx.data (); - for (unsigned int c = 0; c < _channels, c < _dbtp_plugins.size (); ++c) { + for (unsigned int c = 0; c < _channels && c < _dbtp_plugins.size (); ++c) { for (s = 0; s < n_samples; ++s) { _bufs[0][s] = data[s * _channels + c]; } @@ -247,7 +247,7 @@ Analyser::result () } const unsigned cmask = _result.n_channels - 1; // [0, 1] - for (unsigned int c = 0; c < _channels, c < _dbtp_plugins.size (); ++c) { + for (unsigned int c = 0; c < _channels && c < _dbtp_plugins.size (); ++c) { Vamp::Plugin::FeatureSet features = _dbtp_plugins.at(c)->getRemainingFeatures (); if (!features.empty () && features.size () == 2) { _result.have_dbtp = true; diff --git a/libs/audiographer/src/general/loudness_reader.cc b/libs/audiographer/src/general/loudness_reader.cc index 495d653d79..351b15f483 100644 --- a/libs/audiographer/src/general/loudness_reader.cc +++ b/libs/audiographer/src/general/loudness_reader.cc @@ -121,7 +121,7 @@ LoudnessReader::process (ProcessContext<float> const & ctx) } } - for (unsigned int c = processed_channels; c < _channels, c < _dbtp_plugins.size (); ++c) { + for (unsigned int c = processed_channels; c < _channels && c < _dbtp_plugins.size (); ++c) { samplecnt_t s; float const * const d = ctx.data (); for (s = 0; s < n_samples; ++s) { @@ -154,7 +154,7 @@ LoudnessReader::get_normalize_gain (float target_lufs, float target_dbtp) } } - for (unsigned int c = 0; c < _channels, c < _dbtp_plugins.size(); ++c) { + for (unsigned int c = 0; c < _channels && c < _dbtp_plugins.size(); ++c) { Vamp::Plugin::FeatureSet features = _dbtp_plugins.at(c)->getRemainingFeatures (); if (!features.empty () && features.size () == 2) { const float dbtp = features[0][0].values[0]; |