Skip to content

Commit

Permalink
Fix #170 freqToMidi
Browse files Browse the repository at this point in the history
  • Loading branch information
b2renger authored May 3, 2017
1 parent 55fda82 commit 85fc70c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ define(function (require) {
*/
p5.prototype.freqToMidi = function(f){
var mathlog2 = Math.log(f/440) / Math.log(2);
var m = Math.round(12*mathlog2)+57;
var m = Math.round(12*mathlog2)+69;
return m;
};

Expand Down Expand Up @@ -200,4 +200,4 @@ define(function (require) {
return o;
};

});
});

0 comments on commit 85fc70c

Please sign in to comment.