Update README

This commit is contained in:
Starbeamrainbowlabs 2021-07-24 01:45:47 +01:00
parent 7b7bab1f85
commit ed74f1d9e3
Signed by: sbrl
GPG key ID: 1BE5172E637709C2

View file

@ -2,6 +2,20 @@
> Converts MIDI files into music box scores that are ready to print.
## System Requirements
- Linux:
- [Mono](https://www.mono-project.com/download/stable/) (`dotnet` might work but is untested)
- Windows:
- Visual Studio (the free version is fine - it's just the developer command prompt you need)
- All operating systems:
- [Git](https://git-scm.com/downloads) (`sudo apt install git` on apt-based systems)
- For printing:
- [Inkscape](https://inkscape.org/)
- [ImageMagick](https://imagemagick.org/) (`sudo apt install imagemagick` on apt-based systems)
- [pdfposter](https://pdfposter.readthedocs.io/en/stable/Installation.html) (`sudo apt install pdfposter` on apt-based systems)
## Getting Started
This program is written in C♯. To get started, first clone this repository and compile it:
@ -11,9 +25,13 @@ cd MusicBoxConverter
msbuild
```
If you're on Windows, you'll either need to use a _Visual Studio Developer Command Prompt_ or open the solution file in _Visual Studio_ itself.
This should work regardless of whether you're on Linux or Windows.
Alternatively, you can
If you're on Windows, you'll either need to use a _Visual Studio Developer Command Prompt_ or open the solution file in _Visual Studio_ itself and hit the build button.
Once the build is complete, the binary (and associated libraries) can be found in `MusicBoxConverter/bin/Debug` (or `MusicBoxConverter/bin/Release` if you did a release build).
If you're having trouble building it, please [get in touch](https://starbeamrainbowlabs.com/) and I'll send you a build.
## Usage
@ -24,16 +42,16 @@ Alternatively, you can
5. Open the resulting PDF in LibreOffice Draw
6. Print to your actual printer - tiling over multiple pages if required.
This somewhat convoluted process prevents anyone from automatically rescaling it along the way.
This somewhat convoluted process prevents anyone from automatically rescaling it along the way, and thus misaligning the green lines in the SVG file generated by the program.
If the above doesn't work, it's probably LibreOffice Draw scaling it even though you've told it not to. In that case, try this:
```bash
# Convert MIDI -> SVG
./MusicBoxConverter.exe --input song.midi --output score.svg
# Convert it to png
inkscape -e score.png score.svg
# Convert the PNG to PDF, rotating by 90 degrees
# Convert SVG → PNG
inkscape -o score.png score.svg
# Convert the PNG to PDF, rotating by 90 degrees (for portrait printing)
convert score.png -rotate 90 score.pdf
# Split the PDF up into multiple pages for the printer
# -s1 Don't scale the output
@ -48,9 +66,11 @@ convert score.svg score.pdf
pdfposter -s1 score.pdf print.pdf
```
## Useful Links
- [ffmpeg - showspectrumpic manual](https://ffmpeg.org/ffmpeg-filters.html#showspectrumpic)
- [Frequency to Musical Note Converter](https://newt.phys.unsw.edu.au/music/note/)
## License
This project is released under the Mozilla Public License 2.0. The full license text is included in the `LICENSE` file in this repository. Tldr legal have a [great summary](https://tldrlegal.com/license/mozilla-public-license-2.0-(mpl-2)) of the license if you're interested.