InstrumentTrack: fixed calculation in midiPitch()
InstrumentTrack::midiPitch() returned 16384 instead of 16383 if pitch was set to +100 cents. This commit fixes the calculation.
This commit is contained in:
@@ -108,7 +108,7 @@ public:
|
||||
// translate pitch to midi-pitch [0,16383]
|
||||
inline int midiPitch( void ) const
|
||||
{
|
||||
return (int)( ( m_pitchModel.value()+100 ) * 81.92 );
|
||||
return (int)( ( m_pitchModel.value()+100 ) * 16383 ) / 200;
|
||||
}
|
||||
|
||||
// play everything in given frame-range - creates note-play-handles
|
||||
|
||||
Reference in New Issue
Block a user