Skip to content

how do I render a midi file and load the audio data to memory? #922

Answered by mawe42
ghost asked this question in Q&A
Discussion options

You must be logged in to vote

Hi!

Assuming you are on Linux or a similar platform: If you specify - as filename, then FluidSynth will render the audio to stdout instead. Combine that with -q to make sure no extra output messes up your audio stream:

fluidsynth /path/to/font.sf2 /path/to/file.mid -q -F-

Then just execute that using Python and capture stdout, for example with subprocess.check_output.

Cheers

Replies: 1 comment 13 replies

Comment options

You must be logged in to vote
13 replies
@ghost
Comment options

@mawe42
Comment options

@ghost
Comment options

@mawe42
Comment options

@ghost
Comment options

Answer selected
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant