Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gareththegeek/mus2midi
Web based library to convert mus format audio files from Doom wads to midi format written in Typescript
https://github.com/gareththegeek/mus2midi
audio doom midi typescript wad
Last synced: about 1 month ago
JSON representation
Web based library to convert mus format audio files from Doom wads to midi format written in Typescript
- Host: GitHub
- URL: https://github.com/gareththegeek/mus2midi
- Owner: gareththegeek
- License: mit
- Created: 2021-07-07T13:16:58.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-07-08T16:44:25.000Z (over 3 years ago)
- Last Synced: 2024-09-12T00:28:52.610Z (2 months ago)
- Topics: audio, doom, midi, typescript, wad
- Language: TypeScript
- Homepage:
- Size: 110 KB
- Stars: 7
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# mus2midi
A library for converting mus format audio files found in Doom wads to midi format.
Thanks to the following resources for helping me figure this out:
- [Doom wiki](https://doomwiki.org/wiki/MUS)
- [DOS Game Modding Wiki - MUS Format](https://moddingwiki.shikadi.net/wiki/MUS_Format)
- [DOS Game Modding Wiki - MIDI Format](https://moddingwiki.shikadi.net/wiki/MID_Format)## Installation
```bash
yarn add mus2midi
```
or
```bash
npm install --save mus2midi
```## Usage Example
Reading the file `e1m1.mus`, converting to midi and writing out to `e1m1.mid`.
```typescript
import { promises as fs } from 'fs'
import { mus2midi } from 'mus2midi'(async () => {
const mus = await fs.readFile('e1m1.mus')
const mid = mus2midi(mus)
await fs.write('e1m1.mid', mid)
})()
```## Build
```bash
yarn
yarn build
```