lilypond-user
[Top][All Lists]
Advanced

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

Re: Compute \tempo from variables


From: David Hobach
Subject: Re: Compute \tempo from variables
Date: Thu, 1 Feb 2024 18:04:23 +0100

On 2/1/24 17:21, Aaron Hill wrote:
On 2024-02-01 7:36 am, David Hobach wrote:
Hi all,

I'd like to compute the \tempo directive from variables, but couldn't yet 
figure out how to do it.

For example, let's say I have two variables such as
myTempoBase = 4
myTempo = 80

Then I'd like to do something such as
global = {
    \key c \major
    \time 4/4
    \tempo \myTempoBase = \myTempo
}

I'd expect it to resolve to \tempo 4 = 80. The above code however fails on 
2.24.1.

Any ideas?

%%%%
myTempoBase = ##{ 4 #}
%%%%

That seems to work.  Otherwise, myTempoBase is just a number and not a duration.

Yes, indeed. Thanks a lot!

-- Aaron Hill

Attachment: OpenPGP_0x08DEA51AE90C3780.asc
Description: OpenPGP public key

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature


reply via email to

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