lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MIDI file creation - or not?


From: Aaron Hill
Subject: Re: MIDI file creation - or not?
Date: Mon, 01 Jul 2019 19:10:46 -0700
User-agent: Roundcube Webmail/1.3.8

On 2019-07-01 1:22 pm, Ben Potter wrote:
I took the example chant and engraved it as a test - fine. I then
added a \midi{} command in, I believe, the correct place but still get
no MIDI file to play. I am stuck - please can someone help this
beginner?

I do not believe \midi can be used within a \markup \score. At least, in my testing, it does not work. The \score needs to be top-level.

If you need to keep your \score within the \markup, put the important bits in a variable and use it twice:

%%%%
\version "2.19.82"

stuff = << \new Staff { b'4 } \new Staff { \clef "bass" g4 } >>
\markup \fill-line { \score { \stuff } }
\score { \stuff \midi { } }
%%%%

That said, you can probably achieve what you want without needing to use \markup \fill-line for centering. LilyPond already centers the music on the page, you just need to specify a smaller value for line-width:

%%%%
\version "2.19.82"

stuff = << \new Staff { b'4 } \new Staff { \clef "bass" g4 } >>
\paper { indent = 0 line-width = 1\in ragged-right = ##f }
\score { \stuff \layout { } \midi { } }
%%%%

This would require you to specify the width manually, but that might not be a bad thing.


-- Aaron Hill



reply via email to

[Prev in Thread] Current Thread [Next in Thread]