{"id":15583278,"url":"https://github.com/nfroidure/midievents","last_synced_at":"2025-04-24T03:44:17.378Z","repository":{"id":12541293,"uuid":"15211355","full_name":"nfroidure/midievents","owner":"nfroidure","description":"MIDI events parser/encoder.","archived":false,"fork":false,"pushed_at":"2023-02-27T22:45:02.000Z","size":167,"stargazers_count":35,"open_issues_count":3,"forks_count":7,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-24T03:44:12.158Z","etag":null,"topics":["hacktoberfest","midi"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nfroidure.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/CONTRIBUTING","funding":null,"license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2013-12-15T21:43:52.000Z","updated_at":"2024-10-16T02:47:26.000Z","dependencies_parsed_at":"2024-06-18T20:05:01.830Z","dependency_job_id":null,"html_url":"https://github.com/nfroidure/midievents","commit_stats":{"total_commits":22,"total_committers":5,"mean_commits":4.4,"dds":0.5909090909090908,"last_synced_commit":"d3c1060b295c83dc4945d8c3439f2d06194b243e"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfroidure%2Fmidievents","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfroidure%2Fmidievents/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfroidure%2Fmidievents/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfroidure%2Fmidievents/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nfroidure","download_url":"https://codeload.github.com/nfroidure/midievents/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250559521,"owners_count":21450167,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["hacktoberfest","midi"],"created_at":"2024-10-02T20:06:29.293Z","updated_at":"2025-04-24T03:44:17.362Z","avatar_url":"https://github.com/nfroidure.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[//]: # ( )\n[//]: # (This file is automatically generated by a `metapak`)\n[//]: # (module. Do not change it  except between the)\n[//]: # (`content:start/end` flags, your changes would)\n[//]: # (be overridden.)\n[//]: # ( )\n# midievents\n\u003e Decode/encode MIDI events.\n\n[![NPM version](https://badge.fury.io/js/midievents.svg)](https://npmjs.org/package/midievents)\n[![Build status](https://secure.travis-ci.org/nfroidure/midievents.svg)](https://travis-ci.org/nfroidure/midievents)\n[![Dependency Status](https://david-dm.org/nfroidure/midievents.svg)](https://david-dm.org/nfroidure/midievents)\n[![devDependency Status](https://david-dm.org/nfroidure/midievents/dev-status.svg)](https://david-dm.org/nfroidure/midievents#info=devDependencies)\n[![Coverage Status](https://coveralls.io/repos/nfroidure/midievents/badge.svg?branch=master)](https://coveralls.io/r/nfroidure/midievents?branch=master)\n[![Code Climate](https://codeclimate.com/github/nfroidure/midievents.svg)](https://codeclimate.com/github/nfroidure/midievents)\n[![Dependency Status](https://dependencyci.com/github/nfroidure/midievents/badge)](https://dependencyci.com/github/nfroidure/midievents)\n\n\n[//]: # (::contents:start)\n\n## What it does\n* Decode MIDI events\n* Check MIDI events (using `strictMode`)\n*\tCalculate needed buffer to encode MIDI events\n*\tEncode MIDI events\n\n## What it doesn't do\n*\tReading MIDI files. It's the role of the\n [MIDIFile project](https://github.com/nfroidure/midifile).\n* Playing MIDI files. It's the role of the\n [MIDIPlayer project](https://github.com/nfroidure/midiplayer).\n\n## Usage\n```js\n// Your variable with an ArrayBuffer instance containing your MIDI events\nvar anyBuffer;\n\n// Parse MIDI events\nvar events = [];\nvar parser = new MIDIEvents.createParser(new DataView(anyBuffer), 0, false);\nvar event = parser.next();\n\ndo {\n  events.push(event);\n  event = parser.next();\n} while(event);\n\n// Check bufffer size before encoding\nif(anyBuffer.length \u003e= MIDIEvents.getRequiredBufferLength(events)) {\n  console.log('ok');\n}\n\n// Encode MIDI events\nvar destination = new Uint8Array(anyBuffer);\nMIDIEvents.writeToTrack(events, destination);\n\n```\n\n## Contributing / Testing\nInstall them and run the following command :\n\n```bash\nnpm install --dev\nsu npm install grunt-cli -g\ngrunt test\n```\n\n## Contributing\n* Feel free to PR\n* If you find MIDI events the library can't read, create a test an do a pull\n request. I'll work on it asap.\n* Run `npm run` to get a list of useful development commands.\n\n[//]: # (::contents:end)\n\n# License\n[MIT](https://github.com/nfroidure/midievents/blob/master/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnfroidure%2Fmidievents","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnfroidure%2Fmidievents","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnfroidure%2Fmidievents/lists"}