mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 06:44:57 +01:00
Fix -Wsign-compare
This commit is contained in:
parent
9970a243ec
commit
a3673809cf
3 changed files with 5 additions and 5 deletions
|
|
@ -384,7 +384,7 @@ LocalCandidatePYIN::getRemainingFeatures()
|
||||||
}
|
}
|
||||||
|
|
||||||
vector<float> mpOut = mp.process(tempPitchProb);
|
vector<float> mpOut = mp.process(tempPitchProb);
|
||||||
float prevFreq = 0;
|
//float prevFreq = 0;
|
||||||
for (size_t iFrame = 0; iFrame < nFrame; ++iFrame)
|
for (size_t iFrame = 0; iFrame < nFrame; ++iFrame)
|
||||||
{
|
{
|
||||||
if (mpOut[iFrame] > 0) {
|
if (mpOut[iFrame] > 0) {
|
||||||
|
|
@ -392,7 +392,7 @@ LocalCandidatePYIN::getRemainingFeatures()
|
||||||
pitchTracks[iCandidate][iFrame] = mpOut[iFrame];
|
pitchTracks[iCandidate][iFrame] = mpOut[iFrame];
|
||||||
freqSum[iCandidate] += mpOut[iFrame];
|
freqSum[iCandidate] += mpOut[iFrame];
|
||||||
freqNumber[iCandidate]++;
|
freqNumber[iCandidate]++;
|
||||||
prevFreq = mpOut[iFrame];
|
//prevFreq = mpOut[iFrame];
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -89,8 +89,8 @@ MonoPitchHMM::build()
|
||||||
for (size_t iPitch = 0; iPitch < m_nPitch; ++iPitch)
|
for (size_t iPitch = 0; iPitch < m_nPitch; ++iPitch)
|
||||||
{
|
{
|
||||||
int theoreticalMinNextPitch = static_cast<int>(iPitch)-static_cast<int>(m_transitionWidth/2);
|
int theoreticalMinNextPitch = static_cast<int>(iPitch)-static_cast<int>(m_transitionWidth/2);
|
||||||
int minNextPitch = iPitch>m_transitionWidth/2 ? iPitch-m_transitionWidth/2 : 0;
|
size_t minNextPitch = iPitch>m_transitionWidth/2 ? iPitch-m_transitionWidth/2 : 0;
|
||||||
int maxNextPitch = iPitch<m_nPitch-m_transitionWidth/2 ? iPitch+m_transitionWidth/2 : m_nPitch-1;
|
size_t maxNextPitch = iPitch<m_nPitch-m_transitionWidth/2 ? iPitch+m_transitionWidth/2 : m_nPitch-1;
|
||||||
|
|
||||||
// WEIGHT VECTOR
|
// WEIGHT VECTOR
|
||||||
double weightSum = 0;
|
double weightSum = 0;
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@ YinUtil::slowDifference(const double *in, double *yinBuffer, const size_t yinBuf
|
||||||
double delta ;
|
double delta ;
|
||||||
int startPoint = 0;
|
int startPoint = 0;
|
||||||
int endPoint = 0;
|
int endPoint = 0;
|
||||||
for (int i = 1; i < yinBufferSize; ++i) {
|
for (size_t i = 1; i < yinBufferSize; ++i) {
|
||||||
yinBuffer[i] = 0;
|
yinBuffer[i] = 0;
|
||||||
startPoint = yinBufferSize/2 - i/2;
|
startPoint = yinBufferSize/2 - i/2;
|
||||||
endPoint = startPoint + yinBufferSize;
|
endPoint = startPoint + yinBufferSize;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue