「モジュール:MOS」の版間の差分

Furcht968 (トーク | 投稿記録)
編集の要約なし
Furcht968 (トーク | 投稿記録)
編集の要約なし
688行目: 688行目:
return p.new(z, w, mos.equave)
return p.new(z, w, mos.equave)
end
--------------------------------------------------------------------------------
---------------------------- EQUAL-TUNING FUNCTIONS ----------------------------
--------------------------------------------------------------------------------
-- Given a mos and a step ratio, return an equal tuning (or equal division).
-- The step ratio is entered as a 2-element array to allow non-simplified
-- ratios to be entered. (The rational module isn't suitable since it simplifies
-- ratios.)
function p.as_et(mos, step_ratio, suffix)
local suffix = suffix or nil
local et_size = mos.nL * step_ratio[1] + mos.ns * step_ratio[2]
return et.new(et_size, mos.equave, suffix)
end
end