diff --git a/CHANGELOG.md b/CHANGELOG.md index 67f1b7c..6821ece 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Change Log +## [1.0.4] - 2017-11-16 +### Fixed +- Fixed an error where Note On messages were misinterpreted as Control Change +messages. Thanks [@grz0zrg]. +- Updated LICENSE file to match other ROLI ISC licensed projects. Thanks +[@bensupper]. + ## [1.0.3] - 2017-10-18 ### Fixed - Fixed error in docs usage example. @@ -10,7 +17,7 @@ ### Fixed - Fixed scroll positions set by in-page links in docs. -- Fixed script tag src typo in docs. +- Fixed script tag src typo in docs. Thanks [@manifestinteractive]. ## [1.0.1] - 2017-06-19 ### Fixed @@ -33,6 +40,12 @@ scaled rather than raw 14-bit integers. ### Removed - Removed `recorder` class. +[@grz0zrg]: https://github.com/grz0zrg +[@manifestinteractive]: https://github.com/manifestinteractive +[@bensupper]: https://github.com/bensupper + +[1.0.4]: https://github.com/WeAreRoli/mpejs/compare/v1.0.3...v1.0.4 +[1.0.3]: https://github.com/WeAreRoli/mpejs/compare/v1.0.2...v1.0.3 [1.0.2]: https://github.com/WeAreRoli/mpejs/compare/v1.0.1...v1.0.2 [1.0.1]: https://github.com/WeAreRoli/mpejs/compare/v1.0.0...v1.0.1 [1.0.0]: https://github.com/WeAreRoli/mpejs/compare/v0.1.8...v1.0.0 diff --git a/package.json b/package.json index 1c4e921..bf474b0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "mpe", - "version": "1.0.3", + "version": "1.0.4", "description": "Next generation MIDI for the web", "keywords": [ "mpe", diff --git a/src/mpeInstrument/actions.js b/src/mpeInstrument/actions.js index e7c44f1..42c4a6c 100644 --- a/src/mpeInstrument/actions.js +++ b/src/mpeInstrument/actions.js @@ -27,11 +27,13 @@ const deriveActionType = (midiMessageType, channel, dataBytes) => { case types.NOTE_ON: // A note on with velocity 0 is a treated as a note off if (dataBytes[1] === 0) return types.NOTE_OFF; + break; case types.CONTROL_CHANGE: // CC 74 is used for timbre messages if (dataBytes[0] === 74) return types.TIMBRE; // CC 123 on the master channel is an all notes off message if (dataBytes[0] === 123 && channel === 1) return types.ALL_NOTES_OFF; + break; } return midiMessageType; }; @@ -45,7 +47,7 @@ const deriveTypeSpecificData = (baseData, currentStateCallback) => { return { noteNumber: dataBytes[0], noteOnVelocity: dataBytes[1], channelScope }; } case types.NOTE_OFF: - // A note on with velocity 0 is treated as a note off with velocity 64 + // A Note On with velocity 0 is treated as a note off with velocity 64 return midiMessageType === types.NOTE_ON ? { noteNumber: dataBytes[0], noteOffVelocity: defaults.NOTE_OFF_VELOCITY } : { noteNumber: dataBytes[0], noteOffVelocity: dataBytes[1] }; diff --git a/test/functional/metadata.test.js b/test/functional/metadata.test.js index 92b753b..7917dcb 100644 --- a/test/functional/metadata.test.js +++ b/test/functional/metadata.test.js @@ -3,7 +3,7 @@ import fs from 'fs'; describe('license', () => { it('contains an up to date copyright notice', () => { - const license = fs.readFileSync('./LICENSE', 'utf8'); - expect(license).to.include(`Copyright (c) ${new Date().getFullYear()}, ROLI Ltd.`); + const license = fs.readFileSync('./LICENSE.txt', 'utf8'); + expect(license).to.include(`Copyright (c) ${new Date().getFullYear()} ROLI Ltd.`); }); });